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

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