Advertisement
Guest User

Untitled

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