diff --git a/src/modules/idler.cpp b/src/modules/idler.cpp index 95c3734..6691aa2 100644 --- a/src/modules/idler.cpp +++ b/src/modules/idler.cpp @@ -14,7 +14,7 @@ void Idler::PrepareMoveToPlannedSlot() { } void Idler::PlanHomingMove() { - mm::motion.PlanMove(mm::unitToAxisUnit(-360.0_deg), mm::unitToAxisUnit(config::idlerFeedrate)); + mm::motion.PlanMove(mm::unitToAxisUnit(-config::idlerLimits.lenght * 2), mm::unitToAxisUnit(config::idlerFeedrate)); } Idler::OperationResult Idler::Disengage() { diff --git a/src/modules/movable_base.cpp b/src/modules/movable_base.cpp index 91fab93..142fe55 100644 --- a/src/modules/movable_base.cpp +++ b/src/modules/movable_base.cpp @@ -41,6 +41,7 @@ void MovableBase::PerformMove(config::Axis axis) { void MovableBase::PerformHome(config::Axis axis) { if (mm::motion.StallGuard(axis)) { // we have reached the end of the axis - homed ok + mm::motion.AbortPlannedMoves(true); mm::motion.SetMode(axis, mg::globals.MotorsStealth() ? mm::Stealth : mm::Normal); state = Ready; } else if (mm::motion.QueueEmpty(axis)) { diff --git a/src/modules/selector.cpp b/src/modules/selector.cpp index d4bbb3e..794739a 100644 --- a/src/modules/selector.cpp +++ b/src/modules/selector.cpp @@ -14,7 +14,7 @@ void Selector::PrepareMoveToPlannedSlot() { } void Selector::PlanHomingMove() { - mm::motion.PlanMove(mm::unitToAxisUnit(-100.0_mm), mm::unitToAxisUnit(config::selectorFeedrate)); + mm::motion.PlanMove(mm::unitToAxisUnit(config::selectorLimits.lenght * 2), mm::unitToAxisUnit(config::selectorFeedrate)); } Selector::OperationResult Selector::MoveToSlot(uint8_t slot) {