My Marlin configs for Fabrikator Mini and CTC i3 Pro B
Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

pins_FYSETC_S6.h 5.9KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256
  1. /**
  2. * Marlin 3D Printer Firmware
  3. * Copyright (c) 2019 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. #ifndef STM32F4
  24. #error "Oops! Select an STM32F4 board in 'Tools > Board.'"
  25. #elif HOTENDS > 3 || E_STEPPERS > 3
  26. #error "RUMBA32 supports up to 3 hotends / E-steppers."
  27. #endif
  28. #ifndef BOARD_INFO_NAME
  29. #define BOARD_INFO_NAME "FYSETC_S6"
  30. #endif
  31. #ifndef DEFAULT_MACHINE_NAME
  32. #define DEFAULT_MACHINE_NAME BOARD_INFO_NAME
  33. #endif
  34. // change the prio to 3 , 2 is for software serial
  35. //#define TEMP_TIMER_IRQ_PRIO 3
  36. //
  37. // EEPROM Emulation
  38. //
  39. #define FLASH_EEPROM_EMULATION
  40. //#define SRAM_EEPROM_EMULATION
  41. //#define I2C_EEPROM
  42. #ifdef I2C_EEPROM
  43. #undef E2END // Defined in Arduino Core STM32 to be used with EEPROM emulation. This board uses a real EEPROM.
  44. #define E2END 0xFFF // 4KB
  45. #endif
  46. //
  47. // Limit Switches
  48. //
  49. #define X_MIN_PIN PB14
  50. #define X_MAX_PIN PA1
  51. #define Y_MIN_PIN PB13
  52. #define Y_MAX_PIN PA2
  53. #define Z_MIN_PIN PA0
  54. #define Z_MAX_PIN PA3
  55. //
  56. // Servos
  57. // share with Z_MAX_PIN
  58. //
  59. #define SERVO0_PIN PA3
  60. //
  61. // Steppers
  62. //
  63. #define X_STEP_PIN PE11
  64. #define X_DIR_PIN PE10
  65. #define X_ENABLE_PIN PE12
  66. #define X_CS_PIN PE7
  67. #define Y_STEP_PIN PD8
  68. #define Y_DIR_PIN PB12
  69. #define Y_ENABLE_PIN PD9
  70. #define Y_CS_PIN PE15
  71. #define Z_STEP_PIN PD14
  72. #define Z_DIR_PIN PD13
  73. #define Z_ENABLE_PIN PD15
  74. #define Z_CS_PIN PD10
  75. #define E0_STEP_PIN PD5
  76. #define E0_DIR_PIN PD6
  77. #define E0_ENABLE_PIN PD4
  78. #define E0_CS_PIN PD7
  79. #define E1_STEP_PIN PE6
  80. #define E1_DIR_PIN PC13
  81. #define E1_ENABLE_PIN PE5
  82. #define E1_CS_PIN PC14
  83. #define E2_STEP_PIN PE2
  84. #define E2_DIR_PIN PE4
  85. #define E2_ENABLE_PIN PE3
  86. #define E2_CS_PIN PC15
  87. #if HAS_TMC220x
  88. //
  89. // TMC2208/TMC2209 stepper drivers
  90. //
  91. //
  92. // Software serial
  93. //
  94. #define X_SERIAL_TX_PIN PE9
  95. #define X_SERIAL_RX_PIN PE8
  96. #define Y_SERIAL_TX_PIN PE14
  97. #define Y_SERIAL_RX_PIN PE13
  98. #define Z_SERIAL_TX_PIN PD11
  99. #define Z_SERIAL_RX_PIN PD12
  100. #define E0_SERIAL_TX_PIN PD3
  101. #define E0_SERIAL_RX_PIN PA15
  102. #define E1_SERIAL_TX_PIN PC4
  103. #define E1_SERIAL_RX_PIN PC5
  104. #define E2_SERIAL_TX_PIN PE1
  105. #define E2_SERIAL_RX_PIN PE0
  106. #endif
  107. //
  108. // Temperature Sensors
  109. //
  110. #define TEMP_0_PIN PC0
  111. #define TEMP_1_PIN PC1
  112. #define TEMP_2_PIN PC2
  113. #define TEMP_BED_PIN PC3
  114. //
  115. // Heaters / Fans
  116. //
  117. #define HEATER_0_PIN PB3
  118. #define HEATER_1_PIN PB4
  119. #define HEATER_2_PIN PB15
  120. #define HEATER_BED_PIN PC8
  121. #define FAN_PIN PB0
  122. #define FAN1_PIN PB1
  123. #define FAN2_PIN PB2
  124. //
  125. // SPI
  126. //
  127. #define SCK_PIN PA5
  128. #define MISO_PIN PA6
  129. #define MOSI_PIN PA7
  130. //
  131. // Misc. Functions
  132. //
  133. //#define LED_PIN PB14
  134. //#define BTN_PIN PC10
  135. //#define PS_ON_PIN PE11
  136. //#define KILL_PIN PC5
  137. #define SDSS PA4
  138. //
  139. // LCD / Controller
  140. //
  141. #if HAS_SPI_LCD
  142. #define BEEPER_PIN PC9
  143. #define BTN_ENC PA8
  144. #if ENABLED(CR10_STOCKDISPLAY)
  145. #define LCD_PINS_RS PD0
  146. #define BTN_EN1 PC11
  147. #define BTN_EN2 PC10
  148. #define LCD_PINS_ENABLE PD1
  149. #define LCD_PINS_D4 PC12
  150. // CR10_Stock Display needs a different delay setting on SKR PRO v1.1, so undef it here.
  151. // It will be defined again at the #HAS_GRAPHICAL_LCD section below.
  152. #undef ST7920_DELAY_1
  153. #undef ST7920_DELAY_2
  154. #undef ST7920_DELAY_3
  155. #else
  156. #define LCD_PINS_RS PD2
  157. #define BTN_EN1 PC6
  158. #define BTN_EN2 PC7
  159. #define SD_DETECT_PIN PB10
  160. #define LCD_SDSS PA4
  161. #define LCD_PINS_ENABLE PC11
  162. #define LCD_PINS_D4 PC10
  163. #if ENABLED(FYSETC_MINI_12864)
  164. // See https://wiki.fysetc.com/Mini12864_Panel
  165. #define DOGLCD_CS PC11
  166. #define DOGLCD_A0 PD2
  167. #if ENABLED(FYSETC_GENERIC_12864_1_1)
  168. #define LCD_BACKLIGHT_PIN PD0
  169. #endif
  170. #define LCD_RESET_PIN PC10 // Must be high or open for LCD to operate normally.
  171. #if EITHER(FYSETC_MINI_12864_1_2, FYSETC_MINI_12864_2_0)
  172. #ifndef RGB_LED_R_PIN
  173. #define RGB_LED_R_PIN PC12
  174. #endif
  175. #ifndef RGB_LED_G_PIN
  176. #define RGB_LED_G_PIN PD0
  177. #endif
  178. #ifndef RGB_LED_B_PIN
  179. #define RGB_LED_B_PIN PD1
  180. #endif
  181. #elif ENABLED(FYSETC_MINI_12864_2_1)
  182. #define NEOPIXEL_PIN PC12
  183. #endif
  184. #endif // !FYSETC_MINI_12864
  185. #if ENABLED(ULTIPANEL)
  186. #define LCD_PINS_D5 PC12
  187. #define LCD_PINS_D6 PD0
  188. #define LCD_PINS_D7 PD1
  189. #endif
  190. #endif
  191. // Alter timing for graphical display
  192. #if HAS_GRAPHICAL_LCD
  193. #ifndef ST7920_DELAY_1
  194. #define ST7920_DELAY_1 DELAY_NS(96)
  195. #endif
  196. #ifndef ST7920_DELAY_2
  197. #define ST7920_DELAY_2 DELAY_NS(48)
  198. #endif
  199. #ifndef ST7920_DELAY_3
  200. #define ST7920_DELAY_3 DELAY_NS(600)
  201. #endif
  202. #endif
  203. #endif // HAS_SPI_LCD
  204. #ifndef RGB_LED_R_PIN
  205. #define RGB_LED_R_PIN PB6
  206. #endif
  207. #ifndef RGB_LED_G_PIN
  208. #define RGB_LED_G_PIN PB5
  209. #endif
  210. #ifndef RGB_LED_B_PIN
  211. #define RGB_LED_B_PIN PB7
  212. #endif
  213. #ifndef RGB_LED_W_PIN
  214. #define RGB_LED_W_PIN -1
  215. #endif