Add missing motion inline methods (#15433)

This commit is contained in:
Timm 2019-10-01 02:57:22 +02:00 committed by Scott Lahteine
parent 15efe8d839
commit b198f321c8
2 changed files with 15 additions and 6 deletions

View file

@ -655,7 +655,7 @@ void resume_print(const float &slow_load_length/*=0*/, const float &fast_load_le
if (resume_position.e < 0) do_pause_e_move(resume_position.e, feedRate_t(PAUSE_PARK_RETRACT_FEEDRATE)); if (resume_position.e < 0) do_pause_e_move(resume_position.e, feedRate_t(PAUSE_PARK_RETRACT_FEEDRATE));
// Move XY to starting position, then Z // Move XY to starting position, then Z
do_blocking_move_to_xy(xy_pos_t(resume_position), feedRate_t(NOZZLE_PARK_XY_FEEDRATE)); do_blocking_move_to_xy(resume_position, feedRate_t(NOZZLE_PARK_XY_FEEDRATE));
// Move Z_AXIS to saved position // Move Z_AXIS to saved position
do_blocking_move_to_z(resume_position.z, feedRate_t(NOZZLE_PARK_Z_FEEDRATE)); do_blocking_move_to_z(resume_position.z, feedRate_t(NOZZLE_PARK_Z_FEEDRATE));

View file

@ -113,7 +113,7 @@ FORCE_INLINE signed char pgm_read_any(const signed char *p) { return pgm_read_by
#define XYZ_DEFS(T, NAME, OPT) \ #define XYZ_DEFS(T, NAME, OPT) \
extern const XYZval<T> NAME##_P; \ extern const XYZval<T> NAME##_P; \
FORCE_INLINE T NAME(AxisEnum axis) { return pgm_read_any(&NAME##_P[axis]); } \ FORCE_INLINE T NAME(AxisEnum axis) { return pgm_read_any(&NAME##_P[axis]); } \
typedef void __void_##OPT##__ typedef void __void_##OPT##__ /* for semicolon */
XYZ_DEFS(float, base_min_pos, MIN_POS); XYZ_DEFS(float, base_min_pos, MIN_POS);
XYZ_DEFS(float, base_max_pos, MAX_POS); XYZ_DEFS(float, base_max_pos, MAX_POS);
@ -200,10 +200,6 @@ inline void prepare_internal_move_to_destination(const feedRate_t &fr_mm_s=0.0f)
* Blocking movement and shorthand functions * Blocking movement and shorthand functions
*/ */
void do_blocking_move_to(const float rx, const float ry, const float rz, const feedRate_t &fr_mm_s=0.0f); void do_blocking_move_to(const float rx, const float ry, const float rz, const feedRate_t &fr_mm_s=0.0f);
void do_blocking_move_to_x(const float &rx, const feedRate_t &fr_mm_s=0.0f);
void do_blocking_move_to_y(const float &ry, const feedRate_t &fr_mm_s=0.0f);
void do_blocking_move_to_z(const float &rz, const feedRate_t &fr_mm_s=0.0f);
void do_blocking_move_to_xy(const float &rx, const float &ry, const feedRate_t &fr_mm_s=0.0f);
FORCE_INLINE void do_blocking_move_to(const xy_pos_t &raw, const feedRate_t &fr_mm_s=0.0f) { FORCE_INLINE void do_blocking_move_to(const xy_pos_t &raw, const feedRate_t &fr_mm_s=0.0f) {
do_blocking_move_to(raw.x, raw.y, current_position.z, fr_mm_s); do_blocking_move_to(raw.x, raw.y, current_position.z, fr_mm_s);
@ -214,9 +210,22 @@ FORCE_INLINE void do_blocking_move_to(const xyz_pos_t &raw, const feedRate_t &fr
FORCE_INLINE void do_blocking_move_to(const xyze_pos_t &raw, const feedRate_t &fr_mm_s=0.0f) { FORCE_INLINE void do_blocking_move_to(const xyze_pos_t &raw, const feedRate_t &fr_mm_s=0.0f) {
do_blocking_move_to(raw.x, raw.y, raw.z, fr_mm_s); do_blocking_move_to(raw.x, raw.y, raw.z, fr_mm_s);
} }
void do_blocking_move_to_xy(const float &rx, const float &ry, const feedRate_t &fr_mm_s=0.0f);
FORCE_INLINE void do_blocking_move_to_xy(const xy_pos_t &raw, const feedRate_t &fr_mm_s=0.0f) { FORCE_INLINE void do_blocking_move_to_xy(const xy_pos_t &raw, const feedRate_t &fr_mm_s=0.0f) {
do_blocking_move_to_xy(raw.x, raw.y, fr_mm_s); do_blocking_move_to_xy(raw.x, raw.y, fr_mm_s);
} }
FORCE_INLINE void do_blocking_move_to_xy(const xyz_pos_t &raw, const feedRate_t &fr_mm_s=0.0f) {
do_blocking_move_to_xy(raw.x, raw.y, fr_mm_s);
}
FORCE_INLINE void do_blocking_move_to_xy(const xyze_pos_t &raw, const feedRate_t &fr_mm_s=0.0f) {
do_blocking_move_to_xy(raw.x, raw.y, fr_mm_s);
}
void do_blocking_move_to_x(const float &rx, const feedRate_t &fr_mm_s=0.0f);
void do_blocking_move_to_y(const float &ry, const feedRate_t &fr_mm_s=0.0f);
void do_blocking_move_to_z(const float &rz, const feedRate_t &fr_mm_s=0.0f);
void remember_feedrate_and_scaling(); void remember_feedrate_and_scaling();
void remember_feedrate_scaling_off(); void remember_feedrate_scaling_off();