A single SERIAL_ECHO macro type (#12557)

This commit is contained in:
Scott Lahteine
2018-11-29 16:58:58 -06:00
committed by GitHub
parent 69d869c3d9
commit c986239837
86 changed files with 1016 additions and 1356 deletions

View File

@@ -95,13 +95,13 @@ void GcodeSuite::M420() {
const int16_t a = settings.calc_num_meshes();
if (!a) {
SERIAL_PROTOCOLLNPGM("?EEPROM storage not available.");
SERIAL_ECHOLNPGM("?EEPROM storage not available.");
return;
}
if (!WITHIN(storage_slot, 0, a - 1)) {
SERIAL_PROTOCOLLNPGM("?Invalid storage slot.");
SERIAL_PROTOCOLLNPAIR("?Use 0 to ", a - 1);
SERIAL_ECHOLNPGM("?Invalid storage slot.");
SERIAL_ECHOLNPAIR("?Use 0 to ", a - 1);
return;
}
@@ -110,7 +110,7 @@ void GcodeSuite::M420() {
#else
SERIAL_PROTOCOLLNPGM("?EEPROM storage not available.");
SERIAL_ECHOLNPGM("?EEPROM storage not available.");
return;
#endif
@@ -206,10 +206,8 @@ void GcodeSuite::M420() {
set_bed_leveling_enabled(to_enable);
// Error if leveling failed to enable or reenable
if (to_enable && !planner.leveling_active) {
SERIAL_ERROR_START();
SERIAL_ERRORLNPGM(MSG_ERR_M420_FAILED);
}
if (to_enable && !planner.leveling_active)
SERIAL_ERROR_MSG(MSG_ERR_M420_FAILED);
SERIAL_ECHO_START();
SERIAL_ECHOPGM("Bed Leveling ");