Skip to content

Commit

Permalink
Touch Mi: Add magnet Y position (#15166)
Browse files Browse the repository at this point in the history
  • Loading branch information
kakou-fr authored and thinkyhead committed Sep 4, 2019
1 parent 85f0556 commit 6b1c4de
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Marlin/src/module/motion.cpp
Expand Up @@ -424,7 +424,7 @@ void do_blocking_move_to_x(const float &rx, const float &fr_mm_s/*=0.0*/) {
do_blocking_move_to(rx, current_position[Y_AXIS], current_position[Z_AXIS], fr_mm_s);
}
void do_blocking_move_to_y(const float &ry, const float &fr_mm_s/*=0.0*/) {
do_blocking_move_to(current_position[Y_AXIS], ry, current_position[Z_AXIS], fr_mm_s);
do_blocking_move_to(current_position[X_AXIS], ry, current_position[Z_AXIS], fr_mm_s);
}
void do_blocking_move_to_z(const float &rz, const float &fr_mm_s/*=0.0*/) {
do_blocking_move_to(current_position[X_AXIS], current_position[Y_AXIS], rz, fr_mm_s);
Expand Down
9 changes: 7 additions & 2 deletions Marlin/src/module/probe.cpp
Expand Up @@ -116,6 +116,9 @@ float zprobe_zoffset; // Initialized by settings.load()
#if TOUCH_MI_DEPLOY_XPOS > X_MAX_BED
TemporaryGlobalEndstopsState unlock_x(false);
#endif
#if TOUCH_MI_DEPLOY_YPOS > Y_MAX_BED
TemporaryGlobalEndstopsState unlock_y(false);
#endif

#if ENABLED(TOUCH_MI_MANUAL_DEPLOY)

Expand All @@ -132,10 +135,12 @@ float zprobe_zoffset; // Initialized by settings.load()
ui.reset_status();
ui.goto_screen(prev_screen);

#elif defined(TOUCH_MI_DEPLOY_XPOS) && defined(TOUCH_MI_DEPLOY_YPOS)
do_blocking_move_to_xy(TOUCH_MI_DEPLOY_XPOS, TOUCH_MI_DEPLOY_YPOS);
#elif defined(TOUCH_MI_DEPLOY_XPOS)

do_blocking_move_to_x(TOUCH_MI_DEPLOY_XPOS);

#elif defined(TOUCH_MI_DEPLOY_YPOS)
do_blocking_move_to_y(TOUCH_MI_DEPLOY_YPOS);
#endif
}

Expand Down

0 comments on commit 6b1c4de

Please sign in to comment.