|
@@ -504,7 +504,7 @@ void serial_echopair_P(const char* s_P, float v) { serialprintPGM(s_P);
|
504
|
504
|
void serial_echopair_P(const char* s_P, double v) { serialprintPGM(s_P); SERIAL_ECHO(v); }
|
505
|
505
|
void serial_echopair_P(const char* s_P, unsigned long v) { serialprintPGM(s_P); SERIAL_ECHO(v); }
|
506
|
506
|
|
507
|
|
-void gcode_M114();
|
|
507
|
+static void report_current_position();
|
508
|
508
|
|
509
|
509
|
#if ENABLED(DEBUG_LEVELING_FEATURE)
|
510
|
510
|
void print_xyz(const char* prefix, const float x, const float y, const float z) {
|
|
@@ -2886,8 +2886,7 @@ inline void gcode_G28() {
|
2886
|
2886
|
}
|
2887
|
2887
|
#endif
|
2888
|
2888
|
|
2889
|
|
- gcode_M114(); // Send end position to RepetierHost
|
2890
|
|
-
|
|
2889
|
+ report_current_position();
|
2891
|
2890
|
}
|
2892
|
2891
|
|
2893
|
2892
|
#if ENABLED(MESH_BED_LEVELING)
|
|
@@ -3595,8 +3594,7 @@ inline void gcode_G28() {
|
3595
|
3594
|
}
|
3596
|
3595
|
#endif
|
3597
|
3596
|
|
3598
|
|
- gcode_M114(); // Send end position to RepetierHost
|
3599
|
|
-
|
|
3597
|
+ report_current_position();
|
3600
|
3598
|
}
|
3601
|
3599
|
|
3602
|
3600
|
#if DISABLED(Z_PROBE_SLED) // could be avoided
|
|
@@ -3632,7 +3630,7 @@ inline void gcode_G28() {
|
3632
|
3630
|
#endif
|
3633
|
3631
|
stow_z_probe(false); // Retract Z Servo endstop if available. Z_PROBE_SLED is missed here.
|
3634
|
3632
|
|
3635
|
|
- gcode_M114(); // Send end position to RepetierHost
|
|
3633
|
+ report_current_position();
|
3636
|
3634
|
}
|
3637
|
3635
|
|
3638
|
3636
|
#endif //!Z_PROBE_SLED
|
|
@@ -4229,7 +4227,7 @@ inline void gcode_M42() {
|
4229
|
4227
|
|
4230
|
4228
|
clean_up_after_endstop_move();
|
4231
|
4229
|
|
4232
|
|
- gcode_M114(); // Send end position to RepetierHost
|
|
4230
|
+ report_current_position();
|
4233
|
4231
|
}
|
4234
|
4232
|
|
4235
|
4233
|
#endif // AUTO_BED_LEVELING_FEATURE && Z_MIN_PROBE_REPEATABILITY_TEST
|
|
@@ -4878,9 +4876,9 @@ inline void gcode_M92() {
|
4878
|
4876
|
}
|
4879
|
4877
|
|
4880
|
4878
|
/**
|
4881
|
|
- * M114: Output current position to serial port
|
|
4879
|
+ * Output the current position to serial
|
4882
|
4880
|
*/
|
4883
|
|
-inline void gcode_M114() {
|
|
4881
|
+static void report_current_position() {
|
4884
|
4882
|
SERIAL_PROTOCOLPGM("X:");
|
4885
|
4883
|
SERIAL_PROTOCOL(current_position[X_AXIS]);
|
4886
|
4884
|
SERIAL_PROTOCOLPGM(" Y:");
|
|
@@ -4942,6 +4940,11 @@ inline void gcode_M114() {
|
4942
|
4940
|
}
|
4943
|
4941
|
|
4944
|
4942
|
/**
|
|
4943
|
+ * M114: Output current position to serial port
|
|
4944
|
+ */
|
|
4945
|
+inline void gcode_M114() { report_current_position(); }
|
|
4946
|
+
|
|
4947
|
+/**
|
4945
|
4948
|
* M115: Capabilities string
|
4946
|
4949
|
*/
|
4947
|
4950
|
inline void gcode_M115() {
|
|
@@ -5196,7 +5199,9 @@ inline void gcode_M206() {
|
5196
|
5199
|
if (code_seen('T')) set_home_offset(X_AXIS, code_value()); // Theta
|
5197
|
5200
|
if (code_seen('P')) set_home_offset(Y_AXIS, code_value()); // Psi
|
5198
|
5201
|
#endif
|
|
5202
|
+
|
5199
|
5203
|
sync_plan_position();
|
|
5204
|
+ report_current_position();
|
5200
|
5205
|
}
|
5201
|
5206
|
|
5202
|
5207
|
#if ENABLED(DELTA)
|
|
@@ -5915,6 +5920,7 @@ inline void gcode_M428() {
|
5915
|
5920
|
|
5916
|
5921
|
if (!err) {
|
5917
|
5922
|
sync_plan_position();
|
|
5923
|
+ report_current_position();
|
5918
|
5924
|
LCD_MESSAGEPGM(MSG_HOME_OFFSETS_APPLIED);
|
5919
|
5925
|
#if HAS_BUZZER
|
5920
|
5926
|
buzz(200, 659);
|