From ca1be02bf02189312f95d1df2231370b3e102950 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Mon, 4 Feb 2019 00:06:06 -0600 Subject: [PATCH] Tweak some pins formatting --- Marlin/src/pins/pins_3DRAG.h | 10 ++- Marlin/src/pins/pins_K8400.h | 7 +- Marlin/src/pins/pins_RAMPS.h | 132 +++++++++++++++++------------------ 3 files changed, 73 insertions(+), 76 deletions(-) diff --git a/Marlin/src/pins/pins_3DRAG.h b/Marlin/src/pins/pins_3DRAG.h index 61cdb56c1d..3854e2ab14 100644 --- a/Marlin/src/pins/pins_3DRAG.h +++ b/Marlin/src/pins/pins_3DRAG.h @@ -39,11 +39,11 @@ // // Heaters / Fans // -#define RAMPS_D8_PIN 9 -#define RAMPS_D9_PIN 8 -#define MOSFET_D_PIN 12 +#define RAMPS_D8_PIN 9 +#define RAMPS_D9_PIN 8 +#define MOSFET_D_PIN 12 -#define CASE_LIGHT_PIN -1 // MUST BE HARDWARE PWM but one is not available on expansion header +#define CASE_LIGHT_PIN -1 // MUST BE HARDWARE PWM but one is not available on expansion header #include "pins_RAMPS.h" @@ -51,7 +51,6 @@ // Limit Switches // #undef Z_MAX_PIN -#define Z_MAX_PIN -1 // // Steppers @@ -78,7 +77,6 @@ // #if ENABLED(ULTRA_LCD) && ENABLED(NEWPANEL) #undef BEEPER_PIN - #define BEEPER_PIN -1 #undef LCD_PINS_RS #undef LCD_PINS_ENABLE diff --git a/Marlin/src/pins/pins_K8400.h b/Marlin/src/pins/pins_K8400.h index 3e2cd4b212..c225ca54f2 100644 --- a/Marlin/src/pins/pins_K8400.h +++ b/Marlin/src/pins/pins_K8400.h @@ -31,9 +31,8 @@ * - Second heater has moved pin */ -#define BOARD_NAME "K8400" #define DEFAULT_MACHINE_NAME "Vertex" -#define DEFAULT_SOURCE_CODE_URL "https://github.com/birkett/Vertex-K8400-Firmware" +#define BOARD_NAME "K8400" #include "pins_3DRAG.h" @@ -52,13 +51,13 @@ // Steppers // #undef E1_STEP_PIN -#define E1_STEP_PIN 32 +#define E1_STEP_PIN 32 // // Heaters / Fans // #undef HEATER_1_PIN -#define HEATER_1_PIN 11 +#define HEATER_1_PIN 11 // // Misc. Functions diff --git a/Marlin/src/pins/pins_RAMPS.h b/Marlin/src/pins/pins_RAMPS.h index 6b9bd11148..6def8dbfab 100644 --- a/Marlin/src/pins/pins_RAMPS.h +++ b/Marlin/src/pins/pins_RAMPS.h @@ -131,71 +131,6 @@ #define E1_CS_PIN 44 #endif -/** - * Default pins for TMC software SPI - */ -#if ENABLED(TMC_USE_SW_SPI) - #ifndef TMC_SW_MOSI - #define TMC_SW_MOSI 66 - #endif - #ifndef TMC_SW_MISO - #define TMC_SW_MISO 44 - #endif - #ifndef TMC_SW_SCK - #define TMC_SW_SCK 64 - #endif -#endif - -#if HAS_DRIVER(TMC2208) - /** - * TMC2208 stepper drivers - * - * Hardware serial communication ports. - * If undefined software serial is used according to the pins below - */ - //#define X_HARDWARE_SERIAL Serial1 - //#define X2_HARDWARE_SERIAL Serial1 - //#define Y_HARDWARE_SERIAL Serial1 - //#define Y2_HARDWARE_SERIAL Serial1 - //#define Z_HARDWARE_SERIAL Serial1 - //#define Z2_HARDWARE_SERIAL Serial1 - //#define E0_HARDWARE_SERIAL Serial1 - //#define E1_HARDWARE_SERIAL Serial1 - //#define E2_HARDWARE_SERIAL Serial1 - //#define E3_HARDWARE_SERIAL Serial1 - //#define E4_HARDWARE_SERIAL Serial1 - - /** - * Software serial - */ - - #define X_SERIAL_TX_PIN 40 - #define X_SERIAL_RX_PIN 63 - #define X2_SERIAL_TX_PIN -1 - #define X2_SERIAL_RX_PIN -1 - - #define Y_SERIAL_TX_PIN 59 - #define Y_SERIAL_RX_PIN 64 - #define Y2_SERIAL_TX_PIN -1 - #define Y2_SERIAL_RX_PIN -1 - - #define Z_SERIAL_TX_PIN 42 - #define Z_SERIAL_RX_PIN 65 - #define Z2_SERIAL_TX_PIN -1 - #define Z2_SERIAL_RX_PIN -1 - - #define E0_SERIAL_TX_PIN 44 - #define E0_SERIAL_RX_PIN 66 - #define E1_SERIAL_TX_PIN -1 - #define E1_SERIAL_RX_PIN -1 - #define E2_SERIAL_TX_PIN -1 - #define E2_SERIAL_RX_PIN -1 - #define E3_SERIAL_TX_PIN -1 - #define E3_SERIAL_RX_PIN -1 - #define E4_SERIAL_TX_PIN -1 - #define E4_SERIAL_RX_PIN -1 -#endif - // // Temperature Sensors // @@ -285,7 +220,7 @@ #define FILWIDTH_PIN 5 // Analog Input on AUX2 #endif -// define digital pin 4 for the filament runout sensor. Use the RAMPS 1.4 digital input 4 on the servos connector +// RAMPS 1.4 DIO 4 on the servos connector #ifndef FIL_RUNOUT_PIN #define FIL_RUNOUT_PIN 4 #endif @@ -319,6 +254,71 @@ #endif #endif +// +// TMC software SPI +// +#if ENABLED(TMC_USE_SW_SPI) + #ifndef TMC_SW_MOSI + #define TMC_SW_MOSI 66 + #endif + #ifndef TMC_SW_MISO + #define TMC_SW_MISO 44 + #endif + #ifndef TMC_SW_SCK + #define TMC_SW_SCK 64 + #endif +#endif + +#if HAS_DRIVER(TMC2208) + /** + * TMC2208 stepper drivers + * + * Hardware serial communication ports. + * If undefined software serial is used according to the pins below + */ + //#define X_HARDWARE_SERIAL Serial1 + //#define X2_HARDWARE_SERIAL Serial1 + //#define Y_HARDWARE_SERIAL Serial1 + //#define Y2_HARDWARE_SERIAL Serial1 + //#define Z_HARDWARE_SERIAL Serial1 + //#define Z2_HARDWARE_SERIAL Serial1 + //#define E0_HARDWARE_SERIAL Serial1 + //#define E1_HARDWARE_SERIAL Serial1 + //#define E2_HARDWARE_SERIAL Serial1 + //#define E3_HARDWARE_SERIAL Serial1 + //#define E4_HARDWARE_SERIAL Serial1 + + // + // Software serial + // + + #define X_SERIAL_TX_PIN 40 + #define X_SERIAL_RX_PIN 63 + #define X2_SERIAL_TX_PIN -1 + #define X2_SERIAL_RX_PIN -1 + + #define Y_SERIAL_TX_PIN 59 + #define Y_SERIAL_RX_PIN 64 + #define Y2_SERIAL_TX_PIN -1 + #define Y2_SERIAL_RX_PIN -1 + + #define Z_SERIAL_TX_PIN 42 + #define Z_SERIAL_RX_PIN 65 + #define Z2_SERIAL_TX_PIN -1 + #define Z2_SERIAL_RX_PIN -1 + + #define E0_SERIAL_TX_PIN 44 + #define E0_SERIAL_RX_PIN 66 + #define E1_SERIAL_TX_PIN -1 + #define E1_SERIAL_RX_PIN -1 + #define E2_SERIAL_TX_PIN -1 + #define E2_SERIAL_RX_PIN -1 + #define E3_SERIAL_TX_PIN -1 + #define E3_SERIAL_RX_PIN -1 + #define E4_SERIAL_TX_PIN -1 + #define E4_SERIAL_RX_PIN -1 +#endif + // // Průša i3 MK2 Multiplexer Support //