📌 Pins updates for Longer LK5, etc. (#25012)

Co-authored-by: Scott Lahteine <thinkyhead@users.noreply.github.com>
This commit is contained in:
ellensp 2022-12-11 04:00:51 +13:00 committed by Scott Lahteine
parent 0efeedf262
commit 86a3362bf6
15 changed files with 196 additions and 188 deletions

View File

@ -715,6 +715,8 @@
#undef FIL_RUNOUT2_PIN
#endif
#undef LCD_PINS_DEFINED
#ifndef LCD_PINS_D4
#define LCD_PINS_D4 -1
#endif

View File

@ -66,6 +66,8 @@
#define MOSFET_C_PIN 9
#define MOSFET_D_PIN 12
#define HEATER_2_PIN 6
//
// Misc. Functions
//
@ -122,16 +124,6 @@
#endif
#endif
#include "pins_RAMPS.h"
//
// Heaters / Fans
//
#define HEATER_2_PIN 6
#undef SD_DETECT_PIN
#define SD_DETECT_PIN 53
//
// LCD / Controller
//
@ -139,12 +131,6 @@
#undef BEEPER_PIN
// TODO: Remap EXP1/2 based on adapter
#undef LCD_PINS_RS
#undef LCD_PINS_ENABLE
#undef LCD_PINS_D4
#undef LCD_PINS_D5
#undef LCD_PINS_D6
#undef LCD_PINS_D7
#define LCD_PINS_RS 27
#define LCD_PINS_ENABLE 29
#define LCD_PINS_D4 37
@ -153,13 +139,12 @@
#define LCD_PINS_D7 31
// Buttons
#undef BTN_EN1
#undef BTN_EN2
#undef BTN_ENC
#define BTN_EN1 16
#define BTN_EN2 17
#define BTN_ENC 23
#define LCD_PINS_DEFINED
#else
#define BEEPER_PIN 33
@ -171,3 +156,7 @@
#define BOARD_ST7920_DELAY_2 188
#define BOARD_ST7920_DELAY_3 0
#endif
#define SD_DETECT_PIN 53
#include "pins_RAMPS.h"

View File

@ -37,8 +37,7 @@
//
#define X_MIN_PIN 3
#define Y_MAX_PIN 14
#define Z_MAX_PIN 18
#define Z_MIN_PIN -1
#define Z_STOP_PIN 18
//
// Steppers
@ -48,6 +47,7 @@
//
// Heaters / Fans
//
#define HEATER_BED_PIN -1
#define FAN_PIN 8
//
@ -56,28 +56,11 @@
#define SDSS 25
#define CASE_LIGHT_PIN 7
//
// Other RAMPS pins
//
#include "pins_RAMPS.h"
//
// Heaters / Fans
//
#undef HEATER_BED_PIN
//
// LCD / Controller
//
#if HAS_WIRED_LCD && IS_NEWPANEL
#undef BEEPER_PIN
#undef LCD_PINS_RS
#undef LCD_PINS_ENABLE
#undef LCD_PINS_D4
#undef LCD_PINS_D5
#undef LCD_PINS_D6
#undef LCD_PINS_D7
#define LCD_PINS_RS 27
#define LCD_PINS_ENABLE 29
#define LCD_PINS_D4 37
@ -86,15 +69,19 @@
#define LCD_PINS_D7 31
// Buttons
#undef BTN_EN1
#undef BTN_EN2
#undef BTN_ENC
#define BTN_EN1 17
#define BTN_EN2 16
#define BTN_ENC 23
#define LCD_PINS_DEFINED
#else
#define BEEPER_PIN 33
#endif
//
// Other RAMPS pins
//
#include "pins_RAMPS.h"

View File

@ -33,25 +33,30 @@
#endif
#if SERIAL_PORT == 1 || SERIAL_PORT_2 == 1 || SERIAL_PORT_3 == 1
#warning "Serial 1 is originally reserved to DGUS LCD."
#warning "Serial 1 is originally reserved for DGUS LCD."
#endif
#if SERIAL_PORT == 2 || SERIAL_PORT_2 == 2 || SERIAL_PORT_3 == 2 || LCD_SERIAL_PORT == 2
#warning "Serial 2 has no connector. Hardware changes may be required to use it."
#endif
#if SERIAL_PORT == 3 || SERIAL_PORT_2 == 3 || SERIAL_PORT_3 == 3 || LCD_SERIAL_PORT == 3
#define CHANGE_Y_LIMIT_PINS
#warning "Serial 3 is originally reserved to Y limit switches. Hardware changes are required to use it."
#warning "Serial 3 is originally reserved for Y limit switches. Hardware changes are required to use it."
#define Y_STOP_PIN 37
#if MB(LONGER3D_LKx_PRO)
#define Z_STOP_PIN 35
#endif
#endif
// Custom flags and defines for the build
//#define BOARD_CUSTOM_BUILD_FLAGS -D__FOO__
#define BOARD_INFO_NAME "LGT KIT V1.0"
#if ENABLED(LONGER_LK5)
#define DEFAULT_MACHINE_NAME "LONGER LK5"
#else
#define DEFAULT_MACHINE_NAME "LONGER 3D Printer"
#endif
//
// Servos
//
#if !MB(LONGER3D_LK1_PRO)
#if MB(LONGER3D_LKx_PRO)
#define SERVO0_PIN 7
#endif
#define SERVO1_PIN -1
@ -61,28 +66,35 @@
//
// Limit Switches
//
#if ENABLED(LONGER_LK5)
#define X_MIN_PIN 3
#define X_MAX_PIN 2
#else
#define X_STOP_PIN 3
#endif
#ifdef CHANGE_Y_LIMIT_PINS
#define Y_STOP_PIN 37
#if !ANY_PIN(Y_MIN, Y_MAX, Y_STOP)
#if ENABLED(LONGER_LK5)
#define Y_STOP_PIN 14
#else
#define Y_MIN_PIN 14
#define Y_MAX_PIN 15
#endif
#if !MB(LONGER3D_LK1_PRO)
#ifdef CHANGE_Y_LIMIT_PINS
#define Z_STOP_PIN 35
#else
#define Z_MIN_PIN 35
#define Z_MAX_PIN 37
#endif
#if !ANY_PIN(Z_MIN, Z_MAX, Z_STOP)
#if MB(LONGER3D_LKx_PRO)
#define Z_MIN_PIN 35
#else
#define Z_MIN_PIN 11
#endif
#define Z_MAX_PIN 37
#endif
#undef CHANGE_Y_LIMIT_PINS
//
// Z Probe (when not Z_MIN_PIN)
//
#define Z_MIN_PROBE_PIN -1
//
// Steppers - No E1 pins
@ -92,11 +104,6 @@
#define E1_ENABLE_PIN -1
#define E1_CS_PIN -1
//
// Z Probe (when not Z_MIN_PIN)
//
#define Z_MIN_PROBE_PIN -1
//
// Temperature Sensors
//
@ -115,7 +122,36 @@
#define SD_DETECT_PIN 49
#define FIL_RUNOUT_PIN 2
// ------------------ ---------------- --------------- -------------
// Aux-1 | D19 D18 GND 5V | J21 | D4 D5 D6 GND | J17 | D11 GND 24V | J18 | D7 GND 5V |
// ------------------ ---------------- --------------- -------------
#if BOTH(CR10_STOCKDISPLAY, LONGER_LK5)
/** CR-10 Stock Display
* ------
* GND | 9 10 | 5V
* LCD_PINS_RS D5 | 7 8 | D4 LCD_PINS_ENABLE
* BTN_EN2 D19 | 5 6 D6 LCD_PINS_D4
* BTN_EN1 D18 | 3 4 | GND
* BEEPER_PIN D11 | 1 2 | D15 BTN_ENC
* ------
* Connected via provided custom cable to:
* Aux-1, J21, J17 and Y-Max.
*/
#define LCD_PINS_RS 5
#define LCD_PINS_ENABLE 4
#define LCD_PINS_D4 6
#define BTN_EN1 18
#define BTN_EN2 19
#define BTN_ENC 15
#define BEEPER_PIN 11
#define SDCARD_CONNECTION ONBOARD
#define LCD_PINS_DEFINED
#endif
//
// Other RAMPS 1.3 pins
//
#include "pins_RAMPS_13.h" // ... RAMPS
#include "pins_RAMPS_13.h" // ... pins_RAMPS.h

View File

@ -75,31 +75,25 @@
#define E0_SERIAL_RX_PIN 65
#endif
#include "pins_RAMPS.h"
//
// LCD / Controller
//
#if IS_RRD_FG_SC
#undef BEEPER_PIN
#define BEEPER_PIN 35
#undef LCD_PINS_RS
#undef LCD_PINS_ENABLE
#undef LCD_PINS_D4
#define LCD_PINS_RS 27
#define LCD_PINS_ENABLE 23
#define LCD_PINS_D4 37
#undef LCD_SDSS
#undef SD_DETECT_PIN
#define LCD_SDSS 53
#define SD_DETECT_PIN 49
#undef BTN_EN1
#undef BTN_EN2
#undef BTN_ENC
#define BTN_EN1 29
#define BTN_EN2 25
#define BTN_ENC 16
#define LCD_PINS_DEFINED
#endif
#include "pins_RAMPS.h"

View File

@ -585,7 +585,7 @@
// LCDs and Controllers //
//////////////////////////
#if HAS_WIRED_LCD
#if HAS_WIRED_LCD && DISABLED(LCD_PINS_DEFINED)
//#define LCD_SCREEN_ROTATE 180 // 0, 90, 180, 270
@ -715,7 +715,9 @@
#define BTN_EN1 AUX2_05_PIN
#define BTN_EN2 AUX2_03_PIN
#define BTN_ENC AUX2_04_PIN
#ifndef SD_DETECT_PIN
#define SD_DETECT_PIN AUX2_08_PIN
#endif
#elif ENABLED(LCD_I2C_PANELOLU2)
@ -732,7 +734,9 @@
#define BTN_ENC -1
#define LCD_SDSS SDSS
#ifndef SD_DETECT_PIN
#define SD_DETECT_PIN EXP2_07_PIN
#endif
#elif EITHER(VIKI2, miniVIKI)
@ -748,7 +752,9 @@
#define BTN_EN2 7
#define BTN_ENC AUX4_08_PIN
#ifndef SD_DETECT_PIN
#define SD_DETECT_PIN -1 // Pin 49 for display SD interface, 72 for easy adapter board
#endif
#define KILL_PIN EXP2_03_PIN
#elif ENABLED(ELB_FULL_GRAPHIC_CONTROLLER)
@ -764,7 +770,9 @@
#define BTN_ENC EXP2_03_PIN
#define LCD_SDSS SDSS
#ifndef SD_DETECT_PIN
#define SD_DETECT_PIN EXP2_07_PIN
#endif
#define KILL_PIN EXP2_08_PIN
#elif EITHER(MKS_MINI_12864, FYSETC_MINI_12864)
@ -833,7 +841,9 @@
#define BTN_EN2 AUX2_04_PIN
#define BTN_ENC AUX2_03_PIN
#ifndef SD_DETECT_PIN
#define SD_DETECT_PIN AUX3_02_PIN
#endif
#define KILL_PIN AUX2_05_PIN
#elif ENABLED(ZONESTAR_LCD)
@ -848,7 +858,9 @@
#define BEEPER_PIN EXP1_01_PIN
#ifndef SD_DETECT_PIN
#define SD_DETECT_PIN EXP2_07_PIN
#endif
#define KILL_PIN EXP2_08_PIN
#define BTN_EN1 EXP2_05_PIN
@ -857,7 +869,9 @@
#elif IS_TFTGLCD_PANEL
#ifndef SD_DETECT_PIN
#define SD_DETECT_PIN EXP2_07_PIN
#endif
#else
@ -876,7 +890,7 @@
#endif
#endif // IS_NEWPANEL
#endif // HAS_WIRED_LCD
#endif // HAS_WIRED_LCD && !LCD_PINS_DEFINED
#if IS_RRW_KEYPAD && !HAS_ADC_BUTTONS
#define SHIFT_OUT_PIN AUX2_06_PIN
@ -933,7 +947,9 @@
#define BEEPER_PIN EXP1_01_PIN
#ifndef SD_DETECT_PIN
#define SD_DETECT_PIN EXP2_07_PIN
#endif
#define CLCD_MOD_RESET EXP2_05_PIN
#define CLCD_SPI_CS EXP2_03_PIN

View File

@ -26,7 +26,9 @@
* V2 and V3 Boards only differ in USB controller, nothing affecting the pins.
*/
#include "pins_MKS_GEN_13.h" // ... RAMPS
#ifndef FILWIDTH_PIN
#define FILWIDTH_PIN 11 // Analog Input
#endif
//
// Auto fans
@ -44,27 +46,7 @@
#define E3_AUTO_FAN_PIN 6
#endif
#ifndef FILWIDTH_PIN
#define FILWIDTH_PIN 11 // Analog Input
#endif
#if ENABLED(ZONESTAR_LCD)
#undef LCD_PINS_RS
#undef LCD_PINS_ENABLE
#undef LCD_PINS_D4
#undef LCD_PINS_D5
#undef LCD_PINS_D6
#undef LCD_PINS_D7
#undef ADC_KEYPAD_PIN
#undef BEEPER_PIN
#undef SHIFT_OUT_PIN
#undef SHIFT_CLK_PIN
#undef SHIFT_LD_PIN
#undef BTN_EN1
#undef BTN_EN2
#undef BTN_ENC
#define LCD_PINS_RS 16
#define LCD_PINS_ENABLE 17
#define LCD_PINS_D4 23
@ -73,4 +55,8 @@
#define LCD_PINS_D7 29
#define ADC_KEYPAD_PIN 10 // Analog Input
#define BEEPER_PIN 37
#define LCD_PINS_DEFINED
#endif
#include "pins_MKS_GEN_13.h" // ... RAMPS

View File

@ -27,4 +27,6 @@
#define BOARD_INFO_NAME "Azteeg X1"
#define FAN_PIN 4
#include "pins_SANGUINOLOLU_12.h" // ... SANGUINOLOLU_11

View File

@ -29,7 +29,9 @@
#define BOARD_INFO_NAME "Melzi"
#endif
#define IS_MELZI 1
#ifndef FAN_PIN
#define FAN_PIN 4
#endif
// Alter timing for graphical display
#if IS_U8GLIB_ST7920

View File

@ -42,25 +42,20 @@
#define BOARD_ST7920_DELAY_3 125
#endif
#include "pins_MELZI.h" // ... SANGUINOLOLU_12 ... SANGUINOLOLU_11
//
// For the stock CR-10 enable CR10_STOCKDISPLAY in Configuration.h
//
#undef LCD_SDSS
#undef LED_PIN
#undef LCD_PINS_RS
#undef LCD_PINS_ENABLE
#undef LCD_PINS_D4
#undef LCD_PINS_D5
#undef LCD_PINS_D6
#undef LCD_PINS_D7
#if ENABLED(CR10_STOCKDISPLAY)
#define LCD_SDSS 31 // Smart Controller SD card reader (rather than the Melzi)
#define LCD_PINS_RS 28 // ST9720 CS
#define LCD_PINS_ENABLE 17 // ST9720 DAT
#define LCD_PINS_D4 30 // ST9720 CLK
#define LCD_PINS_DEFINED
#endif
#include "pins_MELZI.h" // ... SANGUINOLOLU_12 ... SANGUINOLOLU_11
#if ENABLED(BLTOUCH)
#ifndef SERVO0_PIN
#define SERVO0_PIN 27

View File

@ -27,19 +27,15 @@
#define BOARD_INFO_NAME "Melzi (Malyan)"
#include "pins_MELZI.h" // ... SANGUINOLOLU_12 ... SANGUINOLOLU_11
#undef LCD_SDSS
#undef LCD_PINS_RS
#undef LCD_PINS_ENABLE
#undef LCD_PINS_D4
#undef BTN_EN1
#undef BTN_EN2
#undef BTN_ENC
#if ENABLED(CR10_STOCKDISPLAY)
#define LCD_PINS_RS 17 // ST9720 CS
#define LCD_PINS_ENABLE 16 // ST9720 DAT
#define LCD_PINS_D4 11 // ST9720 CLK
#define BTN_EN1 30
#define BTN_EN2 29
#define BTN_ENC 28
#define LCD_PINS_DEFINED
#endif
#include "pins_MELZI.h" // ... SANGUINOLOLU_12 ... SANGUINOLOLU_11

View File

@ -27,28 +27,11 @@
#define BOARD_INFO_NAME "Melzi (Tronxy)"
// Alter timing for graphical display
#if IS_U8GLIB_ST7920
#define BOARD_ST7920_DELAY_1 0
#define BOARD_ST7920_DELAY_2 125
#define BOARD_ST7920_DELAY_3 0
#endif
#include "pins_MELZI.h" // ... SANGUINOLOLU_12 ... SANGUINOLOLU_11
#undef Z_ENABLE_PIN
#undef LCD_PINS_RS
#undef LCD_PINS_ENABLE
#undef LCD_PINS_D4
#undef LCD_PINS_D5
#undef LCD_PINS_D6
#undef LCD_PINS_D7
#undef BTN_EN1
#undef BTN_EN2
#undef BTN_ENC
#undef LCD_SDSS
#define Z_ENABLE_PIN 14
#define LCD_SDSS -1
#if ENABLED(CR10_STOCKDISPLAY)
#define LCD_PINS_RS 30
#define LCD_PINS_ENABLE 28
#define LCD_PINS_D4 16
@ -58,3 +41,15 @@
#define BTN_EN1 10
#define BTN_EN2 11
#define BTN_ENC 26
#define LCD_PINS_DEFINED
#endif
// Alter timing for graphical display
#if IS_U8GLIB_ST7920
#define BOARD_ST7920_DELAY_1 0
#define BOARD_ST7920_DELAY_2 125
#define BOARD_ST7920_DELAY_3 0
#endif
#include "pins_MELZI.h" // ... SANGUINOLOLU_12 ... SANGUINOLOLU_11

View File

@ -90,30 +90,18 @@
//
#define HEATER_0_PIN 13 // (extruder)
#if ENABLED(SANGUINOLOLU_V_1_2)
#define HEATER_BED_PIN 12 // (bed)
#define X_ENABLE_PIN 14
#define Y_ENABLE_PIN 14
#define Z_ENABLE_PIN 26
#define E0_ENABLE_PIN 14
#if !defined(FAN_PIN) && ENABLED(LCD_I2C_PANELOLU2)
#define FAN_PIN 4 // Uses Transistor1 (PWM) on Panelolu2's Sanguino Adapter Board to drive the fan
#ifndef FAN_PIN
#define FAN_PIN 4 // Works for Panelolu2 too
#endif
#else
#if DISABLED(SANGUINOLOLU_V_1_2)
#define HEATER_BED_PIN 14 // (bed)
#define X_ENABLE_PIN 4
#define Y_ENABLE_PIN 4
#ifndef Z_ENABLE_PIN
#define Z_ENABLE_PIN 4
#define E0_ENABLE_PIN 4
#endif
#if !defined(FAN_PIN) && (MB(AZTEEG_X1, STB_11) || IS_MELZI)
#define FAN_PIN 4 // Works for Panelolu2 too
#define E0_ENABLE_PIN 4
#endif
//
@ -151,7 +139,7 @@
//
// LCD / Controller
//
#if HAS_WIRED_LCD
#if HAS_WIRED_LCD && DISABLED(LCD_PINS_DEFINED)
#define SD_DETECT_PIN -1
@ -245,7 +233,9 @@
#if IS_MELZI
#define BTN_ENC 29
#ifndef LCD_SDSS
#define LCD_SDSS 30 // Panelolu2 SD card reader rather than the Melzi
#endif
#else
#define BTN_ENC 30
#endif
@ -253,7 +243,9 @@
#else // !LCD_FOR_MELZI && !ZONESTAR_LCD && !LCD_I2C_PANELOLU2
#define BTN_ENC 16
#ifndef LCD_SDSS
#define LCD_SDSS 28 // Smart Controller SD card reader rather than the Melzi
#endif
#endif

View File

@ -38,5 +38,17 @@
#define BOARD_INFO_NAME "Sanguinololu 1.2"
#endif
#define HEATER_BED_PIN 12 // (bed)
#define X_ENABLE_PIN 14
#define Y_ENABLE_PIN 14
#ifndef Z_ENABLE_PIN
#define Z_ENABLE_PIN 26
#endif
#define E0_ENABLE_PIN 14
#if !defined(FAN_PIN) && ENABLED(LCD_I2C_PANELOLU2)
#define FAN_PIN 4 // Uses Transistor1 (PWM) on Panelolu2's Sanguino Adapter Board to drive the fan
#endif
#define SANGUINOLOLU_V_1_2
#include "pins_SANGUINOLOLU_11.h"

View File

@ -27,4 +27,8 @@
#define BOARD_INFO_NAME "STB V1.1"
#ifndef FAN_PIN
#define FAN_PIN 4 // Works for Panelolu2 too
#endif
#include "pins_SANGUINOLOLU_12.h" // ... SANGUINOLOLU_11