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.

platformio.ini 30KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870
  1. #
  2. # Marlin Firmware
  3. # PlatformIO Configuration File
  4. #
  5. # For detailed documentation with EXAMPLES:
  6. #
  7. # http://docs.platformio.org/en/latest/projectconf.html
  8. #
  9. # Automatic targets - enable auto-uploading
  10. # targets = upload
  11. #
  12. # By default platformio build will abort after 5 errors.
  13. # Remove '-fmax-errors=5' from build_flags below to see all.
  14. #
  15. [platformio]
  16. src_dir = Marlin
  17. boards_dir = buildroot/share/PlatformIO/boards
  18. default_envs = mega2560
  19. [common]
  20. default_src_filter = +<src/*> -<src/config> -<src/HAL> +<src/HAL/shared>
  21. extra_scripts = pre:buildroot/share/PlatformIO/scripts/common-cxxflags.py
  22. build_flags = -fmax-errors=5 -g -D__MARLIN_FIRMWARE__ -fmerge-all-constants
  23. lib_deps =
  24. LiquidCrystal
  25. TMCStepper@>=0.6.2,<1.0.0
  26. Adafruit NeoPixel
  27. U8glib-HAL=https://github.com/MarlinFirmware/U8glib-HAL/archive/bugfix.zip
  28. Adafruit_MAX31865=https://github.com/adafruit/Adafruit_MAX31865/archive/master.zip
  29. LiquidTWI2=https://github.com/lincomatic/LiquidTWI2/archive/master.zip
  30. Arduino-L6470=https://github.com/ameyer/Arduino-L6470/archive/0.8.0.zip
  31. SailfishLCD=https://github.com/mikeshub/SailfishLCD/archive/master.zip
  32. SlowSoftI2CMaster=https://github.com/mikeshub/SlowSoftI2CMaster/archive/master.zip
  33. # Globally defined properties
  34. # inherited by all environments
  35. [env]
  36. framework = arduino
  37. build_flags = ${common.build_flags}
  38. lib_deps = ${common.lib_deps}
  39. monitor_speed = 250000
  40. #################################
  41. # #
  42. # Unique Core Architectures #
  43. # #
  44. # Add a new "env" below if no #
  45. # entry has values suitable to #
  46. # build for a given board. #
  47. # #
  48. #################################
  49. #
  50. # ATmega2560
  51. #
  52. [env:mega2560]
  53. platform = atmelavr
  54. board = megaatmega2560
  55. board_build.f_cpu = 16000000L
  56. lib_deps = ${common.lib_deps}
  57. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  58. src_filter = ${common.default_src_filter} +<src/HAL/AVR>
  59. #
  60. # ATmega1280
  61. #
  62. [env:mega1280]
  63. platform = atmelavr
  64. board = megaatmega1280
  65. board_build.f_cpu = 16000000L
  66. lib_deps = ${common.lib_deps}
  67. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  68. src_filter = ${common.default_src_filter} +<src/HAL/AVR>
  69. #
  70. # RAMBo
  71. #
  72. [env:rambo]
  73. platform = atmelavr
  74. board = reprap_rambo
  75. board_build.f_cpu = 16000000L
  76. lib_deps = ${common.lib_deps}
  77. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  78. src_filter = ${common.default_src_filter} +<src/HAL/AVR>
  79. #
  80. # FYSETC F6 V1.3
  81. #
  82. [env:FYSETC_F6_13]
  83. platform = atmelavr
  84. board = fysetc_f6_13
  85. board_build.f_cpu = 16000000L
  86. lib_deps = ${common.lib_deps}
  87. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  88. src_filter = ${common.default_src_filter} +<src/HAL/AVR>
  89. #
  90. # FYSETC F6 V1.4
  91. #
  92. [env:FYSETC_F6_14]
  93. platform = atmelavr
  94. board = fysetc_f6_14
  95. board_build.f_cpu = 16000000L
  96. lib_deps = ${common.lib_deps}
  97. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  98. src_filter = ${common.default_src_filter} +<src/HAL/AVR>
  99. #
  100. # Sanguinololu (ATmega644p)
  101. #
  102. [env:sanguino644p]
  103. platform = atmelavr
  104. board = sanguino_atmega644p
  105. lib_deps = ${common.lib_deps}
  106. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  107. src_filter = ${common.default_src_filter} +<src/HAL/AVR>
  108. #
  109. # Sanguinololu (ATmega1284p)
  110. #
  111. [env:sanguino1284p]
  112. platform = atmelavr
  113. board = sanguino_atmega1284p
  114. lib_deps = ${common.lib_deps}
  115. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  116. src_filter = ${common.default_src_filter} +<src/HAL/AVR>
  117. #
  118. # Melzi and clones (ATmega1284p)
  119. #
  120. [env:melzi]
  121. platform = atmelavr
  122. board = sanguino_atmega1284p
  123. lib_deps = ${common.lib_deps}
  124. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  125. src_filter = ${common.default_src_filter} +<src/HAL/AVR>
  126. lib_ignore = TMCStepper
  127. upload_speed = 57600
  128. #
  129. # Melzi and clones (Optiboot bootloader)
  130. #
  131. [env:melzi_optiboot]
  132. platform = atmelavr
  133. board = sanguino_atmega1284p
  134. lib_deps = ${common.lib_deps}
  135. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  136. src_filter = ${common.default_src_filter} +<src/HAL/AVR>
  137. lib_ignore = TMCStepper
  138. upload_speed = 115200
  139. #
  140. # AT90USB1286 boards using CDC bootloader
  141. # - BRAINWAVE
  142. # - BRAINWAVE_PRO
  143. # - SAV_MKI
  144. # - TEENSYLU
  145. #
  146. [env:at90usb1286_cdc]
  147. platform = teensy
  148. board = at90usb1286
  149. lib_deps = ${common.lib_deps}
  150. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  151. lib_ignore = TMCStepper
  152. src_filter = ${common.default_src_filter} +<src/HAL/AVR>
  153. #
  154. # AT90USB1286 boards using DFU bootloader
  155. # - PrintrBoard
  156. # - PrintrBoard Rev.F
  157. # - ? 5DPRINT ?
  158. #
  159. [env:at90usb1286_dfu]
  160. platform = teensy
  161. board = at90usb1286
  162. lib_deps = ${common.lib_deps}
  163. lib_ignore = TMCStepper
  164. src_filter = ${common.default_src_filter} +<src/HAL/AVR>
  165. #
  166. # Due (Atmel SAM3X8E ARM Cortex-M3)
  167. #
  168. # - RAMPS4DUE
  169. # - RADDS
  170. #
  171. [env:DUE]
  172. platform = atmelsam
  173. board = due
  174. src_filter = ${common.default_src_filter} +<src/HAL/DUE>
  175. [env:DUE_USB]
  176. platform = atmelsam
  177. board = dueUSB
  178. src_filter = ${common.default_src_filter} +<src/HAL/DUE>
  179. [env:DUE_debug]
  180. # Used when WATCHDOG_RESET_MANUAL is enabled
  181. platform = atmelsam
  182. board = due
  183. src_filter = ${common.default_src_filter} +<src/HAL/DUE>
  184. build_flags = ${common.build_flags}
  185. -funwind-tables
  186. -mpoke-function-name
  187. #
  188. # Archim SAM
  189. #
  190. [env:DUE_archim]
  191. platform = atmelsam
  192. board = due
  193. src_filter = ${common.default_src_filter} +<src/HAL/DUE>
  194. build_flags = ${common.build_flags}
  195. -DARDUINO_SAM_ARCHIM -DARDUINO_ARCH_SAM -D__SAM3X8E__ -DUSBCON
  196. [env:DUE_archim_debug]
  197. # Used when WATCHDOG_RESET_MANUAL is enabled
  198. platform = atmelsam
  199. board = due
  200. src_filter = ${common.default_src_filter} +<src/HAL/DUE>
  201. build_flags = ${common.build_flags}
  202. -DARDUINO_SAM_ARCHIM -DARDUINO_ARCH_SAM -D__SAM3X8E__ -DUSBCON
  203. -funwind-tables -mpoke-function-name
  204. #
  205. # NXP LPC176x ARM Cortex-M3
  206. #
  207. [env:LPC1768]
  208. platform = https://github.com/p3p/pio-nxplpc-arduino-lpc176x/archive/0.1.2.zip
  209. board = nxp_lpc1768
  210. build_flags = -DU8G_HAL_LINKS -IMarlin/src/HAL/LPC1768/include -IMarlin/src/HAL/LPC1768/u8g ${common.build_flags}
  211. # debug options for backtrace
  212. # -funwind-tables
  213. # -mpoke-function-name
  214. lib_ldf_mode = off
  215. lib_compat_mode = strict
  216. extra_scripts = Marlin/src/HAL/LPC1768/upload_extra_script.py
  217. src_filter = ${common.default_src_filter} +<src/HAL/LPC1768>
  218. lib_deps = Servo
  219. LiquidCrystal
  220. U8glib-HAL=https://github.com/MarlinFirmware/U8glib-HAL/archive/bugfix.zip
  221. TMCStepper@>=0.6.1,<1.0.0
  222. Adafruit NeoPixel=https://github.com/p3p/Adafruit_NeoPixel/archive/release.zip
  223. SailfishLCD=https://github.com/mikeshub/SailfishLCD/archive/master.zip
  224. [env:LPC1769]
  225. platform = https://github.com/p3p/pio-nxplpc-arduino-lpc176x/archive/0.1.2.zip
  226. board = nxp_lpc1769
  227. build_flags = -DU8G_HAL_LINKS -IMarlin/src/HAL/LPC1768/include -IMarlin/src/HAL/LPC1768/u8g ${common.build_flags}
  228. # debug options for backtrace
  229. # -funwind-tables
  230. # -mpoke-function-name
  231. lib_ldf_mode = off
  232. lib_compat_mode = strict
  233. extra_scripts = Marlin/src/HAL/LPC1768/upload_extra_script.py
  234. src_filter = ${common.default_src_filter} +<src/HAL/LPC1768>
  235. lib_deps = Servo
  236. LiquidCrystal
  237. U8glib-HAL=https://github.com/MarlinFirmware/U8glib-HAL/archive/bugfix.zip
  238. TMCStepper@>=0.6.1,<1.0.0
  239. Adafruit NeoPixel=https://github.com/p3p/Adafruit_NeoPixel/archive/release.zip
  240. SailfishLCD=https://github.com/mikeshub/SailfishLCD/archive/master.zip
  241. #
  242. # STM32F103RC
  243. #
  244. [env:STM32F103RC]
  245. platform = ststm32
  246. board = genericSTM32F103RC
  247. platform_packages = tool-stm32duino
  248. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  249. ${common.build_flags} -std=gnu++14
  250. build_unflags = -std=gnu++11
  251. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  252. lib_deps = ${common.lib_deps}
  253. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  254. lib_ignore = Adafruit NeoPixel, SPI
  255. monitor_speed = 115200
  256. #
  257. # STM32F103RC_fysetc
  258. #
  259. [env:STM32F103RC_fysetc]
  260. platform = ststm32
  261. board = genericSTM32F103RC
  262. #board_build.core = maple
  263. platform_packages = tool-stm32duino
  264. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  265. ${common.build_flags} -std=gnu++14 -DDEBUG_LEVEL=0 -DHAVE_SW_SERIAL
  266. build_unflags = -std=gnu++11
  267. extra_scripts = buildroot/share/PlatformIO/scripts/STM32F103RC_fysetc.py
  268. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  269. lib_deps = ${common.lib_deps}
  270. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  271. lib_ignore = Adafruit NeoPixel, SPI
  272. lib_ldf_mode = chain
  273. debug_tool = stlink
  274. upload_protocol = serial
  275. #
  276. # BigTree SKR Mini V1.1 / SKR mini E3 / SKR E3 DIP (STM32F103RCT6 ARM Cortex-M3)
  277. #
  278. # STM32F103RC_btt ............. RCT6 with 256K
  279. # STM32F103RC_btt_USB ......... RCT6 with 256K (USB mass storage)
  280. # STM32F103RC_btt_512K ........ RCT6 with 512K
  281. # STM32F103RC_btt_512K_USB .... RCT6 with 512K (USB mass storage)
  282. #
  283. [env:STM32F103RC_btt]
  284. platform = ststm32
  285. board = genericSTM32F103RC
  286. platform_packages = tool-stm32duino
  287. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  288. ${common.build_flags} -DDEBUG_LEVEL=0 -std=gnu++14 -DHAVE_SW_SERIAL -DSS_TIMER=4
  289. build_unflags = -std=gnu++11
  290. extra_scripts = buildroot/share/PlatformIO/scripts/STM32F103RC_SKR_MINI.py
  291. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  292. lib_deps = ${common.lib_deps}
  293. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  294. lib_ignore = Adafruit NeoPixel, SPI
  295. monitor_speed = 115200
  296. [env:STM32F103RC_btt_USB]
  297. platform = ststm32
  298. board = genericSTM32F103RC
  299. platform_packages = tool-stm32duino
  300. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  301. ${common.build_flags} -DDEBUG_LEVEL=0 -std=gnu++14 -DHAVE_SW_SERIAL -DSS_TIMER=4 -DUSE_USB_COMPOSITE
  302. build_unflags = -std=gnu++11
  303. extra_scripts = buildroot/share/PlatformIO/scripts/STM32F103RC_SKR_MINI.py
  304. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  305. lib_deps = ${common.lib_deps}
  306. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  307. USBComposite for STM32F1@==0.91
  308. lib_ignore = Adafruit NeoPixel, SPI
  309. monitor_speed = 115200
  310. [env:STM32F103RC_btt_512K]
  311. platform = ststm32
  312. board = genericSTM32F103RC
  313. board_upload.maximum_size=524288
  314. platform_packages = tool-stm32duino
  315. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  316. ${common.build_flags} -DDEBUG_LEVEL=0 -std=gnu++14 -DHAVE_SW_SERIAL -DSS_TIMER=4 -DSTM32_FLASH_SIZE=512
  317. build_unflags = -std=gnu++11
  318. extra_scripts = buildroot/share/PlatformIO/scripts/STM32F103RC_SKR_MINI.py
  319. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  320. lib_deps = ${common.lib_deps}
  321. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  322. lib_ignore = Adafruit NeoPixel, SPI
  323. monitor_speed = 115200
  324. [env:STM32F103RC_btt_512K_USB]
  325. platform = ststm32
  326. board = genericSTM32F103RC
  327. board_upload.maximum_size=524288
  328. platform_packages = tool-stm32duino
  329. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  330. ${common.build_flags} -DDEBUG_LEVEL=0 -std=gnu++14 -DHAVE_SW_SERIAL -DSS_TIMER=4 -DSTM32_FLASH_SIZE=512 -DUSE_USB_COMPOSITE
  331. build_unflags = -std=gnu++11
  332. extra_scripts = buildroot/share/PlatformIO/scripts/STM32F103RC_SKR_MINI.py
  333. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  334. lib_deps = ${common.lib_deps}
  335. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  336. USBComposite for STM32F1@==0.91
  337. lib_ignore = Adafruit NeoPixel, SPI
  338. monitor_speed = 115200
  339. #
  340. # STM32F103RE
  341. #
  342. [env:STM32F103RE]
  343. platform = ststm32
  344. board = genericSTM32F103RE
  345. platform_packages = tool-stm32duino
  346. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  347. ${common.build_flags} -std=gnu++14
  348. build_unflags = -std=gnu++11
  349. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  350. lib_deps = ${common.lib_deps}
  351. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  352. lib_ignore = Adafruit NeoPixel, SPI
  353. monitor_speed = 115200
  354. #
  355. # STM32F103RE_btt ............. RET6
  356. # STM32F103RE_btt_USB ......... RET6 (USB mass storage)
  357. #
  358. [env:STM32F103RE_btt]
  359. platform = ststm32
  360. board = genericSTM32F103RE
  361. platform_packages = tool-stm32duino
  362. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  363. ${common.build_flags} -DDEBUG_LEVEL=0 -std=gnu++14 -DHAVE_SW_SERIAL -DSS_TIMER=4
  364. build_unflags = -std=gnu++11
  365. extra_scripts = buildroot/share/PlatformIO/scripts/STM32F103RE_SKR_E3_DIP.py
  366. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  367. lib_deps = ${common.lib_deps}
  368. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  369. lib_ignore = Adafruit NeoPixel, SPI
  370. debug_tool = stlink
  371. upload_protocol = stlink
  372. monitor_speed = 115200
  373. [env:STM32F103RE_btt_USB]
  374. platform = ststm32
  375. board = genericSTM32F103RE
  376. platform_packages = tool-stm32duino
  377. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  378. ${common.build_flags} -DDEBUG_LEVEL=0 -std=gnu++14 -DHAVE_SW_SERIAL -DSS_TIMER=4 -DUSE_USB_COMPOSITE
  379. build_unflags = -std=gnu++11
  380. extra_scripts = buildroot/share/PlatformIO/scripts/STM32F103RE_SKR_E3_DIP.py
  381. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  382. lib_deps = ${common.lib_deps}
  383. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  384. USBComposite for STM32F1@==0.91
  385. lib_ignore = Adafruit NeoPixel, SPI
  386. debug_tool = stlink
  387. upload_protocol = stlink
  388. monitor_speed = 115200
  389. #
  390. # STM32F4 with STM32GENERIC
  391. #
  392. [env:STM32F4]
  393. platform = ststm32
  394. board = disco_f407vg
  395. build_flags = ${common.build_flags} -DUSE_STM32GENERIC -DSTM32GENERIC -DSTM32F4 -DMENU_USB_SERIAL -DMENU_SERIAL=SerialUSB -DHAL_IWDG_MODULE_ENABLED
  396. lib_ignore = Adafruit NeoPixel, TMCStepper
  397. src_filter = ${common.default_src_filter} +<src/HAL/STM32_F4_F7> -<src/HAL/STM32_F4_F7/STM32F7>
  398. #
  399. # STM32F7 with STM32GENERIC
  400. #
  401. [env:STM32F7]
  402. platform = ststm32
  403. board = remram_v1
  404. build_flags = ${common.build_flags} -DUSE_STM32GENERIC -DSTM32GENERIC -DSTM32F7 -DMENU_USB_SERIAL -DMENU_SERIAL=SerialUSB -DHAL_IWDG_MODULE_ENABLED
  405. lib_ignore = Adafruit NeoPixel, TMCStepper
  406. src_filter = ${common.default_src_filter} +<src/HAL/STM32_F4_F7> -<src/HAL/STM32_F4_F7/STM32F4>
  407. #
  408. # ARMED (STM32)
  409. #
  410. [env:ARMED]
  411. platform = ststm32
  412. board = armed_v1
  413. build_flags = ${common.build_flags}
  414. -DUSBCON -DUSBD_VID=0x0483 '-DUSB_MANUFACTURER="Unknown"' '-DUSB_PRODUCT="ARMED_V1"' -DUSBD_USE_CDC
  415. -O2 -ffreestanding -fsigned-char -fno-move-loop-invariants -fno-strict-aliasing -std=gnu11 -std=gnu++11
  416. -IMarlin/src/HAL/STM32
  417. lib_ignore = Adafruit NeoPixel, SoftwareSerial
  418. src_filter = ${common.default_src_filter} +<src/HAL/STM32>
  419. #
  420. # Geeetech GTM32 (STM32F103VET6)
  421. #
  422. [env:STM32F103VE_GTM32]
  423. platform = ststm32
  424. board = genericSTM32F103VE
  425. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  426. ${common.build_flags} -DDEBUG_LEVEL=DEBUG_NONE -std=gnu++14 -MMD -ffunction-sections -fdata-sections -nostdlib
  427. -DBOARD_generic_stm32f103v -DARDUINO_GENERIC_STM32F103V -DARDUINO_ARCH_STM32F1
  428. -DCONFIG_MAPLE_MINI_NO_DISABLE_DEBUG=1 -DVECT_TAB_ADDR=0x8000000 -DERROR_LED_PORT=GPIOE -DERROR_LED_PIN=6
  429. build_unflags = -std=gnu++11
  430. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  431. lib_ignore = Adafruit NeoPixel, SPI
  432. upload_protocol = serial
  433. #
  434. # Longer 3D board in Alfawise U20 (STM32F103VET6)
  435. #
  436. [env:STM32F103VE_longer]
  437. platform = ststm32
  438. board = genericSTM32F103VE
  439. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  440. ${common.build_flags} -std=gnu++14 -USERIAL_USB
  441. -DSTM32F1xx -DU20 -DTS_V12
  442. build_unflags = -std=gnu++11 -DCONFIG_MAPLE_MINI_NO_DISABLE_DEBUG=1 -DERROR_LED_PORT=GPIOE -DERROR_LED_PIN=6
  443. extra_scripts = buildroot/share/PlatformIO/scripts/STM32F103VE_longer.py
  444. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  445. lib_ignore = Adafruit NeoPixel, LiquidTWI2, SPI
  446. #
  447. # MKS Robin Mini (STM32F103VET6)
  448. #
  449. [env:mks_robin_mini]
  450. platform = ststm32
  451. board = genericSTM32F103VE
  452. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  453. ${common.build_flags} -std=gnu++14
  454. build_unflags = -std=gnu++11
  455. extra_scripts = buildroot/share/PlatformIO/scripts/mks_robin_mini.py
  456. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  457. lib_ignore = Adafruit NeoPixel, SPI
  458. #
  459. # MKS Robin Nano (STM32F103VET6)
  460. #
  461. [env:mks_robin_nano]
  462. platform = ststm32
  463. board = genericSTM32F103VE
  464. platform_packages = tool-stm32duino
  465. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  466. ${common.build_flags} -std=gnu++14 -DHAVE_SW_SERIAL -DSS_TIMER=4
  467. build_unflags = -std=gnu++11
  468. extra_scripts = buildroot/share/PlatformIO/scripts/mks_robin_nano.py
  469. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  470. lib_deps = ${common.lib_deps}
  471. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  472. lib_ignore = Adafruit NeoPixel, SPI
  473. #
  474. # MKS Robin (STM32F103ZET6)
  475. #
  476. [env:mks_robin]
  477. platform = ststm32
  478. board = genericSTM32F103ZE
  479. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  480. ${common.build_flags} -std=gnu++14 -DHAVE_SW_SERIAL -DSS_TIMER=4 -DSTM32_XL_DENSITY
  481. build_unflags = -std=gnu++11
  482. extra_scripts = buildroot/share/PlatformIO/scripts/mks_robin.py
  483. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  484. lib_deps = ${common.lib_deps}
  485. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  486. lib_ignore = Adafruit NeoPixel, SPI
  487. #
  488. # MKS Robin Pro (STM32F103ZET6)
  489. #
  490. [env:mks_robin_pro]
  491. platform = ststm32
  492. board = genericSTM32F103ZE
  493. extra_scripts = buildroot/share/PlatformIO/scripts/mks_robin_pro.py
  494. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  495. ${common.build_flags} -std=gnu++14 -DSTM32_XL_DENSITY
  496. build_unflags = -std=gnu++11
  497. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  498. lib_deps = ${common.lib_deps}
  499. lib_ignore = Adafruit NeoPixel, SPI, TMCStepper
  500. #
  501. # MKS Robin Lite/Lite2 (STM32F103RCT6)
  502. #
  503. [env:mks_robin_lite]
  504. platform = ststm32
  505. board = genericSTM32F103RC
  506. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  507. ${common.build_flags} -std=gnu++14
  508. build_unflags = -std=gnu++11
  509. extra_scripts = buildroot/share/PlatformIO/scripts/mks_robin_lite.py
  510. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  511. lib_ignore = Adafruit NeoPixel, SPI
  512. #
  513. # MKS ROBIN LITE3 (STM32F103RCT6)
  514. #
  515. [env:mks_robin_lite3]
  516. platform = ststm32
  517. board = genericSTM32F103RC
  518. extra_scripts = buildroot/share/PlatformIO/scripts/mks_robin_lite3.py
  519. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  520. ${common.build_flags} -std=gnu++14
  521. build_unflags = -std=gnu++11
  522. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  523. lib_deps = ${common.lib_deps}
  524. lib_ignore = Adafruit NeoPixel, SPI
  525. #
  526. # JGAurora A5S A1 (STM32F103ZET6)
  527. #
  528. [env:jgaurora_a5s_a1]
  529. platform = ststm32
  530. board = genericSTM32F103ZE
  531. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  532. ${common.build_flags} -DSTM32F1xx -std=gnu++14 -DSTM32_XL_DENSITY
  533. build_unflags = -std=gnu++11
  534. extra_scripts = buildroot/share/PlatformIO/scripts/jgaurora_a5s_a1_with_bootloader.py
  535. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  536. lib_ignore = Adafruit NeoPixel, SPI
  537. #
  538. # Malyan M200 (STM32F103CB)
  539. #
  540. [env:STM32F103CB_malyan]
  541. platform = ststm32
  542. board = malyanM200
  543. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py -DMCU_STM32F103CB -D __STM32F1__=1 -std=c++1y -D MOTHERBOARD="BOARD_MALYAN_M200" -DSERIAL_USB -ffunction-sections -fdata-sections -Wl,--gc-sections
  544. -DDEBUG_LEVEL=0 -D__MARLIN_FIRMWARE__
  545. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  546. lib_ignore = Adafruit NeoPixel, LiquidCrystal, LiquidTWI2, TMCStepper, U8glib-HAL, SPI
  547. #
  548. # Chitu boards like Tronxy X5s (STM32F103ZET6)
  549. #
  550. [env:chitu_f103]
  551. platform = ststm32
  552. board = genericSTM32F103ZE
  553. build_flags = !python Marlin/src/HAL/STM32F1/build_flags.py
  554. ${common.build_flags} -DSTM32F1xx -std=gnu++14 -DSTM32_XL_DENSITY
  555. build_unflags = -std=gnu++11 -DCONFIG_MAPLE_MINI_NO_DISABLE_DEBUG= -DERROR_LED_PORT=GPIOE -DERROR_LED_PIN=6
  556. extra_scripts = buildroot/share/PlatformIO/scripts/chitu_crypt.py
  557. src_filter = ${common.default_src_filter} +<src/HAL/STM32F1>
  558. lib_ignore = Adafruit NeoPixel
  559. #
  560. # STM32F401VE
  561. # 'STEVAL-3DP001V1' STM32F401VE board - https://www.st.com/en/evaluation-tools/steval-3dp001v1.html
  562. #
  563. [env:STM32F401VE_STEVAL]
  564. platform = ststm32
  565. board = STEVAL_STM32F401VE
  566. platform_packages = framework-arduinoststm32@>=3.107,<4
  567. build_flags = ${common.build_flags}
  568. -DTARGET_STM32F4 -DARDUINO_STEVAL -DSTM32F401xE
  569. -DUSBCON -DUSBD_USE_CDC -DUSBD_VID=0x0483 -DUSB_PRODUCT=\"STEVAL_F401VE\"
  570. -DDISABLE_GENERIC_SERIALUSB
  571. -IMarlin/src/HAL/STM32
  572. build_unflags = -std=gnu++11
  573. extra_scripts = pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  574. buildroot/share/PlatformIO/scripts/STEVAL__F401XX.py
  575. lib_ignore = Adafruit NeoPixel, TMCStepper, SailfishLCD, SlowSoftI2CMaster, SoftwareSerial
  576. src_filter = ${common.default_src_filter} +<src/HAL/STM32>
  577. #
  578. # FLYF407ZG
  579. #
  580. [env:FLYF407ZG]
  581. platform = ststm32
  582. board = FLYF407ZG
  583. platform_packages = framework-arduinoststm32@>=3.107,<4
  584. build_flags = ${common.build_flags}
  585. -DSTM32F4 -DUSBCON -DUSBD_USE_CDC -DUSBD_VID=0x0483 -DUSB_PRODUCT=\"STM32F407ZG\"
  586. -DTARGET_STM32F4 -DVECT_TAB_OFFSET=0x8000
  587. -IMarlin/src/HAL/STM32
  588. build_unflags = -std=gnu++11
  589. extra_scripts = pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  590. lib_ignore = Adafruit NeoPixel, TMCStepper, SailfishLCD, SlowSoftI2CMaster, SoftwareSerial
  591. src_filter = ${common.default_src_filter} +<src/HAL/STM32>
  592. #
  593. # FYSETC S6 (STM32F446VET6 ARM Cortex-M4)
  594. #
  595. [env:FYSETC_S6]
  596. platform = ststm32
  597. board = fysetc_s6
  598. platform_packages =
  599. tool-stm32duino
  600. framework-arduinoststm32@>=3.107,<4
  601. build_flags = ${common.build_flags}
  602. -DTARGET_STM32F4 -std=gnu++14
  603. -DVECT_TAB_OFFSET=0x10000
  604. -DUSBCON -DUSBD_USE_CDC -DHAL_PCD_MODULE_ENABLED -DUSBD_VID=0x0483 '-DUSB_PRODUCT="FYSETC_S6"'
  605. build_unflags = -std=gnu++11
  606. extra_scripts = pre:buildroot/share/PlatformIO/scripts/fysetc_STM32S6.py
  607. src_filter = ${common.default_src_filter} +<src/HAL/STM32>
  608. lib_ignore = Arduino-L6470
  609. debug_tool = stlink
  610. #upload_protocol = stlink
  611. upload_protocol = serial
  612. #
  613. # STM32F407VET6 with RAMPS-like shield
  614. # 'Black' STM32F407VET6 board - http://wiki.stm32duino.com/index.php?title=STM32F407
  615. # Shield - https://github.com/jmz52/Hardware
  616. #
  617. [env:STM32F407VE_black]
  618. platform = ststm32
  619. board = blackSTM32F407VET6
  620. platform_packages = framework-arduinoststm32@>=3.107,<4
  621. build_flags = ${common.build_flags}
  622. -DTARGET_STM32F4 -DARDUINO_BLACK_F407VE
  623. -DUSBCON -DUSBD_USE_CDC -DUSBD_VID=0x0483 -DUSB_PRODUCT=\"BLACK_F407VE\"
  624. -IMarlin/src/HAL/STM32
  625. build_unflags = -std=gnu++11
  626. extra_scripts = pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  627. lib_ignore = Adafruit NeoPixel, TMCStepper, SailfishLCD, SlowSoftI2CMaster, SoftwareSerial
  628. src_filter = ${common.default_src_filter} +<src/HAL/STM32>
  629. #
  630. # BigTreeTech SKR Pro (STM32F407ZGT6 ARM Cortex-M4)
  631. #
  632. [env:BIGTREE_SKR_PRO]
  633. platform = ststm32
  634. board = BigTree_SKR_Pro
  635. platform_packages = framework-arduinoststm32@>=3.107,<4
  636. build_flags = ${common.build_flags}
  637. -DUSBCON -DUSBD_USE_CDC -DUSBD_VID=0x0483 -DUSB_PRODUCT=\"STM32F407ZG\"
  638. -DTARGET_STM32F4 -DSTM32F407_5ZX -DVECT_TAB_OFFSET=0x8000
  639. -IMarlin/src/HAL/STM32
  640. build_unflags = -std=gnu++11
  641. extra_scripts = pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  642. lib_ignore = SoftwareSerial, SoftwareSerialM
  643. src_filter = ${common.default_src_filter} +<src/HAL/STM32>
  644. #upload_protocol = stlink
  645. #upload_command = "$PROJECT_PACKAGES_DIR/tool-stm32duino/stlink/ST-LINK_CLI.exe" -c SWD -P "$BUILD_DIR/firmware.bin" 0x8008000 -Rst -Run
  646. debug_tool = stlink
  647. debug_init_break =
  648. #
  649. # Bigtreetech GTR V1.0 (STM32F407IGT6 ARM Cortex-M4)
  650. #
  651. [env:BIGTREE_GTR_V1_0]
  652. platform = ststm32@>=5.7.0
  653. framework = arduino
  654. platform_packages = framework-arduinoststm32@>=3.107,<4
  655. board = BigTree_SKR_Pro
  656. extra_scripts = pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  657. build_flags = ${common.build_flags}
  658. -DUSBCON -DUSBD_USE_CDC -DUSBD_VID=0x0483 -DUSB_PRODUCT=\"STM32F407IG\"
  659. -DTARGET_STM32F4 -DSTM32F407IX -DVECT_TAB_OFFSET=0x8000
  660. -IMarlin/src/HAL/STM32
  661. lib_deps =
  662. U8glib-HAL=https://github.com/MarlinFirmware/U8glib-HAL/archive/bugfix.zip
  663. LiquidCrystal
  664. TMCStepper@>=0.5.2,<1.0.0
  665. Adafruit NeoPixel
  666. LiquidTWI2=https://github.com/lincomatic/LiquidTWI2/archive/master.zip
  667. Arduino-L6470=https://github.com/ameyer/Arduino-L6470/archive/dev.zip
  668. lib_ignore = SoftwareSerial, SoftwareSerialM
  669. src_filter = ${common.default_src_filter} +<src/HAL/STM32>
  670. monitor_speed = 250000
  671. #
  672. # BigTreeTech BTT002 V1.0 (STM32F407VGT6 ARM Cortex-M4)
  673. #
  674. [env:BIGTREE_BTT002]
  675. platform = ststm32@5.6.0
  676. board = BigTree_Btt002
  677. platform_packages = framework-arduinoststm32@>=3.107,<4
  678. build_flags = ${common.build_flags}
  679. -DUSBCON -DUSBD_USE_CDC -DUSBD_VID=0x0483 -DUSB_PRODUCT=\"STM32F407VG\"
  680. -DTARGET_STM32F4 -DSTM32F407_5VX -DVECT_TAB_OFFSET=0x8000
  681. -DHAVE_HWSERIAL2
  682. -DHAVE_HWSERIAL3
  683. -DPIN_SERIAL2_RX=PD_6
  684. -DPIN_SERIAL2_TX=PD_5
  685. build_unflags = -std=gnu++11
  686. extra_scripts = pre:buildroot/share/PlatformIO/scripts/generic_create_variant.py
  687. lib_ignore = Adafruit NeoPixel, SailfishLCD, SlowSoftI2CMaster
  688. src_filter = ${common.default_src_filter} +<src/HAL/STM32>
  689. #
  690. # Teensy 3.1 / 3.2 (ARM Cortex-M4)
  691. #
  692. [env:teensy31]
  693. platform = teensy
  694. board = teensy31
  695. lib_deps = ${common.lib_deps}
  696. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  697. lib_ignore = Adafruit NeoPixel
  698. src_filter = ${common.default_src_filter} +<src/HAL/TEENSY31_32>
  699. #
  700. # Teensy 3.5 / 3.6 (ARM Cortex-M4)
  701. #
  702. [env:teensy35]
  703. platform = teensy
  704. board = teensy35
  705. lib_deps = ${common.lib_deps}
  706. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  707. lib_ignore = Adafruit NeoPixel
  708. src_filter = ${common.default_src_filter} +<src/HAL/TEENSY35_36>
  709. #
  710. # Espressif ESP32
  711. #
  712. [env:esp32]
  713. platform = espressif32@1.11.2
  714. board = esp32dev
  715. build_flags = ${common.build_flags} -DCORE_DEBUG_LEVEL=0
  716. lib_deps = ${common.lib_deps}
  717. AsyncTCP=https://github.com/me-no-dev/AsyncTCP/archive/master.zip
  718. ESPAsyncWebServer=https://github.com/me-no-dev/ESPAsyncWebServer/archive/master.zip
  719. ESP3DLib=https://github.com/luc-github/ESP3DLib.git
  720. arduinoWebSockets=https://github.com/Links2004/arduinoWebSockets.git
  721. ESP32SSDP=https://github.com/luc-github/ESP32SSDP.git
  722. lib_ignore = LiquidCrystal, LiquidTWI2, SailfishLCD, ESPAsyncTCP
  723. src_filter = ${common.default_src_filter} +<src/HAL/ESP32>
  724. upload_speed = 115200
  725. #upload_port = marlinesp.local
  726. #board_build.flash_mode = qio
  727. #
  728. # Native
  729. # No supported Arduino libraries, base Marlin only
  730. #
  731. [env:linux_native]
  732. platform = native
  733. framework =
  734. build_flags = -D__PLAT_LINUX__ -std=gnu++17 -ggdb -g -lrt -lpthread -D__MARLIN_FIRMWARE__ -Wno-expansion-to-defined
  735. src_build_flags = -Wall -IMarlin/src/HAL/LINUX/include
  736. build_unflags = -Wall
  737. lib_ldf_mode = off
  738. lib_deps =
  739. src_filter = ${common.default_src_filter} +<src/HAL/LINUX>
  740. #
  741. # Adafruit Grand Central M4 (Atmel SAMD51P20A ARM Cortex-M4)
  742. #
  743. [env:SAMD51_grandcentral_m4]
  744. platform = atmelsam
  745. board = adafruit_grandcentral_m4
  746. build_flags = ${common.build_flags} -std=gnu++17 -Wno-register
  747. build_unflags = -std=gnu++11
  748. src_filter = ${common.default_src_filter} +<src/HAL/SAMD51>
  749. lib_deps = ${common.lib_deps}
  750. SoftwareSerialM=https://github.com/FYSETC/SoftwareSerialM/archive/master.zip
  751. Adafruit_SPIFlash=https://github.com/adafruit/Adafruit_SPIFlash/archive/master.zip
  752. debug_tool = jlink
  753. #
  754. # RUMBA32
  755. #
  756. [env:rumba32_f446ve]
  757. platform = ststm32
  758. board = rumba32_f446ve
  759. build_flags = ${common.build_flags}
  760. -DSTM32F4xx
  761. -DARDUINO_RUMBA32_F446VE
  762. -DARDUINO_ARCH_STM32
  763. "-DBOARD_NAME=\"RUMBA32_F446VE\""
  764. -DSTM32F446xx
  765. -DUSBCON
  766. -DUSBD_VID=0x0483
  767. "-DUSB_MANUFACTURER=\"Unknown\""
  768. "-DUSB_PRODUCT=\"RUMBA32_F446VE\""
  769. -DHAL_PCD_MODULE_ENABLED
  770. -DUSBD_USE_CDC
  771. -DDISABLE_GENERIC_SERIALUSB
  772. -DHAL_UART_MODULE_ENABLED
  773. -Os
  774. lib_ignore = Adafruit NeoPixel
  775. src_filter = ${common.default_src_filter} +<src/HAL/STM32>
  776. monitor_speed = 500000
  777. upload_protocol = dfu
  778. #
  779. # MKS RUMBA32 (adds TMC2208/2209 UART interface and AUX-1)
  780. #
  781. [env:rumba32_mks]
  782. platform = ststm32
  783. board = rumba32_f446ve
  784. build_flags = ${common.build_flags}
  785. -DSTM32F4xx -DARDUINO_RUMBA32_F446VE -DARDUINO_ARCH_STM32 "-DBOARD_NAME=\"RUMBA32_F446VE\""
  786. -DSTM32F446xx -DUSBCON -DUSBD_VID=0x8000
  787. "-DUSB_MANUFACTURER=\"Unknown\""
  788. "-DUSB_PRODUCT=\"RUMBA32_F446VE\""
  789. -DHAL_PCD_MODULE_ENABLED
  790. -DUSBD_USE_CDC
  791. -DDISABLE_GENERIC_SERIALUSB
  792. -DHAL_UART_MODULE_ENABLED
  793. -Os
  794. lib_ignore = Adafruit NeoPixel
  795. src_filter = ${common.default_src_filter} +<src/HAL/STM32> +<src/HAL/STM32_F4_F7> -<src/HAL/STM32_F4_F7/STM32F7>
  796. upload_protocol = dfu
  797. #
  798. # Just print the dependency tree
  799. #
  800. [env:include_tree]
  801. platform = atmelavr
  802. board = megaatmega2560
  803. build_flags = -c -H -std=gnu++11 -Wall -Os -D__MARLIN_FIRMWARE__
  804. lib_deps = ${common.lib_deps}
  805. TMC26XStepper=https://github.com/trinamic/TMC26XStepper/archive/master.zip
  806. src_filter = +<src/Marlin.cpp>