My Marlin configs for Fabrikator Mini and CTC i3 Pro B
選択できるのは25トピックまでです。 トピックは、先頭が英数字で、英数字とダッシュ('-')を使用した35文字以内のものにしてください。

pins_RURAMPS4D_11.h 9.8KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299
  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 <https://www.gnu.org/licenses/>.
  20. *
  21. * Ported sys0724 & Vynt
  22. */
  23. #pragma once
  24. /**
  25. * Arduino Mega? or Due with RuRAMPS4DUE pin assignments
  26. *
  27. * Applies to the following boards:
  28. * RURAMPS4DUE (Hotend0, Hotend1, Hotend2, Fan0, Fan1, Bed)
  29. *
  30. * Differences between
  31. * RADDS | RuRAMPS4DUE
  32. * |
  33. */
  34. #include "env_validate.h"
  35. #define BOARD_INFO_NAME "RuRAMPS4Due v1.1"
  36. //
  37. // Servos
  38. //
  39. #define SERVO0_PIN 5
  40. #define SERVO1_PIN 3
  41. //
  42. // Limit Switches
  43. //
  44. #define X_MIN_PIN 45
  45. #define X_MAX_PIN 39
  46. #define Y_MIN_PIN 46
  47. #define Y_MAX_PIN 41
  48. #define Z_MIN_PIN 47
  49. #define Z_MAX_PIN 43
  50. //
  51. // Z Probe (when not Z_MIN_PIN)
  52. //
  53. #ifndef Z_MIN_PROBE_PIN
  54. #define Z_MIN_PROBE_PIN 43
  55. #endif
  56. //
  57. // Steppers
  58. //
  59. #define X_STEP_PIN 37 // Support Extension Board
  60. #define X_DIR_PIN 36
  61. #define X_ENABLE_PIN 38
  62. #ifndef X_CS_PIN
  63. #define X_CS_PIN -1
  64. #endif
  65. #define Y_STEP_PIN 32 // Support Extension Board
  66. #define Y_DIR_PIN 35
  67. #define Y_ENABLE_PIN 34
  68. #ifndef Y_CS_PIN
  69. #define Y_CS_PIN -1
  70. #endif
  71. #define Z_STEP_PIN 30 // Support Extension Board
  72. #define Z_DIR_PIN 2
  73. #define Z_ENABLE_PIN 33
  74. #ifndef Z_CS_PIN
  75. #define Z_CS_PIN -1
  76. #endif
  77. #define E0_STEP_PIN 29
  78. #define E0_DIR_PIN 28
  79. #define E0_ENABLE_PIN 31
  80. #ifndef E0_CS_PIN
  81. #define E0_CS_PIN -1
  82. #endif
  83. #define E1_STEP_PIN 22
  84. #define E1_DIR_PIN 24
  85. #define E1_ENABLE_PIN 26
  86. #ifndef E1_CS_PIN
  87. #define E1_CS_PIN -1
  88. #endif
  89. #define E2_STEP_PIN 25
  90. #define E2_DIR_PIN 23
  91. #define E2_ENABLE_PIN 27
  92. #ifndef E2_CS_PIN
  93. #define E2_CS_PIN -1
  94. #endif
  95. #define E3_STEP_PIN 15 // Only For Extension Board
  96. #define E3_DIR_PIN 14
  97. #define E3_ENABLE_PIN 61
  98. #ifndef E3_CS_PIN
  99. #define E3_CS_PIN -1
  100. #endif
  101. // For Future: Microstepping pins - Mapping not from fastio.h (?)
  102. //#define E3_MS1_PIN ?
  103. //#define E3_MS2_PIN ?
  104. //#define E3_MS3_PIN ?
  105. #ifndef FIL_RUNOUT_PIN
  106. #define FIL_RUNOUT_PIN Y_MIN_PIN
  107. #endif
  108. //
  109. // Heaters / Fans
  110. //
  111. #define HEATER_0_PIN 13
  112. #define HEATER_1_PIN 12
  113. #define HEATER_2_PIN 11
  114. #define HEATER_BED_PIN 7 // BED H1
  115. #ifndef FAN_PIN
  116. #define FAN_PIN 9
  117. #endif
  118. #define FAN1_PIN 8
  119. #define CONTROLLER_FAN_PIN -1
  120. //
  121. // Temperature Sensors
  122. //
  123. #define TEMP_0_PIN 0 // ANALOG A0
  124. #define TEMP_1_PIN 1 // ANALOG A1
  125. #define TEMP_2_PIN 2 // ANALOG A2
  126. #define TEMP_3_PIN 3 // ANALOG A3
  127. #define TEMP_BED_PIN 4 // ANALOG A4
  128. // The thermocouple uses Analog pins
  129. #if ENABLED(VER_WITH_THERMOCOUPLE) // Defined in Configuration.h
  130. #define TEMP_4_PIN 5 // A5
  131. #define TEMP_5_PIN 6 // A6 (Marlin 2.0 not support)
  132. #endif
  133. // SPI for MAX Thermocouple
  134. /*
  135. #if DISABLED(SDSUPPORT)
  136. #define TEMP_0_CS_PIN EXP1_03_PIN
  137. #else
  138. #define TEMP_0_CS_PIN 49
  139. #endif
  140. */
  141. //
  142. // Misc. Functions
  143. //
  144. #define SDSS 4 // 4,10,52 if using HW SPI.
  145. #define LED_PIN -1 // 13 - HEATER_0_PIN
  146. #define PS_ON_PIN -1 // 65
  147. // MKS TFT / Nextion Use internal USART-1
  148. #define TFT_LCD_MODULE_COM 1
  149. #define TFT_LCD_MODULE_BAUDRATE 115600
  150. // ESP WiFi Use internal USART-2
  151. #define ESP_WIFI_MODULE_COM 2
  152. #define ESP_WIFI_MODULE_BAUDRATE 115600
  153. #define ESP_WIFI_MODULE_RESET_PIN -1
  154. #define PIGGY_GPIO_PIN -1
  155. //
  156. // EEPROM
  157. //
  158. #define MARLIN_EEPROM_SIZE 0x8000 // 32K (24lc256)
  159. #define I2C_EEPROM // EEPROM on I2C-0
  160. //#define EEPROM_SD // EEPROM on SDCARD
  161. //#define SPI_EEPROM // EEPROM on SPI-0
  162. //#define SPI_CHAN_EEPROM1 ?
  163. //#define SPI_EEPROM1_CS_PIN ?
  164. // 2K EEPROM
  165. //#define SPI_EEPROM2_CS_PIN ?
  166. // 32Mb FLASH
  167. //#define SPI_FLASH_CS_PIN ?
  168. /**
  169. * ------ ------
  170. * (BEEPER) 62 |10 9 | 40 (BTN_ENC) (MISO) 74 |10 9 | 76 (SCK)
  171. * (LCD_EN) 64 | 8 7 | 63 (LCD_RS) (BTN_EN1) 44 | 8 7 | 10 (SD_SS)
  172. * (LCD_D4) 48 | 6 5 50 (LCD_D5) (BTN_EN2) 42 | 6 5 75 (MOSI)
  173. * (LCD_D6) 52 | 4 3 | 53 (LCD_D7) (SD_DETECT) 51 | 4 3 | RESET
  174. * GND | 2 1 | 5V GND | 2 1 | --
  175. * ------ ------
  176. * EXP1 EXP2
  177. */
  178. #define EXP1_03_PIN 53
  179. #define EXP1_04_PIN 52
  180. #define EXP1_05_PIN 50
  181. #define EXP1_06_PIN 48
  182. #define EXP1_07_PIN 63
  183. #define EXP1_08_PIN 64
  184. #define EXP1_09_PIN 40
  185. #define EXP1_10_PIN 62
  186. #define EXP2_03_PIN -1 // RESET
  187. #define EXP2_04_PIN 51
  188. #define EXP2_05_PIN 75 // MOSI
  189. #define EXP2_06_PIN 42
  190. #define EXP2_07_PIN 10
  191. #define EXP2_08_PIN 44
  192. #define EXP2_09_PIN 76 // SCK
  193. #define EXP2_10_PIN 74 // MISO
  194. //
  195. // LCD / Controller
  196. //
  197. #if HAS_WIRED_LCD
  198. #if ANY(RADDS_DISPLAY, IS_RRD_SC, IS_RRD_FG_SC)
  199. #define BEEPER_PIN EXP1_10_PIN
  200. #define LCD_PINS_D4 EXP1_06_PIN
  201. #define LCD_PINS_D5 EXP1_05_PIN
  202. #define LCD_PINS_D6 EXP1_04_PIN
  203. #define LCD_PINS_D7 EXP1_03_PIN
  204. #define SD_DETECT_PIN EXP2_04_PIN
  205. #endif
  206. #if EITHER(RADDS_DISPLAY, IS_RRD_SC)
  207. #define LCD_PINS_RS EXP1_07_PIN
  208. #define LCD_PINS_ENABLE EXP1_08_PIN
  209. #elif IS_RRD_FG_SC
  210. #define LCD_PINS_RS EXP1_04_PIN
  211. #define LCD_PINS_ENABLE EXP1_03_PIN
  212. #elif HAS_U8GLIB_I2C_OLED
  213. #define BEEPER_PIN EXP1_10_PIN
  214. #define LCD_SDSS EXP2_07_PIN
  215. #define SD_DETECT_PIN EXP2_04_PIN
  216. #elif ENABLED(FYSETC_MINI_12864)
  217. #define BEEPER_PIN EXP1_10_PIN
  218. #define DOGLCD_CS EXP1_08_PIN
  219. #define DOGLCD_A0 EXP1_07_PIN
  220. //#define FORCE_SOFT_SPI // Use this if default of hardware SPI causes display problems
  221. // results in LCD soft SPI mode 3, SD soft SPI mode 0
  222. #define LCD_RESET_PIN EXP1_06_PIN // Must be high or open for LCD to operate normally.
  223. #if EITHER(FYSETC_MINI_12864_1_2, FYSETC_MINI_12864_2_0)
  224. #ifndef RGB_LED_R_PIN
  225. #define RGB_LED_R_PIN EXP1_05_PIN // D5
  226. #endif
  227. #ifndef RGB_LED_G_PIN
  228. #define RGB_LED_G_PIN EXP1_04_PIN // D6
  229. #endif
  230. #ifndef RGB_LED_B_PIN
  231. #define RGB_LED_B_PIN EXP1_03_PIN // D7
  232. #endif
  233. #elif ENABLED(FYSETC_MINI_12864_2_1)
  234. #define NEOPIXEL_PIN EXP1_05_PIN // D5
  235. #endif
  236. #elif ENABLED(SPARK_FULL_GRAPHICS)
  237. //http://doku.radds.org/dokumentation/other-electronics/sparklcd/
  238. #error "Oops! SPARK_FULL_GRAPHICS not supported with RURAMPS4D."
  239. //#define LCD_PINS_D4 29 //?
  240. //#define LCD_PINS_ENABLE 27 //?
  241. //#define LCD_PINS_RS 25 //?
  242. //#define BTN_EN1 35 //?
  243. //#define BTN_EN2 33 //?
  244. //#define BTN_ENC 37 //?
  245. #endif // SPARK_FULL_GRAPHICS
  246. #if IS_NEWPANEL
  247. #define BTN_EN1 EXP2_08_PIN
  248. #define BTN_EN2 EXP2_06_PIN
  249. #define BTN_ENC EXP1_09_PIN
  250. #endif
  251. #if ENABLED(REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
  252. #define BTN_ENC_EN LCD_PINS_D7 // Detect the presence of the encoder
  253. #endif
  254. #endif // HAS_WIRED_LCD