Pārlūkot izejas kodu

Complete M200 output with M503

- The contents of EEPROM include filament diameters even with
Volumetric disabled. This change makes `M503` display the full
volumetric settings so that playing back the output of `M503 S0` will
fully restore them.
Scott Lahteine 10 gadus atpakaļ
vecāks
revīzija
c7c8cfed6f
1 mainītis faili ar 27 papildinājumiem un 21 dzēšanām
  1. 27
    21
      Marlin/configuration_store.cpp

+ 27
- 21
Marlin/configuration_store.cpp Parādīt failu

@@ -826,39 +826,45 @@ void Config_PrintSettings(bool forReplay) {
826 826
 
827 827
   #endif // FWRETRACT
828 828
 
829
-  if (volumetric_enabled) {
830
-    if (!forReplay) {
831
-      CONFIG_ECHO_START;
832
-      SERIAL_ECHOLNPGM("Filament settings:");
833
-    }
829
+  /**
830
+   * Volumetric extrusion M200
831
+   */
832
+  if (!forReplay) {
833
+    CONFIG_ECHO_START;
834
+    SERIAL_ECHOPGM("Filament settings:");
835
+    if (volumetric_enabled)
836
+      SERIAL_EOL;
837
+    else
838
+      SERIAL_ECHOLNPGM(" Disabled");
839
+  }
834 840
 
841
+  CONFIG_ECHO_START;
842
+  SERIAL_ECHOPAIR("  M200 D", filament_size[0]);
843
+  SERIAL_EOL;
844
+  #if EXTRUDERS > 1
835 845
     CONFIG_ECHO_START;
836
-    SERIAL_ECHOPAIR("  M200 D", filament_size[0]);
846
+    SERIAL_ECHOPAIR("  M200 T1 D", filament_size[1]);
837 847
     SERIAL_EOL;
838
-
839
-    #if EXTRUDERS > 1
848
+    #if EXTRUDERS > 2
840 849
       CONFIG_ECHO_START;
841
-      SERIAL_ECHOPAIR("  M200 T1 D", filament_size[1]);
850
+      SERIAL_ECHOPAIR("  M200 T2 D", filament_size[2]);
842 851
       SERIAL_EOL;
843
-      #if EXTRUDERS > 2
852
+      #if EXTRUDERS > 3
844 853
         CONFIG_ECHO_START;
845
-        SERIAL_ECHOPAIR("  M200 T2 D", filament_size[2]);
854
+        SERIAL_ECHOPAIR("  M200 T3 D", filament_size[3]);
846 855
         SERIAL_EOL;
847
-        #if EXTRUDERS > 3
848
-          CONFIG_ECHO_START;
849
-          SERIAL_ECHOPAIR("  M200 T3 D", filament_size[3]);
850
-          SERIAL_EOL;
851
-        #endif
852 856
       #endif
853 857
     #endif
858
+  #endif
854 859
 
855
-  } else {
856
-    if (!forReplay) {
857
-      CONFIG_ECHO_START;
858
-      SERIAL_ECHOLNPGM("Filament settings: Disabled");
859
-    }
860
+  if (!volumetric_enabled) {
861
+    CONFIG_ECHO_START;
862
+    SERIAL_ECHOLNPGM("  M200 D0");
860 863
   }
861 864
 
865
+  /**
866
+   * Auto Bed Leveling
867
+   */
862 868
   #ifdef ENABLE_AUTO_BED_LEVELING
863 869
     #ifdef CUSTOM_M_CODES
864 870
       if (!forReplay) {

Notiek ielāde…
Atcelt
Saglabāt