forked from FastLED/FastLED
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathplatformio.ini
More file actions
256 lines (228 loc) · 9 KB
/
Copy pathplatformio.ini
File metadata and controls
256 lines (228 loc) · 9 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
[env]
; Global settings for all environments
; Symlink in the FastLED library so that changes to the library are reflected in the project
; build immediately.
lib_deps =
FastLED=symlink://./
; NOTE: build_cache_enable and build_cache_dir are not standard PlatformIO options
; Board-specific cache directories are now configured per-board in ci/ci/boards.py
;build_cache_enable = true
;build_cache_dir = ${platformio.build_cache_dir}
[env:generic-esp]
# Developement branch of the open source espressif32 platform
platform = https://github.com/pioarduino/platform-espressif32/releases/download/55.03.35/platform-espressif32.zip
framework = arduino
upload_protocol = esptool
monitor_filters =
default
esp32_exception_decoder ; Decode exceptions so that they are human readable.
; CRASH TRACE INVESTIGATION (2026-04-06):
; ESP32 Arduino framework includes built-in panic handler (Guru Meditation) that prints
; backtrace + register dump on crashes. The esp32_exception_decoder monitor filter above
; decodes addresses to file:line. For silent crashes (watchdog, brownout) with no output,
; the panic handler may not fire — CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT is the default.
; No additional crash handler implementation needed for stack traces.
build_type = debug
build_flags =
-DDEBUG
-DPIN_CLOCK=7
-DFASTLED_RMT5=1
-DESP32_ARDUINO_NO_RGB_BUILTIN=1
; -DFASTLED_LOG_RMT_ENABLED
; -DFASTLED_LOG_PARLIO_ENABLED
-DFASTLED_DEBUG=1
-g
-Og
-DCORE_DEBUG_LEVEL=5
-DLOG_LOCAL_LEVEL=ESP_LOG_VERBOSE
-DFASTLED_ESP32_SPI_BULK_TRANSFER=1
-D IDF_CCACHE_ENABLE=1
check_tool = clangtidy
[env:uno]
platform = atmelavr
board = uno
framework = arduino
[env:giga_r1_m7]
platform = ststm32
board = giga_r1_m7
framework = arduino
[env:esp32s3]
extends = env:generic-esp
board = seeed_xiao_esp32s3
; Flash mode: Use board default (QIO) for hardware, ci/boards.py sets DIO for QEMU builds
; Set flash size to 4MB to match QEMU configuration (seeed_xiao_esp32s3 default is 8MB)
; Use board_build.flash_size to set the binary header, not board_upload.flash_size
board_build.flash_size = 4MB
; Note: This partition table is for normal builds. QEMU builds use settings from ci/boards.py
; Use huge_app partition table to allow larger debug builds
board_build.partitions = huge_app.csv
build_flags =
${env:generic-esp.build_flags}
-D ARDUINO_USB_MODE=1
-D ARDUINO_USB_CDC_ON_BOOT=1
-D ARDUINO_LOOP_STACK_SIZE=16384
[env:esp32c6]
extends = env:generic-esp
board = esp32-c6-devkitc-1
build_flags =
${env:generic-esp.build_flags}
-D ARDUINO_USB_MODE=1
-D ARDUINO_USB_CDC_ON_BOOT=1
-D CONFIG_PARLIO_TX_ISR_HANDLER_IN_IRAM=1
-D CONFIG_PARLIO_TX_ISR_CACHE_SAFE=1
-D ARDUINO_LOOP_STACK_SIZE=16384
-D PIN_DATA=21
-D PARLIO_FORCE_LSB_MODE=0
; Optional: fix early prints
; Flash mode: Use board default (QIO) for hardware, ci/boards.py sets DIO for QEMU builds
board_build.flash_size = 4MB
board_upload.flash_size = 4MB
board_build.partitions = huge_app.csv
[env:esp32p4]
extends = env:generic-esp
board = esp32-p4-evboard
build_flags =
${env:generic-esp.build_flags}
-D ARDUINO_USB_MODE=1
board_build.partitions = huge_app.csv
[env:esp32c3]
extends = env:generic-esp
board = esp32-c3-devkitm-1
; Flash mode: Use board default (QIO) for hardware, ci/boards.py sets DIO for QEMU builds
build_flags = ${env:generic-esp.build_flags}
[env:esp32-wroom-32]
extends = env:generic-esp
board = esp32dev
build_flags = ${env:generic-esp.build_flags}
[env:esp32c2]
extends = env:generic-esp
platform = https://github.com/pioarduino/platform-espressif32.git#develop
board = esp32-c2-devkitm-1
custom_sdkconfig = CONFIG_IDF_TARGET="esp32c2"
board_build.partitions = huge_app.csv
build_flags =
${env:generic-esp.build_flags}
[env:esp32dev]
extends = env:generic-esp
platform = platformio/espressif32
board = esp32dev
; Use DIO flash mode instead of QIO for QEMU compatibility
; QEMU's ESP32 emulation doesn't support setting the QIE (Quad I/O Enable) bit,
; causing "Failed to set QIE bit" error and boot assertion failure in startup_funcs.c:95
; DIO (Dual I/O) mode works reliably in both hardware and QEMU emulation
board_build.flash_mode = dio
; esp32dev is FastLED's binary-size reference target — `check_esp32_size`
; tracks the 330 KB ceiling here. We MUST override generic-esp's debug
; build_type (=> -Og, no exception/unwind stripping) and verbose logging
; flags or the test compiles a debug binary and reads ~2x the real release
; footprint.
build_type = release
build_flags =
${env:generic-esp.build_flags}
; -- override generic-esp debug flags for size-check builds --
-UDEBUG
-DNDEBUG
-UFASTLED_DEBUG
-UCORE_DEBUG_LEVEL
-DCORE_DEBUG_LEVEL=0
-ULOG_LOCAL_LEVEL
-DLOG_LOCAL_LEVEL=ESP_LOG_NONE
; -- size-strip flags (mirror Teensy 4 cxx_flags) --
-Os
-fno-exceptions
-fno-rtti
-fno-unwind-tables
-fno-asynchronous-unwind-tables
-ffunction-sections
-fdata-sections
build_unflags =
-Og
-g
[env:teensy40]
platform = teensy
board = teensy40
framework = arduino
build_flags = -D USB_MIDI_SERIAL
[env:teensy41]
platform = teensy
board = teensy41
framework = arduino
build_flags = -D USB_MIDI_SERIAL
[env:sparkfun_xrp_controller]
platform = https://github.com/maxgerhardt/platform-raspberrypi
board = sparkfun_xrp_controller
framework = arduino
build_flags = -fopt-info-all=optimization_report.txt
extra_scripts = pre:ci/ci-flags.py
[env:lpc845brk]
; NXP LPC845-BRK bring-up target — built via the fbuild nxplpc orchestrator
; which consumes zackees/ArduinoCore-LPC8xx. PlatformIO does not have a
; native nxplpc platform; this env is here only so the AutoResearch wrapper
; (`bash autoresearch lpc845brk`) can resolve a known environment name and
; dispatch to the consolidated bring-up sketch at examples/AutoResearch/
; (low-memory mode auto-engages on LPC8xx; see FastLED #3030 / #3041).
;
; Build flags:
; -DRELEASE -- disables FASTLED_FORCE_DBG so the FL_DBG
; call sites stay no-op (~4 KB saved).
; ; -DFASTLED_LPC_PWM_DMA=1 -- activates the hardware-accelerated SCT +
; DMA-to-GPIO clockless driver (FastLED
; #2842 / #2850) in place of the bit-bang
; default. Claims the SCT + 3 DMA channels
; for the FastLED controller lifetime.
; The WS2812 loopback RPC is now derived from the LPC845 platform predicate
; inside AutoResearchLowMemory.h; no user build flag is required.
platform = https://github.com/zackees/platform-nxplpc-arduino.git#2ee527ae80de98e9105329a7260edb003289dfda
board = lpc845brk
framework = arduino
build_flags =
-DRELEASE
-DFASTLED_LPC_PWM_DMA=1
-DFASTLED_AUTORESEARCH_LOW_MEMORY=1
[env:lpc845brk_ieee754]
; Dedicated AutoResearch IEEE754 codec surface for FastLED #3039. This keeps
; the default LPC845-BRK low-memory RPC surface size-neutral while letting
; `bash autoresearch lpc845brk --ieee754` build a firmware that binds only the
; echo and ieee754CodecTest RPCs.
extends = env:lpc845brk
build_flags =
${env:lpc845brk.build_flags}
-DFL_AUTORESEARCH_IEEE754=1
; --------------------------------------------------------------------------
; LPC8xx canary envs (FastLED #2990 — fbuild Stage 6 canary).
;
; Minimal definitions so the per-board CI workflows below can resolve
; each variant name against the fbuild nxplpc orchestrator. These envs
; do NOT carry the AutoResearch-specific build_flags that `lpc845brk`
; does — they exist for the Blink canary path only.
;
; All four use the same nxplpc + ArduinoCore-LPC8xx stack (see lpc845brk
; comment above for the dispatch rationale). Each maps 1:1 to one of the
; `variants/<name>/` entries in zackees/ArduinoCore-LPC8xx, matching the
; five upstream `fbuild build . -e <variant>` jobs that already pass on
; that repo (see #2990 body).
; --------------------------------------------------------------------------
[env:lpc845]
platform = https://github.com/zackees/platform-nxplpc-arduino.git#2ee527ae80de98e9105329a7260edb003289dfda
board = lpc845
framework = arduino
[env:lpc804]
platform = https://github.com/zackees/platform-nxplpc-arduino.git#2ee527ae80de98e9105329a7260edb003289dfda
board = lpc804
framework = arduino
[env:lpcxpresso845max]
platform = https://github.com/zackees/platform-nxplpc-arduino.git#2ee527ae80de98e9105329a7260edb003289dfda
board = lpcxpresso845max
framework = arduino
[env:lpcxpresso804]
platform = https://github.com/zackees/platform-nxplpc-arduino.git#2ee527ae80de98e9105329a7260edb003289dfda
board = lpcxpresso804
framework = arduino
[platformio]
src_dir = examples/Sailboat ; default: examples/AutoResearch/AutoResearch.ino (override with PLATFORMIO_SRC_DIR env var)
default_envs = esp32s3
; ARDUINO_USB_CDC_ON_BOOT lives in per-board build_flags now (ci/boards.py).
; Safe to enable thanks to Serial.setTxTimeoutMs(0); see issue #2668.
; Enable shared build cache to avoid recompiling FastLED library when switching sketches
; This dramatically speeds up `bash debug <example>` workflow by reusing compiled objects
build_cache_dir = .pio/build_cache