Explorar o código

Avoid copying FW version number into RAM - use the PROGMEM string

D.R.racer %!s(int64=3) %!d(string=hai) anos
pai
achega
c1ff6242b0
Modificáronse 2 ficheiros con 2 adicións e 2 borrados
  1. 1 1
      Firmware/Marlin_main.cpp
  2. 1 1
      Firmware/ultralcd.cpp

+ 1 - 1
Firmware/Marlin_main.cpp

@@ -8218,7 +8218,7 @@ Sigma_Exit:
                     if(code_seen('P'))
                          fw_version_check(++strchr_pointer);
                     else if(code_seen('Q'))
-                         SERIAL_PROTOCOLLN(FW_VERSION);
+                         SERIAL_PROTOCOLLNRPGM(FW_VERSION_STR_P());
                     break;
                case ClPrintChecking::_Gcode:      // ~ .5
                     if(code_seen('P'))

+ 1 - 1
Firmware/ultralcd.cpp

@@ -4212,7 +4212,7 @@ static void prusa_stat_printinfo()
 		SERIAL_ECHO(0);
 	}
 	SERIAL_ECHOPGM("][FWR:");
-	SERIAL_ECHO(FW_VERSION);
+	SERIAL_ECHORPGM(FW_VERSION_STR_P());
 	SERIAL_ECHO(']');
      prusa_stat_diameter();
 }