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_BTT_SKR_SE_BX.h 7.7KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233
  1. /**
  2. * Marlin 3D Printer Firmware
  3. * Copyright (c) 2021 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. */
  22. #pragma once
  23. #if NOT_TARGET(STM32H7)
  24. #error "Oops! Select an STM32H7 board in 'Tools > Board.'"
  25. #endif
  26. #define BOARD_INFO_NAME "BTT SKR SE BX"
  27. #define DEFAULT_MACHINE_NAME "BIQU-BX"
  28. // Onboard I2C EEPROM
  29. #define I2C_EEPROM
  30. #define MARLIN_EEPROM_SIZE 0x1000 // 4K (24C32)
  31. #define HAS_OTG_USB_HOST_SUPPORT // USB Flash Drive support
  32. //
  33. // Limit Switches
  34. //
  35. #define X_MIN_PIN PB11
  36. #define X_MAX_PIN PD13
  37. #define Y_MIN_PIN PB12
  38. #define Y_MAX_PIN PB13
  39. #define Z_MIN_PIN PD12
  40. #define Z_MAX_PIN PD11
  41. #define FIL_RUNOUT_PIN PD13
  42. #define FIL_RUNOUT2_PIN PB13
  43. #define LED_PIN PA13
  44. #define BEEPER_PIN PA14
  45. #define POWER_MONITOR_PIN PB0
  46. #define RPI_POWER_PIN PE5
  47. #define SAFE_POWER_PIN PI11
  48. #define SERVO0_PIN PA2
  49. //
  50. // Z Probe (when not Z_MIN_PIN)
  51. //
  52. #ifndef Z_MIN_PROBE_PIN
  53. #define Z_MIN_PROBE_PIN PH2 // Probe
  54. #endif
  55. //
  56. // Steppers
  57. //
  58. #define X_STEP_PIN PG13
  59. #define X_DIR_PIN PG12
  60. #define X_ENABLE_PIN PG14
  61. #define X_CS_PIN PG10
  62. #define Y_STEP_PIN PB3
  63. #define Y_DIR_PIN PD3
  64. #define Y_ENABLE_PIN PB4
  65. #define Y_CS_PIN PD4
  66. #define Z_STEP_PIN PD7
  67. #define Z_DIR_PIN PD6
  68. #define Z_ENABLE_PIN PG9
  69. #define Z_CS_PIN PD5
  70. #define E0_STEP_PIN PC14
  71. #define E0_DIR_PIN PC13
  72. #define E0_ENABLE_PIN PC15
  73. #define E0_CS_PIN PI8
  74. #define E1_STEP_PIN PA8
  75. #define E1_DIR_PIN PC9
  76. #define E1_ENABLE_PIN PD2
  77. #define E1_CS_PIN PC8
  78. //
  79. // Software SPI pins for TMC2130 stepper drivers
  80. //
  81. #if ENABLED(TMC_USE_SW_SPI)
  82. #ifndef TMC_SW_MOSI
  83. #define TMC_SW_MOSI PC6
  84. #endif
  85. #ifndef TMC_SW_MISO
  86. #define TMC_SW_MISO PG3
  87. #endif
  88. #ifndef TMC_SW_SCK
  89. #define TMC_SW_SCK PC7
  90. #endif
  91. #endif
  92. #if HAS_TMC_UART
  93. /**
  94. * TMC2208/TMC2209 stepper drivers
  95. *
  96. * Hardware serial communication ports.
  97. * If undefined software serial is used according to the pins below
  98. */
  99. //#define X_HARDWARE_SERIAL Serial
  100. //#define X2_HARDWARE_SERIAL Serial1
  101. //#define Y_HARDWARE_SERIAL Serial1
  102. //#define Y2_HARDWARE_SERIAL Serial1
  103. //#define Z_HARDWARE_SERIAL Serial1
  104. //#define Z2_HARDWARE_SERIAL Serial1
  105. //#define E0_HARDWARE_SERIAL Serial1
  106. //#define E1_HARDWARE_SERIAL Serial1
  107. //#define E2_HARDWARE_SERIAL Serial1
  108. //#define E3_HARDWARE_SERIAL Serial1
  109. //#define E4_HARDWARE_SERIAL Serial1
  110. //#define E5_HARDWARE_SERIAL Serial1
  111. //#define E6_HARDWARE_SERIAL Serial1
  112. //#define E7_HARDWARE_SERIAL Serial1
  113. #define X_SERIAL_TX_PIN PG10
  114. #define X_SERIAL_RX_PIN X_SERIAL_TX_PIN
  115. #define Y_SERIAL_TX_PIN PD4
  116. #define Y_SERIAL_RX_PIN Y_SERIAL_TX_PIN
  117. #define Z_SERIAL_TX_PIN PD5
  118. #define Z_SERIAL_RX_PIN Z_SERIAL_TX_PIN
  119. #define E0_SERIAL_TX_PIN PI8
  120. #define E0_SERIAL_RX_PIN E0_SERIAL_TX_PIN
  121. #define E1_SERIAL_TX_PIN PC8
  122. #define E1_SERIAL_RX_PIN E1_SERIAL_TX_PIN
  123. // Reduce baud rate to improve software serial reliability
  124. #define TMC_BAUD_RATE 19200
  125. #endif
  126. //
  127. // Temperature Sensors
  128. //
  129. #define TEMP_0_PIN PH4 // TH0
  130. #define TEMP_1_PIN PA3 // TH1
  131. #define TEMP_BED_PIN PH5 // TB
  132. //
  133. // Heaters / Fans
  134. //
  135. #define HEATER_0_PIN PC4
  136. #define HEATER_1_PIN PC5
  137. #define HEATER_BED_PIN PA4
  138. #define FAN_PIN PA5 // "FAN0"
  139. #define FAN1_PIN PA6 // "FAN1"
  140. #define FAN2_PIN PA7 // "FAN2"
  141. #define NEOPIXEL_PIN PH3
  142. #define NEOPIXEL2_PIN PB1
  143. #if HAS_LTDC_TFT
  144. // LTDC_LCD Timing
  145. #define LTDC_LCD_CLK 50 // LTDC clock frequency = 50Mhz
  146. #define LTDC_LCD_HSYNC 30 // Horizontal synchronization
  147. #define LTDC_LCD_HBP 114 // Horizontal back porch
  148. #define LTDC_LCD_HFP 16 // Horizontal front porch
  149. #define LTDC_LCD_VSYNC 3 // Vertical synchronization
  150. #define LTDC_LCD_VBP 32 // Vertical back porch
  151. #define LTDC_LCD_VFP 10 // Vertical front porch
  152. #define TFT_BACKLIGHT_PIN PB5
  153. #define LCD_DE_PIN PF10
  154. #define LCD_CLK_PIN PG7
  155. #define LCD_VSYNC_PIN PI9
  156. #define LCD_HSYNC_PIN PI10
  157. #define LCD_R7_PIN PG6 // R5
  158. #define LCD_R6_PIN PH12
  159. #define LCD_R5_PIN PH11
  160. #define LCD_R4_PIN PH10
  161. #define LCD_R3_PIN PH9
  162. #define LCD_G7_PIN PI2 // G6
  163. #define LCD_G6_PIN PI1
  164. #define LCD_G5_PIN PI0
  165. #define LCD_G4_PIN PH15
  166. #define LCD_G3_PIN PH14
  167. #define LCD_G2_PIN PH13
  168. #define LCD_B7_PIN PI7 // B5
  169. #define LCD_B6_PIN PI6
  170. #define LCD_B5_PIN PI5
  171. #define LCD_B4_PIN PI4
  172. #define LCD_B3_PIN PG11
  173. // GT911 Capacitive Touch Sensor
  174. #if ENABLED(TFT_TOUCH_DEVICE_GT911)
  175. #define GT911_RST_PIN PE4
  176. #define GT911_INT_PIN PE3
  177. #define GT911_SW_I2C_SCL_PIN PE2
  178. #define GT911_SW_I2C_SDA_PIN PE6
  179. #endif
  180. #endif
  181. #if IS_NEWPANEL
  182. #define BTN_EN1 PH6
  183. #define BTN_EN2 PH7
  184. #define BTN_ENC PH8
  185. #endif
  186. //
  187. // SD card
  188. //
  189. #ifndef SDCARD_CONNECTION
  190. #define SDCARD_CONNECTION ONBOARD
  191. #endif
  192. #define SOFTWARE_SPI
  193. #define SDSS PA15
  194. #define SD_SS_PIN SDSS
  195. #define SD_SCK_PIN PC10
  196. #define SD_MISO_PIN PC11
  197. #define SD_MOSI_PIN PC12
  198. #define SD_DETECT_PIN PI3