My Marlin configs for Fabrikator Mini and CTC i3 Pro B
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

pins_RAMPS.h 18KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721
  1. /**
  2. * Marlin 3D Printer Firmware
  3. * Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
  4. *
  5. * Based on Sprinter and grbl.
  6. * Copyright (c) 2011 Camiel Gubbels / Erik van der Zalm
  7. *
  8. * This program is free software: you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License as published by
  10. * the Free Software Foundation, either version 3 of the License, or
  11. * (at your option) any later version.
  12. *
  13. * This program is distributed in the hope that it will be useful,
  14. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  15. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  16. * GNU General Public License for more details.
  17. *
  18. * You should have received a copy of the GNU General Public License
  19. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  20. *
  21. */
  22. #pragma once
  23. /**
  24. * Arduino Mega with RAMPS v1.4 (or v1.3) pin assignments
  25. *
  26. * Applies to the following boards:
  27. *
  28. * RAMPS_14_EFB (Hotend, Fan, Bed)
  29. * RAMPS_14_EEB (Hotend0, Hotend1, Bed)
  30. * RAMPS_14_EFF (Hotend, Fan0, Fan1)
  31. * RAMPS_14_EEF (Hotend0, Hotend1, Fan)
  32. * RAMPS_14_SF (Spindle, Controller Fan)
  33. *
  34. * RAMPS_13_EFB (Hotend, Fan, Bed)
  35. * RAMPS_13_EEB (Hotend0, Hotend1, Bed)
  36. * RAMPS_13_EFF (Hotend, Fan0, Fan1)
  37. * RAMPS_13_EEF (Hotend0, Hotend1, Fan)
  38. * RAMPS_13_SF (Spindle, Controller Fan)
  39. *
  40. * Other pins_MYBOARD.h files may override these defaults
  41. *
  42. * Differences between
  43. * RAMPS_13 | RAMPS_14
  44. * 7 | 11
  45. */
  46. #ifdef TARGET_LPC1768
  47. #error "Oops! Set MOTHERBOARD to an LPC1768-based board when building for LPC1768."
  48. #elif defined(__STM32F1__)
  49. #error "Oops! Set MOTHERBOARD to an STM32F1-based board when building for STM32F1."
  50. #endif
  51. #if NONE(IS_RAMPS_SMART, IS_RAMPS_DUO, IS_RAMPS4DUE, TARGET_LPC1768)
  52. #if !defined(__AVR_ATmega1280__) && !defined(__AVR_ATmega2560__)
  53. #error "Oops! Select 'Arduino/Genuino Mega or Mega 2560' in 'Tools > Board.'"
  54. #endif
  55. #endif
  56. #ifndef BOARD_INFO_NAME
  57. #define BOARD_INFO_NAME "RAMPS 1.4"
  58. #endif
  59. //
  60. // Servos
  61. //
  62. #ifndef SERVO0_PIN
  63. #ifdef IS_RAMPS_13
  64. #define SERVO0_PIN 7
  65. #else
  66. #define SERVO0_PIN 11
  67. #endif
  68. #endif
  69. #ifndef SERVO1_PIN
  70. #define SERVO1_PIN 6
  71. #endif
  72. #ifndef SERVO2_PIN
  73. #define SERVO2_PIN 5
  74. #endif
  75. #ifndef SERVO3_PIN
  76. #define SERVO3_PIN 4
  77. #endif
  78. //
  79. // Limit Switches
  80. //
  81. #ifndef X_STOP_PIN
  82. #ifndef X_MIN_PIN
  83. #define X_MIN_PIN 3
  84. #endif
  85. #ifndef X_MAX_PIN
  86. #define X_MAX_PIN 2
  87. #endif
  88. #endif
  89. #ifndef Y_STOP_PIN
  90. #ifndef Y_MIN_PIN
  91. #define Y_MIN_PIN 14
  92. #endif
  93. #ifndef Y_MAX_PIN
  94. #define Y_MAX_PIN 15
  95. #endif
  96. #endif
  97. #ifndef Z_STOP_PIN
  98. #ifndef Z_MIN_PIN
  99. #define Z_MIN_PIN 18
  100. #endif
  101. #ifndef Z_MAX_PIN
  102. #define Z_MAX_PIN 19
  103. #endif
  104. #endif
  105. //
  106. // Z Probe (when not Z_MIN_PIN)
  107. //
  108. #ifndef Z_MIN_PROBE_PIN
  109. #define Z_MIN_PROBE_PIN 32
  110. #endif
  111. //
  112. // Steppers
  113. //
  114. #define X_STEP_PIN 54
  115. #define X_DIR_PIN 55
  116. #define X_ENABLE_PIN 38
  117. #ifndef X_CS_PIN
  118. #define X_CS_PIN 53
  119. #endif
  120. #define Y_STEP_PIN 60
  121. #define Y_DIR_PIN 61
  122. #define Y_ENABLE_PIN 56
  123. #ifndef Y_CS_PIN
  124. #define Y_CS_PIN 49
  125. #endif
  126. #define Z_STEP_PIN 46
  127. #define Z_DIR_PIN 48
  128. #define Z_ENABLE_PIN 62
  129. #ifndef Z_CS_PIN
  130. #define Z_CS_PIN 40
  131. #endif
  132. #define E0_STEP_PIN 26
  133. #define E0_DIR_PIN 28
  134. #define E0_ENABLE_PIN 24
  135. #ifndef E0_CS_PIN
  136. #define E0_CS_PIN 42
  137. #endif
  138. #define E1_STEP_PIN 36
  139. #define E1_DIR_PIN 34
  140. #define E1_ENABLE_PIN 30
  141. #ifndef E1_CS_PIN
  142. #define E1_CS_PIN 44
  143. #endif
  144. //
  145. // Temperature Sensors
  146. //
  147. #ifndef TEMP_0_PIN
  148. #define TEMP_0_PIN 13 // Analog Input
  149. #endif
  150. #ifndef TEMP_1_PIN
  151. #define TEMP_1_PIN 15 // Analog Input
  152. #endif
  153. #ifndef TEMP_BED_PIN
  154. #define TEMP_BED_PIN 14 // Analog Input
  155. #endif
  156. // SPI for Max6675 or Max31855 Thermocouple
  157. #if DISABLED(SDSUPPORT)
  158. #define MAX6675_SS_PIN 66 // Don't use 53 if using Display/SD card
  159. #else
  160. #define MAX6675_SS_PIN 66 // Don't use 49 (SD_DETECT_PIN)
  161. #endif
  162. //
  163. // Augmentation for auto-assigning RAMPS plugs
  164. //
  165. #if NONE(IS_RAMPS_EEB, IS_RAMPS_EEF, IS_RAMPS_EFB, IS_RAMPS_EFF, IS_RAMPS_SF) && !PIN_EXISTS(MOSFET_D)
  166. #if HOTENDS > 1
  167. #if TEMP_SENSOR_BED
  168. #define IS_RAMPS_EEB
  169. #else
  170. #define IS_RAMPS_EEF
  171. #endif
  172. #elif TEMP_SENSOR_BED
  173. #define IS_RAMPS_EFB
  174. #else
  175. #define IS_RAMPS_EFF
  176. #endif
  177. #endif
  178. //
  179. // Heaters / Fans
  180. //
  181. #ifndef MOSFET_D_PIN
  182. #define MOSFET_D_PIN -1
  183. #endif
  184. #ifndef RAMPS_D8_PIN
  185. #define RAMPS_D8_PIN 8
  186. #endif
  187. #ifndef RAMPS_D9_PIN
  188. #define RAMPS_D9_PIN 9
  189. #endif
  190. #ifndef RAMPS_D10_PIN
  191. #define RAMPS_D10_PIN 10
  192. #endif
  193. #define HEATER_0_PIN RAMPS_D10_PIN
  194. #if ENABLED(IS_RAMPS_EFB) // Hotend, Fan, Bed
  195. #define HEATER_BED_PIN RAMPS_D8_PIN
  196. #elif ENABLED(IS_RAMPS_EEF) // Hotend, Hotend, Fan
  197. #define HEATER_1_PIN RAMPS_D9_PIN
  198. #elif ENABLED(IS_RAMPS_EEB) // Hotend, Hotend, Bed
  199. #define HEATER_1_PIN RAMPS_D9_PIN
  200. #define HEATER_BED_PIN RAMPS_D8_PIN
  201. #elif ENABLED(IS_RAMPS_EFF) // Hotend, Fan, Fan
  202. #define FAN1_PIN RAMPS_D8_PIN
  203. #elif DISABLED(IS_RAMPS_SF) // Not Spindle, Fan (i.e., "EFBF" or "EFBE")
  204. #define HEATER_BED_PIN RAMPS_D8_PIN
  205. #if HOTENDS == 1
  206. #define FAN1_PIN MOSFET_D_PIN
  207. #else
  208. #define HEATER_1_PIN MOSFET_D_PIN
  209. #endif
  210. #endif
  211. #ifndef FAN_PIN
  212. #if EITHER(IS_RAMPS_EFB, IS_RAMPS_EFF) // Hotend, Fan, Bed or Hotend, Fan, Fan
  213. #define FAN_PIN 7 // RAMPS_D9_PIN
  214. #elif EITHER(IS_RAMPS_EEF, IS_RAMPS_SF) // Hotend, Hotend, Fan or Spindle, Fan
  215. #define FAN_PIN RAMPS_D8_PIN
  216. #elif ENABLED(IS_RAMPS_EEB) // Hotend, Hotend, Bed
  217. #define FAN_PIN 4 // IO pin. Buffer needed
  218. #else // Non-specific are "EFB" (i.e., "EFBF" or "EFBE")
  219. #define FAN_PIN RAMPS_D9_PIN
  220. #endif
  221. #endif
  222. //
  223. // Misc. Functions
  224. //
  225. #define SDSS 53
  226. #define LED_PIN 13
  227. #ifndef FILWIDTH_PIN
  228. #define FILWIDTH_PIN 5 // Analog Input on AUX2
  229. #endif
  230. // RAMPS 1.4 DIO 4 on the servos connector
  231. #ifndef FIL_RUNOUT_PIN
  232. #define FIL_RUNOUT_PIN 4
  233. #endif
  234. #ifndef PS_ON_PIN
  235. #define PS_ON_PIN 12
  236. #endif
  237. #if ENABLED(CASE_LIGHT_ENABLE) && !defined(CASE_LIGHT_PIN) && !defined(SPINDLE_LASER_ENA_PIN)
  238. #if NUM_SERVOS <= 1 // Prefer the servo connector
  239. #define CASE_LIGHT_PIN 6 // Hardware PWM
  240. #elif HAS_FREE_AUX2_PINS
  241. #define CASE_LIGHT_PIN 44 // Hardware PWM
  242. #endif
  243. #endif
  244. //
  245. // M3/M4/M5 - Spindle/Laser Control
  246. //
  247. #if HAS_CUTTER && !defined(SPINDLE_LASER_ENA_PIN)
  248. #if !NUM_SERVOS // Use servo connector if possible
  249. #define SPINDLE_LASER_ENA_PIN 4 // Pullup or pulldown!
  250. #define SPINDLE_LASER_PWM_PIN 6 // Hardware PWM
  251. #define SPINDLE_DIR_PIN 5
  252. #elif HAS_FREE_AUX2_PINS
  253. #define SPINDLE_LASER_ENA_PIN 40 // Pullup or pulldown!
  254. #define SPINDLE_LASER_PWM_PIN 44 // Hardware PWM
  255. #define SPINDLE_DIR_PIN 65
  256. #else
  257. #error "No auto-assignable Spindle/Laser pins available."
  258. #endif
  259. #endif
  260. //
  261. // TMC software SPI
  262. //
  263. #if ENABLED(TMC_USE_SW_SPI)
  264. #ifndef TMC_SW_MOSI
  265. #define TMC_SW_MOSI 66
  266. #endif
  267. #ifndef TMC_SW_MISO
  268. #define TMC_SW_MISO 44
  269. #endif
  270. #ifndef TMC_SW_SCK
  271. #define TMC_SW_SCK 64
  272. #endif
  273. #endif
  274. #if HAS_TMC220x
  275. /**
  276. * TMC2208/TMC2209 stepper drivers
  277. *
  278. * Hardware serial communication ports.
  279. * If undefined software serial is used according to the pins below
  280. */
  281. //#define X_HARDWARE_SERIAL Serial1
  282. //#define X2_HARDWARE_SERIAL Serial1
  283. //#define Y_HARDWARE_SERIAL Serial1
  284. //#define Y2_HARDWARE_SERIAL Serial1
  285. //#define Z_HARDWARE_SERIAL Serial1
  286. //#define Z2_HARDWARE_SERIAL Serial1
  287. //#define E0_HARDWARE_SERIAL Serial1
  288. //#define E1_HARDWARE_SERIAL Serial1
  289. //#define E2_HARDWARE_SERIAL Serial1
  290. //#define E3_HARDWARE_SERIAL Serial1
  291. //#define E4_HARDWARE_SERIAL Serial1
  292. //
  293. // Software serial
  294. //
  295. #ifndef X_SERIAL_TX_PIN
  296. #define X_SERIAL_TX_PIN 40
  297. #endif
  298. #ifndef X_SERIAL_RX_PIN
  299. #define X_SERIAL_RX_PIN 63
  300. #endif
  301. #ifndef X2_SERIAL_TX_PIN
  302. #define X2_SERIAL_TX_PIN -1
  303. #endif
  304. #ifndef X2_SERIAL_RX_PIN
  305. #define X2_SERIAL_RX_PIN -1
  306. #endif
  307. #ifndef Y_SERIAL_TX_PIN
  308. #define Y_SERIAL_TX_PIN 59
  309. #endif
  310. #ifndef Y_SERIAL_RX_PIN
  311. #define Y_SERIAL_RX_PIN 64
  312. #endif
  313. #ifndef Y2_SERIAL_TX_PIN
  314. #define Y2_SERIAL_TX_PIN -1
  315. #endif
  316. #ifndef Y2_SERIAL_RX_PIN
  317. #define Y2_SERIAL_RX_PIN -1
  318. #endif
  319. #ifndef Z_SERIAL_TX_PIN
  320. #define Z_SERIAL_TX_PIN 42
  321. #endif
  322. #ifndef Z_SERIAL_RX_PIN
  323. #define Z_SERIAL_RX_PIN 65
  324. #endif
  325. #ifndef Z2_SERIAL_TX_PIN
  326. #define Z2_SERIAL_TX_PIN -1
  327. #endif
  328. #ifndef Z2_SERIAL_RX_PIN
  329. #define Z2_SERIAL_RX_PIN -1
  330. #endif
  331. #ifndef E0_SERIAL_TX_PIN
  332. #define E0_SERIAL_TX_PIN 44
  333. #endif
  334. #ifndef E0_SERIAL_RX_PIN
  335. #define E0_SERIAL_RX_PIN 66
  336. #endif
  337. #ifndef E1_SERIAL_TX_PIN
  338. #define E1_SERIAL_TX_PIN -1
  339. #endif
  340. #ifndef E1_SERIAL_RX_PIN
  341. #define E1_SERIAL_RX_PIN -1
  342. #endif
  343. #ifndef E2_SERIAL_TX_PIN
  344. #define E2_SERIAL_TX_PIN -1
  345. #endif
  346. #ifndef E2_SERIAL_RX_PIN
  347. #define E2_SERIAL_RX_PIN -1
  348. #endif
  349. #ifndef E3_SERIAL_TX_PIN
  350. #define E3_SERIAL_TX_PIN -1
  351. #endif
  352. #ifndef E3_SERIAL_RX_PIN
  353. #define E3_SERIAL_RX_PIN -1
  354. #endif
  355. #ifndef E4_SERIAL_TX_PIN
  356. #define E4_SERIAL_TX_PIN -1
  357. #endif
  358. #ifndef E4_SERIAL_RX_PIN
  359. #define E4_SERIAL_RX_PIN -1
  360. #endif
  361. #ifndef E5_SERIAL_TX_PIN
  362. #define E5_SERIAL_TX_PIN -1
  363. #endif
  364. #ifndef E5_SERIAL_RX_PIN
  365. #define E5_SERIAL_RX_PIN -1
  366. #endif
  367. #ifndef E6_SERIAL_TX_PIN
  368. #define E6_SERIAL_TX_PIN -1
  369. #endif
  370. #ifndef E6_SERIAL_RX_PIN
  371. #define E6_SERIAL_RX_PIN -1
  372. #endif
  373. #ifndef E7_SERIAL_TX_PIN
  374. #define E7_SERIAL_TX_PIN -1
  375. #endif
  376. #ifndef E7_SERIAL_RX_PIN
  377. #define E7_SERIAL_RX_PIN -1
  378. #endif
  379. #endif
  380. //
  381. // Průša i3 MK2 Multiplexer Support
  382. //
  383. #ifndef E_MUX0_PIN
  384. #define E_MUX0_PIN 40 // Z_CS_PIN
  385. #endif
  386. #ifndef E_MUX1_PIN
  387. #define E_MUX1_PIN 42 // E0_CS_PIN
  388. #endif
  389. #ifndef E_MUX2_PIN
  390. #define E_MUX2_PIN 44 // E1_CS_PIN
  391. #endif
  392. //////////////////////////
  393. // LCDs and Controllers //
  394. //////////////////////////
  395. #if HAS_SPI_LCD
  396. //
  397. // LCD Display output pins
  398. //
  399. #if ENABLED(REPRAPWORLD_GRAPHICAL_LCD)
  400. #define LCD_PINS_RS 49 // CS chip select /SS chip slave select
  401. #define LCD_PINS_ENABLE 51 // SID (MOSI)
  402. #define LCD_PINS_D4 52 // SCK (CLK) clock
  403. #elif BOTH(NEWPANEL, PANEL_ONE)
  404. #define LCD_PINS_RS 40
  405. #define LCD_PINS_ENABLE 42
  406. #define LCD_PINS_D4 65
  407. #define LCD_PINS_D5 66
  408. #define LCD_PINS_D6 44
  409. #define LCD_PINS_D7 64
  410. #else
  411. #if ENABLED(CR10_STOCKDISPLAY)
  412. #define LCD_PINS_RS 27
  413. #define LCD_PINS_ENABLE 29
  414. #define LCD_PINS_D4 25
  415. #if DISABLED(NEWPANEL)
  416. #define BEEPER_PIN 37
  417. #endif
  418. #elif ENABLED(ZONESTAR_LCD)
  419. #define LCD_PINS_RS 64
  420. #define LCD_PINS_ENABLE 44
  421. #define LCD_PINS_D4 63
  422. #define LCD_PINS_D5 40
  423. #define LCD_PINS_D6 42
  424. #define LCD_PINS_D7 65
  425. #else
  426. #if EITHER(MKS_12864OLED, MKS_12864OLED_SSD1306)
  427. #define LCD_PINS_DC 25 // Set as output on init
  428. #define LCD_PINS_RS 27 // Pull low for 1s to init
  429. // DOGM SPI LCD Support
  430. #define DOGLCD_CS 16
  431. #define DOGLCD_MOSI 17
  432. #define DOGLCD_SCK 23
  433. #define DOGLCD_A0 LCD_PINS_DC
  434. #else
  435. #define LCD_PINS_RS 16
  436. #define LCD_PINS_ENABLE 17
  437. #define LCD_PINS_D4 23
  438. #define LCD_PINS_D5 25
  439. #define LCD_PINS_D6 27
  440. #endif
  441. #define LCD_PINS_D7 29
  442. #if DISABLED(NEWPANEL)
  443. #define BEEPER_PIN 33
  444. #endif
  445. #endif
  446. #if DISABLED(NEWPANEL)
  447. // Buttons attached to a shift register
  448. // Not wired yet
  449. //#define SHIFT_CLK 38
  450. //#define SHIFT_LD 42
  451. //#define SHIFT_OUT 40
  452. //#define SHIFT_EN 17
  453. #endif
  454. #endif
  455. //
  456. // LCD Display input pins
  457. //
  458. #if ENABLED(NEWPANEL)
  459. #if ENABLED(REPRAP_DISCOUNT_SMART_CONTROLLER)
  460. #define BEEPER_PIN 37
  461. #if ENABLED(CR10_STOCKDISPLAY)
  462. #define BTN_EN1 17
  463. #define BTN_EN2 23
  464. #else
  465. #define BTN_EN1 31
  466. #define BTN_EN2 33
  467. #endif
  468. #define BTN_ENC 35
  469. #ifndef SD_DETECT_PIN
  470. #define SD_DETECT_PIN 49
  471. #endif
  472. #ifndef KILL_PIN
  473. #define KILL_PIN 41
  474. #endif
  475. #if ENABLED(BQ_LCD_SMART_CONTROLLER)
  476. #define LCD_BACKLIGHT_PIN 39
  477. #endif
  478. #elif ENABLED(REPRAPWORLD_GRAPHICAL_LCD)
  479. #define BTN_EN1 64
  480. #define BTN_EN2 59
  481. #define BTN_ENC 63
  482. #define SD_DETECT_PIN 42
  483. #elif ENABLED(LCD_I2C_PANELOLU2)
  484. #define BTN_EN1 47
  485. #define BTN_EN2 43
  486. #define BTN_ENC 32
  487. #define LCD_SDSS SDSS
  488. #define KILL_PIN 41
  489. #elif ENABLED(LCD_I2C_VIKI)
  490. #define BTN_EN1 40 // http://files.panucatt.com/datasheets/viki_wiring_diagram.pdf explains 40/42.
  491. #define BTN_EN2 42
  492. #define BTN_ENC -1
  493. #define LCD_SDSS SDSS
  494. #define SD_DETECT_PIN 49
  495. #elif ANY(VIKI2, miniVIKI)
  496. #define DOGLCD_CS 45
  497. #define DOGLCD_A0 44
  498. #define LCD_SCREEN_ROT_180
  499. #define BEEPER_PIN 33
  500. #define STAT_LED_RED_PIN 32
  501. #define STAT_LED_BLUE_PIN 35
  502. #define BTN_EN1 22
  503. #define BTN_EN2 7
  504. #define BTN_ENC 39
  505. #define SD_DETECT_PIN -1 // Pin 49 for display SD interface, 72 for easy adapter board
  506. #define KILL_PIN 31
  507. #elif ENABLED(ELB_FULL_GRAPHIC_CONTROLLER)
  508. #define DOGLCD_CS 29
  509. #define DOGLCD_A0 27
  510. #define BEEPER_PIN 23
  511. #define LCD_BACKLIGHT_PIN 33
  512. #define BTN_EN1 35
  513. #define BTN_EN2 37
  514. #define BTN_ENC 31
  515. #define LCD_SDSS SDSS
  516. #define SD_DETECT_PIN 49
  517. #define KILL_PIN 41
  518. #elif EITHER(MKS_MINI_12864, FYSETC_MINI_12864)
  519. #define BEEPER_PIN 37
  520. #define BTN_ENC 35
  521. #define SD_DETECT_PIN 49
  522. #ifndef KILL_PIN
  523. #define KILL_PIN 41
  524. #endif
  525. #if ENABLED(MKS_MINI_12864) // Added in Marlin 1.1.6
  526. #define DOGLCD_A0 27
  527. #define DOGLCD_CS 25
  528. // GLCD features
  529. // Uncomment screen orientation
  530. //#define LCD_SCREEN_ROT_90
  531. //#define LCD_SCREEN_ROT_180
  532. //#define LCD_SCREEN_ROT_270
  533. // not connected to a pin
  534. #define LCD_BACKLIGHT_PIN -1 // 65 (MKS mini12864 can't adjust backlight by software!)
  535. #define BTN_EN1 31
  536. #define BTN_EN2 33
  537. #elif ENABLED(FYSETC_MINI_12864)
  538. // From https://wiki.fysetc.com/Mini12864_Panel/?fbclid=IwAR1FyjuNdVOOy9_xzky3qqo_WeM5h-4gpRnnWhQr_O1Ef3h0AFnFXmCehK8
  539. #define DOGLCD_A0 16
  540. #define DOGLCD_CS 17
  541. #define BTN_EN1 33
  542. #define BTN_EN2 31
  543. //#define FORCE_SOFT_SPI // Use this if default of hardware SPI causes display problems
  544. // results in LCD soft SPI mode 3, SD soft SPI mode 0
  545. #define LCD_RESET_PIN 23 // Must be high or open for LCD to operate normally.
  546. #if EITHER(FYSETC_MINI_12864_1_2, FYSETC_MINI_12864_2_0)
  547. #ifndef RGB_LED_R_PIN
  548. #define RGB_LED_R_PIN 25
  549. #endif
  550. #ifndef RGB_LED_G_PIN
  551. #define RGB_LED_G_PIN 27
  552. #endif
  553. #ifndef RGB_LED_B_PIN
  554. #define RGB_LED_B_PIN 29
  555. #endif
  556. #elif ENABLED(FYSETC_MINI_12864_2_1)
  557. #define NEOPIXEL_PIN 25
  558. #endif
  559. #endif
  560. #elif ENABLED(MINIPANEL)
  561. #define BEEPER_PIN 42
  562. // not connected to a pin
  563. #define LCD_BACKLIGHT_PIN 65 // backlight LED on A11/D65
  564. #define DOGLCD_A0 44
  565. #define DOGLCD_CS 66
  566. // GLCD features
  567. // Uncomment screen orientation
  568. //#define LCD_SCREEN_ROT_90
  569. //#define LCD_SCREEN_ROT_180
  570. //#define LCD_SCREEN_ROT_270
  571. #define BTN_EN1 40
  572. #define BTN_EN2 63
  573. #define BTN_ENC 59
  574. #define SD_DETECT_PIN 49
  575. #define KILL_PIN 64
  576. #elif ENABLED(ZONESTAR_LCD)
  577. #define ADC_KEYPAD_PIN 12
  578. #elif ENABLED(AZSMZ_12864)
  579. // Pins only defined for RAMPS_SMART currently
  580. #else
  581. // Beeper on AUX-4
  582. #define BEEPER_PIN 33
  583. // Buttons are directly attached to AUX-2
  584. #if ENABLED(PANEL_ONE)
  585. #define BTN_EN1 59 // AUX2 PIN 3
  586. #define BTN_EN2 63 // AUX2 PIN 4
  587. #define BTN_ENC 49 // AUX3 PIN 7
  588. #else
  589. #define BTN_EN1 37
  590. #define BTN_EN2 35
  591. #define BTN_ENC 31
  592. #endif
  593. #if ENABLED(G3D_PANEL)
  594. #define SD_DETECT_PIN 49
  595. #define KILL_PIN 41
  596. #endif
  597. #endif
  598. #endif // NEWPANEL
  599. #endif // HAS_SPI_LCD
  600. #if ENABLED(REPRAPWORLD_KEYPAD)
  601. #define SHIFT_OUT 40
  602. #define SHIFT_CLK 44
  603. #define SHIFT_LD 42
  604. #ifndef BTN_EN1
  605. #define BTN_EN1 64
  606. #endif
  607. #ifndef BTN_EN2
  608. #define BTN_EN2 59
  609. #endif
  610. #ifndef BTN_ENC
  611. #define BTN_ENC 63
  612. #endif
  613. #endif