My Marlin configs for Fabrikator Mini and CTC i3 Pro B
Du kannst nicht mehr als 25 Themen auswählen Themen müssen mit entweder einem Buchstaben oder einer Ziffer beginnen. Sie können Bindestriche („-“) enthalten und bis zu 35 Zeichen lang sein.

stm32f4.ini 13KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404
  1. #
  2. # Marlin Firmware
  3. # PlatformIO Configuration File
  4. #
  5. #################################
  6. #
  7. # STM32F4 Architecture
  8. #
  9. # Naming Example: STM32F401RGT6
  10. #
  11. # F : Foundation (sometimes High Performance F2/F4)
  12. # 4 : Cortex M4 core
  13. # 01 : Line/Features
  14. # R : 64 or 66 pins (V:100, Z:144, I:176)
  15. # G : 1024KB Flash-memory (C:256KB, D:384KB, E:512KB)
  16. # T : LQFP package
  17. # 6 : -40...85°C (7: ...105°C)
  18. #
  19. #################################
  20. #
  21. # ARMED (STM32)
  22. #
  23. [env:ARMED]
  24. platform = ${common_stm32.platform}
  25. extends = common_stm32
  26. board = armed_v1
  27. build_flags = ${common_stm32.build_flags}
  28. -O2 -ffreestanding -fsigned-char -fno-move-loop-invariants -fno-strict-aliasing
  29. #
  30. # STM32F401VE
  31. # 'STEVAL-3DP001V1' STM32F401VE board - https://www.st.com/en/evaluation-tools/steval-3dp001v1.html
  32. #
  33. [env:STM32F401VE_STEVAL]
  34. platform = ${common_stm32.platform}
  35. extends = common_stm32
  36. board = STEVAL_STM32F401VE
  37. build_flags = ${common_stm32.build_flags}
  38. -DARDUINO_STEVAL -DSTM32F401xE
  39. -DDISABLE_GENERIC_SERIALUSB -DUSBD_USE_CDC_COMPOSITE -DUSE_USB_FS
  40. extra_scripts = ${common.extra_scripts}
  41. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  42. buildroot/share/PlatformIO/scripts/STM32F401VE_STEVAL.py
  43. #
  44. # STM32F401RC
  45. #
  46. [env:FYSETC_CHEETAH_V20]
  47. platform = ${common_stm32.platform}
  48. extends = common_stm32
  49. board = FYSETC_CHEETAH_V20
  50. build_flags = ${common_stm32.build_flags} -DSTM32F401xC -DVECT_TAB_OFFSET=0xC000
  51. extra_scripts = ${common.extra_scripts}
  52. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  53. buildroot/share/PlatformIO/scripts/FYSETC_CHEETAH_V20.py
  54. #
  55. # FLYF407ZG
  56. #
  57. [env:FLYF407ZG]
  58. platform = ${common_stm32.platform}
  59. extends = common_stm32
  60. board = FLYF407ZG
  61. build_flags = ${common_stm32.build_flags}
  62. -DVECT_TAB_OFFSET=0x8000
  63. extra_scripts = ${common.extra_scripts}
  64. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  65. #
  66. # FLY MINI(stm32f103rct6)
  67. #
  68. [env:FLY_MINI]
  69. platform = ${common_stm32f1.platform}
  70. extends = common_stm32f1
  71. board = genericSTM32F103RC
  72. extra_scripts = ${common_stm32f1.extra_scripts}
  73. buildroot/share/PlatformIO/scripts/fly_mini.py
  74. build_flags = ${common_stm32f1.build_flags}
  75. -DDEBUG_LEVEL=0 -DSS_TIMER=4
  76. #
  77. # FYSETC S6 (STM32F446VET6 ARM Cortex-M4)
  78. #
  79. [env:FYSETC_S6]
  80. platform = ${common_stm32.platform}
  81. extends = common_stm32
  82. platform_packages = tool-stm32duino
  83. board = marlin_fysetc_s6
  84. build_flags = ${common_stm32.build_flags}
  85. -DVECT_TAB_OFFSET=0x10000
  86. -DHAL_PCD_MODULE_ENABLED
  87. extra_scripts = ${common.extra_scripts}
  88. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  89. debug_tool = stlink
  90. upload_protocol = dfu
  91. upload_command = dfu-util -a 0 -s 0x08010000:leave -D "$SOURCE"
  92. #
  93. # STM32F407VET6 with RAMPS-like shield
  94. # 'Black' STM32F407VET6 board - https://wiki.stm32duino.com/index.php?title=STM32F407
  95. # Shield - https://github.com/jmz52/Hardware
  96. #
  97. [env:STM32F407VE_black]
  98. platform = ${common_stm32.platform}
  99. extends = common_stm32
  100. board = blackSTM32F407VET6
  101. build_flags = ${common_stm32.build_flags}
  102. -DARDUINO_BLACK_F407VE
  103. -DUSBD_USE_CDC_COMPOSITE -DUSE_USB_FS
  104. extra_scripts = ${common.extra_scripts}
  105. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  106. #
  107. # Anet ET4-MB_V1.x/ET4P-MB_V1.x (STM32F407VGT6 ARM Cortex-M4)
  108. # For use with with davidtgbe's OpenBLT bootloader https://github.com/davidtgbe/openblt/releases
  109. # Comment out board_build.offset = 0x10000 if you don't plan to use OpenBLT/flashing directly to 0x08000000.
  110. #
  111. [env:Anet_ET4_OpenBLT]
  112. platform = ${common_stm32.platform}
  113. extends = common_stm32
  114. build_flags = ${common_stm32.build_flags} -DHAL_SD_MODULE_ENABLED -DHAL_SRAM_MODULE_ENABLED
  115. board = genericSTM32F407VGT6
  116. board_build.core = stm32
  117. board_build.variant = MARLIN_F4x7Vx
  118. board_build.ldscript = ldscript.ld
  119. board_build.firmware = firmware.srec
  120. # Just openblt.py (not stm32_bootloader.py) generates the file
  121. board_build.encrypt = Yes
  122. board_build.offset = 0x10000
  123. board_upload.offset_address = 0x08010000
  124. build_unflags = ${common_stm32.build_unflags} -DUSBCON -DUSBD_USE_CDC -DUSBD_VID=0x0483
  125. debug_tool = jlink
  126. upload_protocol = jlink
  127. extra_scripts = ${common.extra_scripts}
  128. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  129. buildroot/share/PlatformIO/scripts/stm32_bootloader.py
  130. buildroot/share/PlatformIO/scripts/openblt.py
  131. #
  132. # BigTreeTech SKR Pro (STM32F407ZGT6 ARM Cortex-M4)
  133. #
  134. [env:BIGTREE_SKR_PRO]
  135. platform = ${common_stm32.platform}
  136. extends = common_stm32
  137. board = BigTree_SKR_Pro
  138. build_flags = ${common_stm32.build_flags}
  139. -DSTM32F407_5ZX -DVECT_TAB_OFFSET=0x8000
  140. extra_scripts = ${common.extra_scripts}
  141. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  142. #upload_protocol = stlink
  143. #upload_command = "$PROJECT_PACKAGES_DIR/tool-stm32duino/stlink/ST-LINK_CLI.exe" -c SWD -P "$BUILD_DIR/firmware.bin" 0x8008000 -Rst -Run
  144. debug_tool = stlink
  145. debug_init_break =
  146. #
  147. # USB Flash Drive mix-ins for STM32
  148. #
  149. [stm_flash_drive]
  150. platform_packages = framework-arduinoststm32@https://github.com/rhapsodyv/Arduino_Core_STM32/archive/usb-host-msc.zip
  151. build_flags = ${common_stm32.build_flags}
  152. -DHAL_PCD_MODULE_ENABLED -DHAL_HCD_MODULE_ENABLED
  153. -DUSBHOST -DUSBH_IRQ_PRIO=3 -DUSBH_IRQ_SUBPRIO=4
  154. #
  155. # BigTreeTech SKR Pro (STM32F407ZGT6 ARM Cortex-M4) with USB Flash Drive Support
  156. #
  157. [env:BIGTREE_SKR_PRO_usb_flash_drive]
  158. extends = env:BIGTREE_SKR_PRO
  159. platform_packages = ${stm_flash_drive.platform_packages}
  160. build_unflags = -DUSBCON -DUSBD_USE_CDC
  161. build_flags = ${stm_flash_drive.build_flags}
  162. -DSTM32F407_5ZX -DVECT_TAB_OFFSET=0x8000
  163. #
  164. # BigTreeTech E3 RRF (STM32F407VGT6 ARM Cortex-M4)
  165. #
  166. [env:BIGTREE_E3_RRF]
  167. platform = ${common_stm32.platform}
  168. extends = common_stm32
  169. board = genericSTM32F407VGT6
  170. board_build.variant = BIGTREE_E3_RRF
  171. build_flags = ${common_stm32.build_flags}
  172. -DSTM32F407_5VX -DVECT_TAB_OFFSET=0x8000
  173. -DSERIAL_RX_BUFFER_SIZE=255 -DSERIAL_TX_BUFFER_SIZE=255
  174. extra_scripts = ${common.extra_scripts}
  175. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  176. #
  177. # Bigtreetech GTR V1.0 (STM32F407IGT6 ARM Cortex-M4)
  178. #
  179. [env:BIGTREE_GTR_V1_0]
  180. platform = ${common_stm32.platform}
  181. extends = common_stm32
  182. board = BigTree_GTR_v1
  183. extra_scripts = ${common.extra_scripts}
  184. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  185. build_flags = ${common_stm32.build_flags}
  186. -DSTM32F407IX -DVECT_TAB_OFFSET=0x8000
  187. #
  188. # Bigtreetech GTR V1.0 (STM32F407IGT6 ARM Cortex-M4) with USB Flash Drive Support
  189. #
  190. [env:BIGTREE_GTR_V1_0_usb_flash_drive]
  191. extends = env:BIGTREE_GTR_V1_0
  192. platform_packages = ${stm_flash_drive.platform_packages}
  193. build_unflags = -DUSBCON -DUSBD_USE_CDC
  194. build_flags = ${stm_flash_drive.build_flags}
  195. -DSTM32F407IX -DVECT_TAB_OFFSET=0x8000
  196. #
  197. # BigTreeTech BTT002 V1.0 (STM32F407VGT6 ARM Cortex-M4)
  198. #
  199. [env:BIGTREE_BTT002]
  200. platform = ${common_stm32.platform}
  201. extends = common_stm32
  202. board = BigTree_Btt002
  203. build_flags = ${common_stm32.build_flags}
  204. -DSTM32F407_5VX -DVECT_TAB_OFFSET=0x8000
  205. -DHAVE_HWSERIAL2
  206. -DHAVE_HWSERIAL3
  207. -DPIN_SERIAL2_RX=PD_6
  208. -DPIN_SERIAL2_TX=PD_5
  209. extra_scripts = ${common.extra_scripts}
  210. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  211. #
  212. # Lerdge base
  213. #
  214. [lerdge_common]
  215. platform = ${common_stm32.platform}
  216. extends = common_stm32
  217. board = LERDGE
  218. board_build.offset = 0x10000
  219. board_build.encrypt = Yes
  220. extra_scripts = ${common.extra_scripts}
  221. pre:buildroot/share/PlatformIO/scripts/copy_marlin_variant_to_framework.py
  222. buildroot/share/PlatformIO/scripts/stm32_bootloader.py
  223. buildroot/share/PlatformIO/scripts/lerdge.py
  224. build_flags = ${common_stm32.build_flags}
  225. -DSTM32F4 -DSTM32F4xx -DTARGET_STM32F4
  226. -DDISABLE_GENERIC_SERIALUSB -DARDUINO_ARCH_STM32 -DARDUINO_LERDGE
  227. -DHAL_SRAM_MODULE_ENABLED
  228. build_unflags = ${common_stm32.build_unflags} -DUSBCON -DUSBD_USE_CDC -DUSBD_VID=0x0483
  229. #
  230. # Lerdge X
  231. #
  232. [env:LERDGEX]
  233. platform = ${lerdge_common.platform}
  234. extends = lerdge_common
  235. board_build.firmware = Lerdge_X_firmware_force.bin
  236. #
  237. # Lerdge X with USB Flash Drive Support
  238. #
  239. [env:LERDGEX_usb_flash_drive]
  240. platform = ${env:LERDGEX.platform}
  241. extends = env:LERDGEX
  242. platform_packages = ${stm_flash_drive.platform_packages}
  243. build_flags = ${stm_flash_drive.build_flags}
  244. #
  245. # Lerdge S
  246. #
  247. [env:LERDGES]
  248. platform = ${lerdge_common.platform}
  249. extends = lerdge_common
  250. board_build.firmware = Lerdge_firmware_force.bin
  251. #
  252. # Lerdge S with USB Flash Drive Support
  253. #
  254. [env:LERDGES_usb_flash_drive]
  255. platform = ${env:LERDGES.platform}
  256. extends = env:LERDGES
  257. platform_packages = ${stm_flash_drive.platform_packages}
  258. build_flags = ${stm_flash_drive.build_flags}
  259. #
  260. # Lerdge K
  261. #
  262. [env:LERDGEK]
  263. platform = ${lerdge_common.platform}
  264. extends = lerdge_common
  265. board_build.firmware = Lerdge_K_firmware_force.bin
  266. build_flags = ${lerdge_common.build_flags}
  267. -DLERDGEK
  268. #
  269. # Lerdge K with USB Flash Drive Support
  270. #
  271. [env:LERDGEK_usb_flash_drive]
  272. platform = ${env:LERDGEK.platform}
  273. extends = env:LERDGEK
  274. platform_packages = ${stm_flash_drive.platform_packages}
  275. build_flags = ${stm_flash_drive.build_flags}
  276. #
  277. # RUMBA32
  278. #
  279. [env:rumba32]
  280. platform = ${common_stm32.platform}
  281. extends = common_stm32
  282. build_flags = ${common_stm32.build_flags}
  283. -Os
  284. -DHAL_PCD_MODULE_ENABLED
  285. -DDISABLE_GENERIC_SERIALUSB
  286. -DHAL_UART_MODULE_ENABLED
  287. -DTIMER_SERIAL=TIM9
  288. board = rumba32_f446ve
  289. upload_protocol = dfu
  290. monitor_speed = 500000
  291. board_build.core = stm32
  292. board_build.variant = MARLIN_F446VE
  293. board_build.ldscript = ldscript.ld
  294. board_build.offset = 0x0000
  295. board_build.encrypt = No
  296. board_build.firmware = firmware.bin
  297. extra_scripts = ${common.extra_scripts}
  298. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  299. buildroot/share/PlatformIO/scripts/stm32_bootloader.py
  300. #
  301. # MKS Robin Pro V2
  302. #
  303. [env:mks_robin_pro2]
  304. platform = ${common_stm32.platform}
  305. platform_packages = ${stm_flash_drive.platform_packages}
  306. extends = common_stm32
  307. build_flags = ${stm_flash_drive.build_flags}
  308. board = genericSTM32F407VET6
  309. board_build.core = stm32
  310. board_build.variant = MARLIN_F4x7Vx
  311. board_build.ldscript = ldscript.ld
  312. board_build.firmware = firmware.bin
  313. board_build.offset = 0x0000
  314. board_upload.offset_address = 0x08000000
  315. build_unflags = ${common_stm32.build_unflags} -DUSBCON -DUSBD_USE_CDC
  316. debug_tool = jlink
  317. upload_protocol = jlink
  318. extra_scripts = ${common.extra_scripts}
  319. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  320. buildroot/share/PlatformIO/scripts/stm32_bootloader.py
  321. #
  322. # This SPI is used by Robin Nano V3
  323. #
  324. [stm32f4_I2C1]
  325. build_flags = -DPIN_WIRE_SCL=PB6 -DPIN_WIRE_SDA=PB7
  326. #
  327. # MKS Robin Nano V3
  328. #
  329. [env:mks_robin_nano_v3]
  330. platform = ${common_stm32.platform}
  331. extends = common_stm32
  332. build_flags = ${common_stm32.build_flags} ${stm32f4_I2C1.build_flags} -DHAL_PCD_MODULE_ENABLED -DUSBCON -DUSBD_USE_CDC
  333. board = genericSTM32F407VGT6
  334. board_build.core = stm32
  335. board_build.variant = MARLIN_F4x7Vx
  336. board_build.ldscript = ldscript.ld
  337. board_build.firmware = Robin_nano_v3.bin
  338. board_build.offset = 0xC000
  339. board_upload.offset_address = 0x0800C000
  340. build_unflags = ${common_stm32.build_unflags}
  341. debug_tool = jlink
  342. upload_protocol = jlink
  343. extra_scripts = ${common.extra_scripts}
  344. pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  345. buildroot/share/PlatformIO/scripts/stm32_bootloader.py
  346. #
  347. # MKS Robin Nano V3 with USB Flash Drive Support
  348. # Currently, using a STM32duino fork, until USB Host get merged
  349. #
  350. [env:mks_robin_nano_v3_usb_flash_drive]
  351. extends = env:mks_robin_nano_v3
  352. platform_packages = ${stm_flash_drive.platform_packages}
  353. build_flags = ${stm_flash_drive.build_flags} ${stm32f4_I2C1.build_flags}
  354. -DUSBCON
  355. -DUSE_USBHOST_HS
  356. -DUSBD_IRQ_PRIO=5
  357. -DUSBD_IRQ_SUBPRIO=6
  358. -DUSE_USB_HS_IN_FS
  359. -DUSBD_USE_CDC
  360. #
  361. # MKS Robin Nano V3 with USB Flash Drive Support and Shared Media
  362. # Currently, using a STM32duino fork, until USB Host and USB Device MSC get merged
  363. #
  364. [env:mks_robin_nano_v3_usb_flash_drive_msc]
  365. platform = ${common_stm32.platform}
  366. extends = env:mks_robin_nano_v3
  367. platform_packages = framework-arduinoststm32@https://github.com/rhapsodyv/Arduino_Core_STM32/archive/usb-host-msc-cdc-msc.zip
  368. build_unflags = ${common_stm32.build_unflags} -DUSBD_USE_CDC
  369. build_flags = ${stm_flash_drive.build_flags} ${stm32f4_I2C1.build_flags}
  370. -DUSBCON
  371. -DUSE_USBHOST_HS
  372. -DUSBD_IRQ_PRIO=5
  373. -DUSBD_IRQ_SUBPRIO=6
  374. -DUSE_USB_HS_IN_FS
  375. -DUSBD_USE_CDC_MSC