Fix unit tests for AbortPlannedMoves(axis)

pull/116/head
D.R.racer 2021-09-07 14:59:55 +02:00
parent dd2b4087fc
commit f062f368e0
1 changed files with 5 additions and 1 deletions

View File

@ -71,10 +71,14 @@ bool Motion::QueueEmpty(Axis axis) const {
void Motion::AbortPlannedMoves(bool halt) {
for (uint8_t i = 0; i < 3; ++i) {
axes[i].targetPos = axes[i].pos; // leave the axis where it was at the time of abort
AbortPlannedMoves((config::Axis)i, halt); // leave the axis where it was at the time of abort
}
}
void Motion::AbortPlannedMoves(config::Axis i, bool) {
axes[i].targetPos = axes[i].pos; // leave the axis where it was at the time of abort
}
void ReinitMotion() {
// reset the simulation data to defaults
axes[0] = AxisSim({ 0, 0, false, false, false }); // pulley