Browse Source

Clean up some LCD conditions

pull/1/head
Scott Lahteine 5 years ago
parent
commit
948c3f580b
  1. 5
      Marlin/src/inc/Conditionals_LCD.h
  2. 8
      Marlin/src/pins/linux/pins_RAMPS_LINUX.h
  3. 4
      Marlin/src/pins/pins.h
  4. 10
      Marlin/src/pins/ramps/pins_RAMPS.h
  5. 12
      Marlin/src/pins/ramps/pins_Z_BOLT_X_SERIES.h

5
Marlin/src/inc/Conditionals_LCD.h

@ -229,17 +229,14 @@
// Einstart OLED has Cardinal nav via pins defined in pins_EINSTART-S.h
#if ENABLED(U8GLIB_SH1106_EINSTART)
#define ULTRA_LCD
#define DOGLCD
#define ULTIPANEL
#define NEWPANEL
#endif
/**
* FSMC/SPI TFT PANELS
*/
#if ENABLED(MKS_ROBIN_TFT)
#define ULTRA_LCD
#define DOGLCD
#define ULTIPANEL
#endif
@ -330,7 +327,7 @@
#endif
#if ENABLED(ULTIPANEL)
#define NEWPANEL // Disable this if you actually have no click-encoder panel
#define NEWPANEL // Disable if there's actually no click-encoder panel
#define ULTRA_LCD
#endif

8
Marlin/src/pins/linux/pins_RAMPS_LINUX.h

@ -221,9 +221,9 @@
#endif
#if ENABLED(CASE_LIGHT_ENABLE) && !defined(CASE_LIGHT_PIN) && !defined(SPINDLE_LASER_ENA_PIN)
#if NUM_SERVOS <= 1 // try to use servo connector first
#if NUM_SERVOS <= 1 // Prefer the servo connector
#define CASE_LIGHT_PIN 6 // Hardware PWM
#elif !(BOTH(ULTRA_LCD, NEWPANEL) && ANY(PANEL_ONE, VIKI2, miniVIKI, MINIPANEL, REPRAPWORLD_KEYPAD)) // try to use AUX 2
#elif HAS_FREE_AUX2_PINS // try to use AUX 2
#define CASE_LIGHT_PIN 44 // Hardware PWM
#endif
#endif
@ -232,11 +232,11 @@
// M3/M4/M5 - Spindle/Laser Control
//
#if HAS_CUTTER && !PIN_EXISTS(SPINDLE_LASER_ENA)
#if !defined(NUM_SERVOS) || NUM_SERVOS == 0 // try to use servo connector first
#if !defined(NUM_SERVOS) || NUM_SERVOS == 0 // Prefer the servo connector
#define SPINDLE_LASER_ENA_PIN 4 // Pullup or pulldown!
#define SPINDLE_LASER_PWM_PIN 6 // Hardware PWM
#define SPINDLE_DIR_PIN 5
#elif !(BOTH(ULTRA_LCD, NEWPANEL) && ANY(PANEL_ONE, VIKI2, miniVIKI, MINIPANEL, REPRAPWORLD_KEYPAD)) // try to use AUX 2
#elif HAS_FREE_AUX2_PINS // try to use AUX 2
#define SPINDLE_LASER_ENA_PIN 40 // Pullup or pulldown!
#define SPINDLE_LASER_PWM_PIN 44 // Hardware PWM
#define SPINDLE_DIR_PIN 65

4
Marlin/src/pins/pins.h

@ -47,6 +47,8 @@
#define IS_RAMPS_SF
#endif
#define HAS_FREE_AUX2_PINS !(BOTH(ULTRA_LCD, NEWPANEL) && ANY(PANEL_ONE, VIKI2, miniVIKI, MINIPANEL, REPRAPWORLD_KEYPAD))
//
// RAMPS 1.3 / 1.4 - ATmega1280, ATmega2560
//
@ -1079,3 +1081,5 @@
#endif
#endif
#endif
#undef HAS_FREE_AUX2_PINS

10
Marlin/src/pins/ramps/pins_RAMPS.h

@ -258,12 +258,10 @@
#define PS_ON_PIN 12
#endif
#define AUX2_PINS_FREE !( BOTH(ULTRA_LCD, NEWPANEL) && ANY(PANEL_ONE, VIKI2, miniVIKI, MINIPANEL, REPRAPWORLD_KEYPAD) )
#if ENABLED(CASE_LIGHT_ENABLE) && !defined(CASE_LIGHT_PIN) && !defined(SPINDLE_LASER_ENA_PIN)
#if NUM_SERVOS <= 1 // try to use servo connector first
#if NUM_SERVOS <= 1 // Prefer the servo connector
#define CASE_LIGHT_PIN 6 // Hardware PWM
#elif AUX2_PINS_FREE
#elif HAS_FREE_AUX2_PINS
#define CASE_LIGHT_PIN 44 // Hardware PWM
#endif
#endif
@ -276,7 +274,7 @@
#define SPINDLE_LASER_ENA_PIN 4 // Pullup or pulldown!
#define SPINDLE_LASER_PWM_PIN 6 // Hardware PWM
#define SPINDLE_DIR_PIN 5
#elif AUX2_PINS_FREE
#elif HAS_FREE_AUX2_PINS
#define SPINDLE_LASER_ENA_PIN 40 // Pullup or pulldown!
#define SPINDLE_LASER_PWM_PIN 44 // Hardware PWM
#define SPINDLE_DIR_PIN 65
@ -285,8 +283,6 @@
#endif
#endif
#undef AUX2_PINS_FREE
//
// TMC software SPI
//

12
Marlin/src/pins/ramps/pins_Z_BOLT_X_SERIES.h

@ -157,12 +157,10 @@
#define PS_ON_PIN 12
#endif
#define AUX2_PINS_FREE !( BOTH(ULTRA_LCD, NEWPANEL) && ANY(PANEL_ONE, VIKI2, miniVIKI, MINIPANEL, REPRAPWORLD_KEYPAD) )
#if ENABLED(CASE_LIGHT_ENABLE) && !defined(CASE_LIGHT_PIN) && !defined(SPINDLE_LASER_ENA_PIN)
#if NUM_SERVOS <= 1 // try to use servo connector first
#if NUM_SERVOS <= 1 // Prefer the servo connector
#define CASE_LIGHT_PIN 6 // Hardware PWM
#elif AUX2_PINS_FREE
#elif HAS_FREE_AUX2_PINS
#define CASE_LIGHT_PIN 44 // Hardware PWM
#endif
#endif
@ -171,19 +169,17 @@
// M3/M4/M5 - Spindle/Laser Control
//
#if HAS_CUTTER && !PIN_EXISTS(SPINDLE_LASER_ENA)
#if !defined(NUM_SERVOS) || NUM_SERVOS == 0 // try to use servo connector first
#if !defined(NUM_SERVOS) || NUM_SERVOS == 0 // Prefer the servo connector
#define SPINDLE_LASER_ENA_PIN 4 // Pullup or pulldown!
#define SPINDLE_LASER_PWM_PIN 6 // Hardware PWM
#define SPINDLE_DIR_PIN 5
#elif AUX2_PINS_FREE
#elif HAS_FREE_AUX2_PINS
#define SPINDLE_LASER_ENA_PIN 40 // Pullup or pulldown!
#define SPINDLE_LASER_PWM_PIN 44 // Hardware PWM
#define SPINDLE_DIR_PIN 65
#endif
#endif
#undef AUX2_PINS_FREE
//
// TMC software SPI
//

Loading…
Cancel
Save