Adjustments to M209, G28, M605

This commit is contained in:
Scott Lahteine 2016-08-20 20:11:08 -05:00
parent e354cf5884
commit 4cd1ad8f28

View File

@ -3326,7 +3326,7 @@ inline void gcode_G28() {
switch (state) { switch (state) {
case MeshReport: case MeshReport:
if (mbl.has_mesh()) { if (mbl.has_mesh()) {
SERIAL_PROTOCOLPAIR("State: ", mbl.active() ? "On" : "Off"); SERIAL_PROTOCOLPAIR("State: ", mbl.active() ? MSG_ON : MSG_OFF);
SERIAL_PROTOCOLLNPGM("\nNum X,Y: " STRINGIFY(MESH_NUM_X_POINTS) "," STRINGIFY(MESH_NUM_Y_POINTS)); SERIAL_PROTOCOLLNPGM("\nNum X,Y: " STRINGIFY(MESH_NUM_X_POINTS) "," STRINGIFY(MESH_NUM_Y_POINTS));
SERIAL_PROTOCOLLNPGM("Z search height: " STRINGIFY(MESH_HOME_SEARCH_Z)); SERIAL_PROTOCOLLNPGM("Z search height: " STRINGIFY(MESH_HOME_SEARCH_Z));
SERIAL_PROTOCOLPGM("Z offset: "); SERIAL_PROTOCOL_F(mbl.z_offset, 5); SERIAL_PROTOCOLPGM("Z offset: "); SERIAL_PROTOCOL_F(mbl.z_offset, 5);
@ -5557,18 +5557,7 @@ inline void gcode_M206() {
*/ */
inline void gcode_M209() { inline void gcode_M209() {
if (code_seen('S')) { if (code_seen('S')) {
int t = code_value_int(); autoretract_enabled = code_value_bool();
switch (t) {
case 0:
autoretract_enabled = false;
break;
case 1:
autoretract_enabled = true;
break;
default:
unknown_command_error();
return;
}
for (int i = 0; i < EXTRUDERS; i++) retracted[i] = false; for (int i = 0; i < EXTRUDERS; i++) retracted[i] = false;
} }
} }
@ -6529,8 +6518,7 @@ inline void gcode_M503() {
stepper.synchronize(); stepper.synchronize();
extruder_duplication_enabled = code_seen('S') && code_value_int() == 2; extruder_duplication_enabled = code_seen('S') && code_value_int() == 2;
SERIAL_ECHO_START; SERIAL_ECHO_START;
SERIAL_ECHOPAIR(MSG_DUPLICATION_MODE, extruder_duplication_enabled ? MSG_ON : MSG_OFF); SERIAL_ECHOLNPAIR(MSG_DUPLICATION_MODE, extruder_duplication_enabled ? MSG_ON : MSG_OFF);
SERIAL_EOL;
} }
#endif // M605 #endif // M605