1
0
mirror of https://github.com/MarlinFirmware/Marlin.git synced 2024-11-27 22:08:02 +00:00

Optimize some serial strings

This commit is contained in:
Scott Lahteine 2018-01-23 18:58:10 -06:00
parent d4ab383a1b
commit f447668387
5 changed files with 8 additions and 8 deletions

View File

@ -117,7 +117,7 @@
SERIAL_ECHOPGM("New position reads as ");
SERIAL_ECHO(get_position());
SERIAL_ECHOPGM("(");
SERIAL_CHAR('(');
SERIAL_ECHO(mm_from_count(get_position()));
SERIAL_ECHOLNPGM(")");
#endif

View File

@ -10029,7 +10029,7 @@ inline void gcode_M502() {
if (!ijk) {
SERIAL_ECHO_START();
SERIAL_ECHO(MSG_SKEW_FACTOR " XY: ");
SERIAL_ECHOPGM(MSG_SKEW_FACTOR " XY: ");
SERIAL_ECHO_F(planner.xy_skew_factor, 6);
SERIAL_EOL();
#if ENABLED(SKEW_CORRECTION_FOR_Z)

View File

@ -2228,7 +2228,7 @@ void MarlinSettings::reset() {
}
CONFIG_ECHO_START;
#if ENABLED(SKEW_CORRECTION_FOR_Z)
SERIAL_ECHO(" M852 I");
SERIAL_ECHOPGM(" M852 I");
SERIAL_ECHO_F(LINEAR_UNIT(planner.xy_skew_factor), 6);
SERIAL_ECHOPGM(" J");
SERIAL_ECHO_F(LINEAR_UNIT(planner.xz_skew_factor), 6);
@ -2236,7 +2236,7 @@ void MarlinSettings::reset() {
SERIAL_ECHO_F(LINEAR_UNIT(planner.yz_skew_factor), 6);
SERIAL_EOL();
#else
SERIAL_ECHO(" M852 S");
SERIAL_ECHOPGM(" M852 S");
SERIAL_ECHO_F(LINEAR_UNIT(planner.xy_skew_factor), 6);
SERIAL_EOL();
#endif
@ -2251,7 +2251,7 @@ void MarlinSettings::reset() {
SERIAL_ECHOLNPGM("Stepper driver current:");
}
CONFIG_ECHO_START;
SERIAL_ECHO(" M906");
SERIAL_ECHOPGM(" M906");
#if ENABLED(X_IS_TMC2130) || ENABLED(X_IS_TMC2208)
SERIAL_ECHOPAIR(" X ", stepperX.getCurrent());
#endif
@ -2297,7 +2297,7 @@ void MarlinSettings::reset() {
SERIAL_ECHOLNPGM("Sensorless homing threshold:");
}
CONFIG_ECHO_START;
SERIAL_ECHO(" M914");
SERIAL_ECHOPGM(" M914");
#if ENABLED(X_IS_TMC2130)
SERIAL_ECHOPAIR(" X", stepperX.sgt());
#endif

View File

@ -282,7 +282,7 @@ void GCodeParser::unknown_command_error() {
#else
SERIAL_ECHOPAIR(" args: \"", command_args);
#endif
SERIAL_ECHOPGM("\"");
SERIAL_CHAR('"');
if (string_arg) {
SERIAL_ECHOPGM(" string: \"");
SERIAL_ECHO(string_arg);

View File

@ -140,7 +140,7 @@ void PrintCounter::showStats() {
SERIAL_ECHOPGM("Filament used: ");
SERIAL_ECHO(this->data.filamentUsed / 1000);
SERIAL_ECHOPGM("m");
SERIAL_CHAR('m');
SERIAL_EOL();
}