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_V3_0_common.h 17KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569
  1. /**
  2. * Marlin 3D Printer Firmware
  3. * Copyright (c) 2022 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. // If you have the BigTreeTech driver expansion module, enable BTT_MOTOR_EXPANSION
  27. // https://github.com/bigtreetech/BTT-Expansion-module/tree/master/BTT%20EXP-MOT
  28. //#define BTT_MOTOR_EXPANSION
  29. #if BOTH(HAS_WIRED_LCD, BTT_MOTOR_EXPANSION)
  30. #if EITHER(CR10_STOCKDISPLAY, ENDER2_STOCKDISPLAY)
  31. #define EXP_MOT_USE_EXP2_ONLY 1
  32. #else
  33. #error "You can't use both an LCD and a Motor Expansion Module on EXP1/EXP2 at the same time."
  34. #endif
  35. #endif
  36. #define USES_DIAG_JUMPERS
  37. // Onboard I2C EEPROM
  38. #if EITHER(NO_EEPROM_SELECTED, I2C_EEPROM)
  39. #undef NO_EEPROM_SELECTED
  40. #define I2C_EEPROM
  41. #define SOFT_I2C_EEPROM // Force the use of Software I2C
  42. #define I2C_SCL_PIN PA14
  43. #define I2C_SDA_PIN PA13
  44. #define MARLIN_EEPROM_SIZE 0x1000 // 4KB
  45. #endif
  46. //
  47. // Servos
  48. //
  49. #define SERVO0_PIN PE5
  50. //
  51. // Trinamic Stallguard pins
  52. //
  53. #define X_DIAG_PIN PC1 // X-STOP
  54. #define Y_DIAG_PIN PC3 // Y-STOP
  55. #define Z_DIAG_PIN PC0 // Z-STOP
  56. #define E0_DIAG_PIN PC2 // E0DET
  57. #define E1_DIAG_PIN PA0 // E1DET
  58. //
  59. // Limit Switches
  60. //
  61. #ifdef X_STALL_SENSITIVITY
  62. #define X_STOP_PIN X_DIAG_PIN
  63. #if X_HOME_TO_MIN
  64. #define X_MAX_PIN PC2 // E0DET
  65. #else
  66. #define X_MIN_PIN PC2 // E0DET
  67. #endif
  68. #elif ENABLED(X_DUAL_ENDSTOPS)
  69. #ifndef X_MIN_PIN
  70. #define X_MIN_PIN PC1 // X-STOP
  71. #endif
  72. #ifndef X_MAX_PIN
  73. #define X_MAX_PIN PC2 // E0DET
  74. #endif
  75. #else
  76. #define X_STOP_PIN PC1 // X-STOP
  77. #endif
  78. #ifdef Y_STALL_SENSITIVITY
  79. #define Y_STOP_PIN Y_DIAG_PIN
  80. #if Y_HOME_TO_MIN
  81. #define Y_MAX_PIN PA0 // E1DET
  82. #else
  83. #define Y_MIN_PIN PA0 // E1DET
  84. #endif
  85. #elif ENABLED(Y_DUAL_ENDSTOPS)
  86. #ifndef Y_MIN_PIN
  87. #define Y_MIN_PIN PC3 // Y-STOP
  88. #endif
  89. #ifndef Y_MAX_PIN
  90. #define Y_MAX_PIN PA0 // E1DET
  91. #endif
  92. #else
  93. #define Y_STOP_PIN PC3 // Y-STOP
  94. #endif
  95. #ifdef Z_STALL_SENSITIVITY
  96. #define Z_STOP_PIN Z_DIAG_PIN
  97. #if Z_HOME_TO_MIN
  98. #define Z_MAX_PIN PC15 // PWRDET
  99. #else
  100. #define Z_MIN_PIN PC15 // PWRDET
  101. #endif
  102. #elif ENABLED(Z_MULTI_ENDSTOPS)
  103. #ifndef Z_MIN_PIN
  104. #define Z_MIN_PIN PC0 // Z-STOP
  105. #endif
  106. #ifndef Z_MAX_PIN
  107. #define Z_MAX_PIN PC15 // PWRDET
  108. #endif
  109. #else
  110. #ifndef Z_STOP_PIN
  111. #define Z_STOP_PIN PC0 // Z-STOP
  112. #endif
  113. #endif
  114. //
  115. // Z Probe (when not Z_MIN_PIN)
  116. //
  117. #ifndef Z_MIN_PROBE_PIN
  118. #define Z_MIN_PROBE_PIN PC13
  119. #endif
  120. //
  121. // Probe enable
  122. //
  123. #if ENABLED(PROBE_ENABLE_DISABLE)
  124. #ifndef PROBE_ENABLE_PIN
  125. #define PROBE_ENABLE_PIN SERVO0_PIN
  126. #endif
  127. #endif
  128. //
  129. // Filament Runout Sensor
  130. //
  131. #define FIL_RUNOUT_PIN PC2 // E0DET
  132. #define FIL_RUNOUT2_PIN PA0 // E1DET
  133. //
  134. // Power Supply Control
  135. //
  136. #ifndef PS_ON_PIN
  137. #define PS_ON_PIN PE4 // PS-ON
  138. #endif
  139. //
  140. // Power Loss Detection
  141. //
  142. #ifndef POWER_LOSS_PIN
  143. #define POWER_LOSS_PIN PC15 // PWRDET
  144. #endif
  145. //
  146. // Steppers
  147. //
  148. #define X_STEP_PIN PD4
  149. #define X_DIR_PIN PD3
  150. #define X_ENABLE_PIN PD6
  151. #ifndef X_CS_PIN
  152. #define X_CS_PIN PD5
  153. #endif
  154. #define Y_STEP_PIN PA15
  155. #define Y_DIR_PIN PA8
  156. #define Y_ENABLE_PIN PD1
  157. #ifndef Y_CS_PIN
  158. #define Y_CS_PIN PD0
  159. #endif
  160. #define Z_STEP_PIN PE2
  161. #define Z_DIR_PIN PE3
  162. #define Z_ENABLE_PIN PE0
  163. #ifndef Z_CS_PIN
  164. #define Z_CS_PIN PE1
  165. #endif
  166. #ifndef E0_STEP_PIN
  167. #define E0_STEP_PIN PD15
  168. #endif
  169. #ifndef E0_DIR_PIN
  170. #define E0_DIR_PIN PD14
  171. #endif
  172. #ifndef E0_ENABLE_PIN
  173. #define E0_ENABLE_PIN PC7
  174. #endif
  175. #ifndef E0_CS_PIN
  176. #define E0_CS_PIN PC6
  177. #endif
  178. #ifndef E1_STEP_PIN
  179. #define E1_STEP_PIN PD11
  180. #endif
  181. #ifndef E1_DIR_PIN
  182. #define E1_DIR_PIN PD10
  183. #endif
  184. #ifndef E1_ENABLE_PIN
  185. #define E1_ENABLE_PIN PD13
  186. #endif
  187. #ifndef E1_CS_PIN
  188. #define E1_CS_PIN PD12
  189. #endif
  190. //
  191. // Temperature Sensors
  192. //
  193. #ifndef TEMP_0_PIN
  194. #define TEMP_0_PIN PA2 // TH0
  195. #endif
  196. #ifndef TEMP_1_PIN
  197. #define TEMP_1_PIN PA3 // TH1
  198. #endif
  199. #ifndef TEMP_BED_PIN
  200. #define TEMP_BED_PIN PA1 // TB
  201. #endif
  202. #if HOTENDS == 1 && DISABLED(HEATERS_PARALLEL)
  203. #if TEMP_SENSOR_PROBE
  204. #define TEMP_PROBE_PIN TEMP_1_PIN
  205. #elif TEMP_SENSOR_CHAMBER
  206. #define TEMP_CHAMBER_PIN TEMP_1_PIN
  207. #endif
  208. #endif
  209. //
  210. // Heaters / Fans
  211. //
  212. #ifndef HEATER_0_PIN
  213. #define HEATER_0_PIN PB3 // Heater0
  214. #endif
  215. #ifndef HEATER_1_PIN
  216. #define HEATER_1_PIN PB4 // Heater1
  217. #endif
  218. #ifndef HEATER_BED_PIN
  219. #define HEATER_BED_PIN PD7 // Hotbed
  220. #endif
  221. #ifndef FAN_PIN
  222. #define FAN_PIN PB7 // Fan0
  223. #endif
  224. #if HAS_CUTTER
  225. #ifndef SPINDLE_LASER_PWM_PIN
  226. #define SPINDLE_LASER_PWM_PIN PB5
  227. #endif
  228. #ifndef SPINDLE_LASER_ENA_PIN
  229. #define SPINDLE_LASER_ENA_PIN PB6
  230. #endif
  231. #else
  232. #ifndef FAN1_PIN
  233. #define FAN1_PIN PB6 // Fan1
  234. #endif
  235. #ifndef FAN2_PIN
  236. #define FAN2_PIN PB5 // Fan2
  237. #endif
  238. #endif // SPINDLE_FEATURE || LASER_FEATURE
  239. //
  240. // Software SPI pins for TMC2130 stepper drivers
  241. //
  242. #if ENABLED(TMC_USE_SW_SPI)
  243. #ifndef TMC_SW_MOSI
  244. #define TMC_SW_MOSI PE13
  245. #endif
  246. #ifndef TMC_SW_MISO
  247. #define TMC_SW_MISO PE15
  248. #endif
  249. #ifndef TMC_SW_SCK
  250. #define TMC_SW_SCK PE14
  251. #endif
  252. #endif
  253. #if HAS_TMC_UART
  254. /**
  255. * TMC2208/TMC2209 stepper drivers
  256. *
  257. * Hardware serial communication ports.
  258. * If undefined software serial is used according to the pins below
  259. */
  260. //#define X_HARDWARE_SERIAL Serial1
  261. //#define X2_HARDWARE_SERIAL Serial1
  262. //#define Y_HARDWARE_SERIAL Serial1
  263. //#define Y2_HARDWARE_SERIAL Serial1
  264. //#define Z_HARDWARE_SERIAL Serial1
  265. //#define Z2_HARDWARE_SERIAL Serial1
  266. //#define E0_HARDWARE_SERIAL Serial1
  267. //#define E1_HARDWARE_SERIAL Serial1
  268. //#define E2_HARDWARE_SERIAL Serial1
  269. //#define E3_HARDWARE_SERIAL Serial1
  270. //#define E4_HARDWARE_SERIAL Serial1
  271. //
  272. // Software serial
  273. //
  274. #define X_SERIAL_TX_PIN PD5
  275. #define X_SERIAL_RX_PIN X_SERIAL_TX_PIN
  276. #define Y_SERIAL_TX_PIN PD0
  277. #define Y_SERIAL_RX_PIN Y_SERIAL_TX_PIN
  278. #define Z_SERIAL_TX_PIN PE1
  279. #define Z_SERIAL_RX_PIN Z_SERIAL_TX_PIN
  280. #define E0_SERIAL_TX_PIN PC6
  281. #define E0_SERIAL_RX_PIN E0_SERIAL_TX_PIN
  282. #define E1_SERIAL_TX_PIN PD12
  283. #define E1_SERIAL_RX_PIN E1_SERIAL_TX_PIN
  284. // Reduce baud rate to improve software serial reliability
  285. #define TMC_BAUD_RATE 19200
  286. #endif
  287. //
  288. // SD Connection
  289. //
  290. #ifndef SDCARD_CONNECTION
  291. #define SDCARD_CONNECTION ONBOARD
  292. #endif
  293. /**
  294. * ------ ------
  295. * (BEEPER) PC5 |10 9 | PB0 (BTN_ENC) (MISO) PA6 |10 9 | PA5 (SCK)
  296. * (LCD_EN) PB1 | 8 7 | PE8 (LCD_RS) (BTN_EN1) PE7 | 8 7 | PA4 (SD_SS)
  297. * (LCD_D4) PE9 | 6 5 PE10 (LCD_D5) (BTN_EN2) PB2 | 6 5 PA7 (MOSI)
  298. * (LCD_D6) PE11 | 4 3 | PE12 (LCD_D7) (SD_DETECT) PC4 | 4 3 | RESET
  299. * GND | 2 1 | 5V GND | 2 1 | --
  300. * ------ ------
  301. * EXP1 EXP2
  302. */
  303. #define EXP1_03_PIN PE12
  304. #define EXP1_04_PIN PE11
  305. #define EXP1_05_PIN PE10
  306. #define EXP1_06_PIN PE9
  307. #define EXP1_07_PIN PE8
  308. #define EXP1_08_PIN PB1
  309. #define EXP1_09_PIN PB0
  310. #define EXP1_10_PIN PC5
  311. #define EXP2_03_PIN -1
  312. #define EXP2_04_PIN PC4
  313. #define EXP2_05_PIN PA7
  314. #define EXP2_06_PIN PB2
  315. #define EXP2_07_PIN PA4
  316. #define EXP2_08_PIN PE7
  317. #define EXP2_09_PIN PA5
  318. #define EXP2_10_PIN PA6
  319. //
  320. // Onboard SD card
  321. // Must use soft SPI because Marlin's default hardware SPI is tied to LCD's EXP2
  322. //
  323. #if SD_CONNECTION_IS(LCD)
  324. #define SDSS EXP2_07_PIN
  325. #define SD_SS_PIN SDSS
  326. #define SD_SCK_PIN EXP2_09_PIN
  327. #define SD_MISO_PIN EXP2_10_PIN
  328. #define SD_MOSI_PIN EXP2_05_PIN
  329. #define SD_DETECT_PIN EXP2_04_PIN
  330. #elif SD_CONNECTION_IS(ONBOARD)
  331. #define SDIO_SUPPORT
  332. #define SDIO_CLOCK 24000000 // 24MHz
  333. #elif SD_CONNECTION_IS(CUSTOM_CABLE)
  334. #error "No custom SD drive cable defined for this board."
  335. #endif
  336. #if ENABLED(BTT_MOTOR_EXPANSION)
  337. /** ----- -----
  338. * -- | . . | GND -- | . . | GND
  339. * -- | . . | M1EN M2EN | . . | M3EN
  340. * M1STP | . . M1DIR M1RX | . . M1DIAG
  341. * M2DIR | . . | M2STP M2RX | . . | M2DIAG
  342. * M3DIR | . . | M3STP M3RX | . . | M3DIAG
  343. * ----- -----
  344. * EXP2 EXP1
  345. *
  346. * NB In EXP_MOT_USE_EXP2_ONLY mode EXP1 is not used and M2EN and M3EN need to be jumpered to M1EN
  347. */
  348. // M1 on Driver Expansion Module
  349. #define E2_STEP_PIN EXP2_05_PIN
  350. #define E2_DIR_PIN EXP2_06_PIN
  351. #define E2_ENABLE_PIN EXP2_04_PIN
  352. #if !EXP_MOT_USE_EXP2_ONLY
  353. #define E2_DIAG_PIN EXP1_06_PIN
  354. #define E2_CS_PIN EXP1_05_PIN
  355. #if HAS_TMC_UART
  356. #define E2_SERIAL_TX_PIN EXP1_05_PIN
  357. #define E2_SERIAL_RX_PIN EXP1_05_PIN
  358. #endif
  359. #endif
  360. // M2 on Driver Expansion Module
  361. #define E3_STEP_PIN EXP2_08_PIN
  362. #define E3_DIR_PIN EXP2_07_PIN
  363. #if !EXP_MOT_USE_EXP2_ONLY
  364. #define E3_ENABLE_PIN EXP1_03_PIN
  365. #define E3_DIAG_PIN EXP1_08_PIN
  366. #define E3_CS_PIN EXP1_07_PIN
  367. #if HAS_TMC_UART
  368. #define E3_SERIAL_TX_PIN EXP1_07_PIN
  369. #define E3_SERIAL_RX_PIN EXP1_07_PIN
  370. #endif
  371. #else
  372. #define E3_ENABLE_PIN EXP2_04_PIN
  373. #endif
  374. // M3 on Driver Expansion Module
  375. #define E4_STEP_PIN EXP2_10_PIN
  376. #define E4_DIR_PIN EXP2_09_PIN
  377. #if !EXP_MOT_USE_EXP2_ONLY
  378. #define E4_ENABLE_PIN EXP1_04_PIN
  379. #define E4_DIAG_PIN EXP1_10_PIN
  380. #define E4_CS_PIN EXP1_09_PIN
  381. #if HAS_TMC_UART
  382. #define E4_SERIAL_TX_PIN EXP1_09_PIN
  383. #define E4_SERIAL_RX_PIN EXP1_09_PIN
  384. #endif
  385. #else
  386. #define E4_ENABLE_PIN EXP2_04_PIN
  387. #endif
  388. #endif // BTT_MOTOR_EXPANSION
  389. //
  390. // LCDs and Controllers
  391. //
  392. #if IS_TFTGLCD_PANEL
  393. #if ENABLED(TFTGLCD_PANEL_SPI)
  394. #define TFTGLCD_CS EXP2_08_PIN
  395. #endif
  396. #elif HAS_WIRED_LCD
  397. #define BEEPER_PIN EXP1_10_PIN
  398. #define BTN_ENC EXP1_09_PIN
  399. #if ENABLED(CR10_STOCKDISPLAY)
  400. #define LCD_PINS_RS EXP1_04_PIN
  401. #define BTN_EN1 EXP1_08_PIN
  402. #define BTN_EN2 EXP1_06_PIN
  403. #define LCD_PINS_ENABLE EXP1_03_PIN
  404. #define LCD_PINS_D4 EXP1_05_PIN
  405. #elif ENABLED(MKS_MINI_12864)
  406. #define DOGLCD_A0 EXP1_04_PIN
  407. #define DOGLCD_CS EXP1_05_PIN
  408. #define BTN_EN1 EXP2_08_PIN
  409. #define BTN_EN2 EXP2_06_PIN
  410. #else
  411. #define LCD_PINS_RS EXP1_07_PIN
  412. #define BTN_EN1 EXP2_08_PIN
  413. #define BTN_EN2 EXP2_06_PIN
  414. #define LCD_PINS_ENABLE EXP1_08_PIN
  415. #define LCD_PINS_D4 EXP1_06_PIN
  416. #if ENABLED(FYSETC_MINI_12864)
  417. #define DOGLCD_CS EXP1_08_PIN
  418. #define DOGLCD_A0 EXP1_07_PIN
  419. //#define LCD_BACKLIGHT_PIN -1
  420. #define LCD_RESET_PIN EXP1_06_PIN // Must be high or open for LCD to operate normally.
  421. #if EITHER(FYSETC_MINI_12864_1_2, FYSETC_MINI_12864_2_0)
  422. #ifndef RGB_LED_R_PIN
  423. #define RGB_LED_R_PIN EXP1_05_PIN
  424. #endif
  425. #ifndef RGB_LED_G_PIN
  426. #define RGB_LED_G_PIN EXP1_04_PIN
  427. #endif
  428. #ifndef RGB_LED_B_PIN
  429. #define RGB_LED_B_PIN EXP1_03_PIN
  430. #endif
  431. #elif ENABLED(FYSETC_MINI_12864_2_1)
  432. #define NEOPIXEL_PIN EXP1_05_PIN
  433. #endif
  434. #endif // !FYSETC_MINI_12864
  435. #if IS_ULTIPANEL
  436. #define LCD_PINS_D5 EXP1_05_PIN
  437. #define LCD_PINS_D6 EXP1_04_PIN
  438. #define LCD_PINS_D7 EXP1_03_PIN
  439. #if ENABLED(REPRAP_DISCOUNT_FULL_GRAPHIC_SMART_CONTROLLER)
  440. #define BTN_ENC_EN LCD_PINS_D7 // Detect the presence of the encoder
  441. #endif
  442. #endif
  443. #endif
  444. #endif // HAS_WIRED_LCD
  445. // Alter timing for graphical display
  446. #if IS_U8GLIB_ST7920
  447. #ifndef BOARD_ST7920_DELAY_1
  448. #define BOARD_ST7920_DELAY_1 120
  449. #endif
  450. #ifndef BOARD_ST7920_DELAY_2
  451. #define BOARD_ST7920_DELAY_2 80
  452. #endif
  453. #ifndef BOARD_ST7920_DELAY_3
  454. #define BOARD_ST7920_DELAY_3 580
  455. #endif
  456. #endif
  457. #if HAS_SPI_TFT
  458. //
  459. // e.g., BTT_TFT35_SPI_V1_0 (480x320, 3.5", SPI Stock Display with Rotary Encoder in BIQU B1 SE)
  460. //
  461. #define TFT_CS_PIN EXP2_07_PIN
  462. #define TFT_A0_PIN EXP2_04_PIN
  463. #define TFT_SCK_PIN EXP2_09_PIN
  464. #define TFT_MISO_PIN EXP2_10_PIN
  465. #define TFT_MOSI_PIN EXP2_05_PIN
  466. #define TOUCH_INT_PIN EXP1_04_PIN
  467. #define TOUCH_MISO_PIN EXP1_05_PIN
  468. #define TOUCH_MOSI_PIN EXP1_08_PIN
  469. #define TOUCH_SCK_PIN EXP1_06_PIN
  470. #define TOUCH_CS_PIN EXP1_07_PIN
  471. #define BTN_EN1 EXP2_08_PIN
  472. #define BTN_EN2 EXP2_06_PIN
  473. #define BTN_ENC EXP1_09_PIN
  474. #endif
  475. //
  476. // NeoPixel LED
  477. //
  478. #ifndef NEOPIXEL_PIN
  479. #define NEOPIXEL_PIN PE6
  480. #endif
  481. //
  482. // WIFI
  483. //
  484. /**
  485. * -------
  486. * GND | 9 | | 8 | 3.3V
  487. * (ESP-CS) PB12 | 10 | | 7 | PB15 (ESP-MOSI)
  488. * 3.3V | 11 | | 6 | PB14 (ESP-MISO)
  489. * (ESP-IO0) PB10 | 12 | | 5 | PB13 (ESP-CLK)
  490. * (ESP-IO4) PB11 | 13 | | 4 | --
  491. * -- | 14 | | 3 | 3.3V (ESP-EN)
  492. * (ESP-RX) PD8 | 15 | | 2 | --
  493. * (ESP-TX) PD9 | 16 | | 1 | PC14 (ESP-RST)
  494. * -------
  495. * WIFI
  496. */
  497. #define ESP_WIFI_MODULE_COM 3 // Must also set either SERIAL_PORT or SERIAL_PORT_2 to this
  498. #define ESP_WIFI_MODULE_BAUDRATE BAUDRATE // Must use same BAUDRATE as SERIAL_PORT & SERIAL_PORT_2
  499. #define ESP_WIFI_MODULE_RESET_PIN PC14
  500. #define ESP_WIFI_MODULE_GPIO0_PIN PB10
  501. #define ESP_WIFI_MODULE_GPIO4_PIN PB11