Browse Source

Fix BAUD_RATE_GCODE, etc. (#17135)

vanilla_fb_2.0.x
Jason Smith 5 years ago
committed by GitHub
parent
commit
9c759e5f74
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      Marlin/src/core/macros.h
  2. 4
      Marlin/src/gcode/calibrate/G34_M422.cpp
  3. 2
      Marlin/src/gcode/lcd/M0_M1.cpp
  4. 4
      Marlin/src/inc/Conditionals_adv.h
  5. 4
      Marlin/src/inc/Conditionals_post.h

2
Marlin/src/core/macros.h

@ -189,7 +189,7 @@
#define ENABLED(V...) DO(ENA,&&,V) #define ENABLED(V...) DO(ENA,&&,V)
#define DISABLED(V...) DO(DIS,&&,V) #define DISABLED(V...) DO(DIS,&&,V)
#define TERN(O,A,B) _TERN(_ENA_1(O),B,A) // OPTION converted to to '0' or '1' #define TERN(O,A,B) _TERN(_ENA_1(O),B,A) // OPTION converted to '0' or '1'
#define _TERN(E,V...) __TERN(_CAT(T_,E),V) // Prepend 'T_' to get 'T_0' or 'T_1' #define _TERN(E,V...) __TERN(_CAT(T_,E),V) // Prepend 'T_' to get 'T_0' or 'T_1'
#define __TERN(T,V...) ___TERN(_CAT(_NO,T),V) // Prepend '_NO' to get '_NOT_0' or '_NOT_1' #define __TERN(T,V...) ___TERN(_CAT(_NO,T),V) // Prepend '_NO' to get '_NOT_0' or '_NOT_1'
#define ___TERN(P,V...) THIRD(P,V) // If first argument has a comma, A. Else B. #define ___TERN(P,V...) THIRD(P,V) // If first argument has a comma, A. Else B.

4
Marlin/src/gcode/calibrate/G34_M422.cpp

@ -411,10 +411,10 @@ void GcodeSuite::M422() {
if (!parser.seen_any()) { if (!parser.seen_any()) {
LOOP_L_N(i, NUM_Z_STEPPER_DRIVERS) LOOP_L_N(i, NUM_Z_STEPPER_DRIVERS)
SERIAL_ECHOLNPAIR_P(PSTR("M422 S"), i + '1', SP_X_STR, z_stepper_align.xy[i].x, SP_Y_STR, z_stepper_align.xy[i].y); SERIAL_ECHOLNPAIR_P(PSTR("M422 S"), int(i + 1), SP_X_STR, z_stepper_align.xy[i].x, SP_Y_STR, z_stepper_align.xy[i].y);
#if ENABLED(Z_STEPPER_ALIGN_KNOWN_STEPPER_POSITIONS) #if ENABLED(Z_STEPPER_ALIGN_KNOWN_STEPPER_POSITIONS)
LOOP_L_N(i, NUM_Z_STEPPER_DRIVERS) LOOP_L_N(i, NUM_Z_STEPPER_DRIVERS)
SERIAL_ECHOLNPAIR_P(PSTR("M422 W"), i + '1', SP_X_STR, z_stepper_align.stepper_xy[i].x, SP_Y_STR, z_stepper_align.stepper_xy[i].y); SERIAL_ECHOLNPAIR_P(PSTR("M422 W"), int(i + 1), SP_X_STR, z_stepper_align.stepper_xy[i].x, SP_Y_STR, z_stepper_align.stepper_xy[i].y);
#endif #endif
return; return;
} }

2
Marlin/src/gcode/lcd/M0_M1.cpp

@ -59,7 +59,7 @@ void GcodeSuite::M0_M1() {
#if HAS_LEDS_OFF_FLAG #if HAS_LEDS_OFF_FLAG
const bool seenQ = parser.seen('Q'); const bool seenQ = parser.seen('Q');
if (seenQ) printerEventLEDs.onPrintCompleted(); // Change LED color for Print Completed if (seenQ) printerEventLEDs.onPrintCompleted(); // Change LED color for Print Completed
#else #elif HAS_LCD_MENU
constexpr bool seenQ = false; constexpr bool seenQ = false;
#endif #endif

4
Marlin/src/inc/Conditionals_adv.h

@ -100,10 +100,6 @@
#define HAS_LEDS_OFF_FLAG 1 #define HAS_LEDS_OFF_FLAG 1
#endif #endif
#if !NUM_SERIAL
#undef BAUD_RATE_GCODE
#endif
// Multiple Z steppers // Multiple Z steppers
#ifndef NUM_Z_STEPPER_DRIVERS #ifndef NUM_Z_STEPPER_DRIVERS
#define NUM_Z_STEPPER_DRIVERS 1 #define NUM_Z_STEPPER_DRIVERS 1

4
Marlin/src/inc/Conditionals_post.h

@ -2200,3 +2200,7 @@
#define INIT_SDCARD_ON_BOOT #define INIT_SDCARD_ON_BOOT
#endif #endif
#endif #endif
#if !NUM_SERIAL
#undef BAUD_RATE_GCODE
#endif

Loading…
Cancel
Save