Explorar el Código

Move XYZ in print_xyz and DEBUG_POS to the front

Scott Lahteine hace 9 años
padre
commit
9c5b462ef2
Se han modificado 1 ficheros con 8 adiciones y 8 borrados
  1. 8
    8
      Marlin/Marlin_main.cpp

+ 8
- 8
Marlin/Marlin_main.cpp Ver fichero

573
 static void report_current_position();
573
 static void report_current_position();
574
 
574
 
575
 #if ENABLED(DEBUG_LEVELING_FEATURE)
575
 #if ENABLED(DEBUG_LEVELING_FEATURE)
576
-  void print_xyz(const char* prefix, const float x, const float y, const float z) {
577
-    SERIAL_ECHO(prefix);
578
-    SERIAL_ECHOPAIR(": (", x);
576
+  void print_xyz(const char* suffix, const float x, const float y, const float z) {
577
+    SERIAL_ECHOPAIR("(", x);
579
     SERIAL_ECHOPAIR(", ", y);
578
     SERIAL_ECHOPAIR(", ", y);
580
     SERIAL_ECHOPAIR(", ", z);
579
     SERIAL_ECHOPAIR(", ", z);
581
-    SERIAL_ECHOLNPGM(")");
580
+    SERIAL_ECHOLNPGM(") ");
581
+    SERIAL_ECHO(suffix);
582
   }
582
   }
583
-  void print_xyz(const char* prefix, const float xyz[]) {
584
-    print_xyz(prefix, xyz[X_AXIS], xyz[Y_AXIS], xyz[Z_AXIS]);
583
+  void print_xyz(const char* suffix, const float xyz[]) {
584
+    print_xyz(suffix, xyz[X_AXIS], xyz[Y_AXIS], xyz[Z_AXIS]);
585
   }
585
   }
586
   #if ENABLED(AUTO_BED_LEVELING_FEATURE)
586
   #if ENABLED(AUTO_BED_LEVELING_FEATURE)
587
-    void print_xyz(const char* prefix, const vector_3 &xyz) {
588
-      print_xyz(prefix, xyz.x, xyz.y, xyz.z);
587
+    void print_xyz(const char* suffix, const vector_3 &xyz) {
588
+      print_xyz(suffix, xyz.x, xyz.y, xyz.z);
589
     }
589
     }
590
   #endif
590
   #endif
591
   #define DEBUG_POS(PREFIX,VAR) do{ SERIAL_ECHOPGM(PREFIX); print_xyz(" > " STRINGIFY(VAR), VAR); }while(0)
591
   #define DEBUG_POS(PREFIX,VAR) do{ SERIAL_ECHOPGM(PREFIX); print_xyz(" > " STRINGIFY(VAR), VAR); }while(0)

Loading…
Cancelar
Guardar