Skip to content

Commit

Permalink
Comment return false in motion functions
Browse files Browse the repository at this point in the history
  • Loading branch information
thinkyhead committed Dec 25, 2017
1 parent 1bb5791 commit fb6b62a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 4 additions & 6 deletions Marlin/Marlin_main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13027,7 +13027,6 @@ void set_current_from_steppers_for_axis(const AxisEnum axis) {
}
else {
// Must already have been split on these border(s)
// This should be a rare case.
buffer_line_to_destination(fr_mm_s);
set_current_from_destination();
return;
Expand Down Expand Up @@ -13096,7 +13095,6 @@ void set_current_from_steppers_for_axis(const AxisEnum axis) {
}
else {
// Must already have been split on these border(s)
// This should be a rare case.
buffer_line_to_destination(fr_mm_s);
set_current_from_destination();
return;
Expand Down Expand Up @@ -13139,7 +13137,7 @@ void set_current_from_steppers_for_axis(const AxisEnum axis) {
// If the move is only in Z/E don't split up the move
if (!xdiff && !ydiff) {
planner.buffer_line_kinematic(rtarget, _feedrate_mm_s, active_extruder);
return false;
return false; // caller will update current_position
}

// Fail if attempting move outside printable radius
Expand Down Expand Up @@ -13236,7 +13234,7 @@ void set_current_from_steppers_for_axis(const AxisEnum axis) {
planner.buffer_line_kinematic(rtarget, _feedrate_mm_s, active_extruder);
#endif

return false;
return false; // caller will update current_position
}

#else // !IS_KINEMATIC
Expand All @@ -13257,7 +13255,7 @@ void set_current_from_steppers_for_axis(const AxisEnum axis) {
return true; // all moves, including Z-only moves.
#elif ENABLED(SEGMENT_LEVELED_MOVES)
segmented_line_to_destination(MMS_SCALED(feedrate_mm_s));
return false;
return false; // caller will update current_position
#else
/**
* For MBL and ABL-BILINEAR only segment moves when X or Y are involved.
Expand All @@ -13276,7 +13274,7 @@ void set_current_from_steppers_for_axis(const AxisEnum axis) {
#endif // HAS_MESH

buffer_line_to_destination(MMS_SCALED(feedrate_mm_s));
return false;
return false; // caller will update current_position
}

#endif // !IS_KINEMATIC
Expand Down
2 changes: 2 additions & 0 deletions Marlin/ubl_motion.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -616,6 +616,8 @@

} // segment loop
} // cell loop

return false; // caller will update current_position
}

#endif // UBL_SEGMENTED
Expand Down

0 comments on commit fb6b62a

Please sign in to comment.