forked from MoonModules/MoonLight
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathplatformio.ini
More file actions
216 lines (176 loc) · 11.6 KB
/
platformio.ini
File metadata and controls
216 lines (176 loc) · 11.6 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
; PlatformIO Project Configuration File
;
; Build options: build flags, source filter
; Upload options: custom upload port, speed and extra flags
; Library options: dependencies, extra library storages
; Advanced options: extra scripting
;
; Please visit documentation for the other options and examples
; https://docs.platformio.org/page/projectconf.html
[platformio]
description = MoonLight ; 💫
data_dir = data
extra_configs =
factory_settings.ini
features.ini
firmware/*.ini ; 🌙 inspired by meshtastic, actual board definitions are in /firmware
; default_envs = esp32-s3-devkitc-1, esp32-s3-devkitc-1-n16r8v ; exclude esp32dev as > 100% ATM
; 🌙 See /firmware folder for all the envs!!!
; =======================================
[env]
framework = arduino ;espidf will not work as libs rely on arduino (e.g. PhysicHTTP, ...)
; https://github.com/platformio/platform-espressif32/releases
; platform = espressif32 @ 6.10.0 ;Jan 2025, ESP-IDF v4.4.7-dirty / Arduino v2.0.17
; platform = espressif32 @ 6.11.0 ; June 2025, ESP-IDF v4.4.7-dirty / Arduino v2.0.17 latest v4.4.7-dirty ! framework-arduinoespressif32 @ ~3.20017.0
; v4 -> v5 flash size from 1955 to 2238 KB on S3 ! esp32 > 100%...
; v5 resulting in FastLED hickups on all listed versions:
; platform = https://github.com/pioarduino/platform-espressif32/releases/download/2024.07.00/platform-espressif32.zip ; Jul 15, 2024 espressif Arduino core 3.0.2 / IDF 5.1.4: error: no matching function for call to 'NetworkClientSecure::setCACertBundle(const uint8_t [], int)'
; platform = https://github.com/pioarduino/platform-espressif32/releases/download/53.03.10/platform-espressif32.zip ; Dec 16, 2024 Arduino core 3.1.0 based on IDF 5.3.2.241210
; platform = https://github.com/pioarduino/platform-espressif32/releases/download/53.03.11/platform-espressif32.zip ; Jan 19, 2025 Arduino core 3.1.1 based on IDF 5.3.2.241224
; platform = https://github.com/pioarduino/platform-espressif32/releases/download/54.03.20/platform-espressif32.zip ; March 28, 2025 Latest release! ESP-IDF v5.4.1-1-g2f7dcd862a-dirty / Arduino v3.2.0
; platform = https://github.com/pioarduino/platform-espressif32/releases/download/53.03.13/platform-espressif32.zip ; June 2025 not 54.03? used in latest upstream ESP-IDF v5.3.2-584-g489d7a2b3a-dirty / Arduino v3.1.3
; platform = https://github.com/pioarduino/platform-espressif32/releases/download/54.03.20/platform-espressif32.zip ; latest FastLED see https://github.com/FastLED/FastLED/issues/1903 ESP-IDF v5.4.1-1-g2f7dcd862a-dirty / Arduino v3.2.0
; physical driver crashes on this
; platform = https://github.com/pioarduino/platform-espressif32/releases/download/54.03.21/platform-espressif32.zip ; latest sveltekit
; installed https://github.com/espressif/esp32-arduino-lib-builder/releases/download/idf-release_v5.4/esp32-arduino-libs-idf-release_v5.4-858a988d-v1.zip at 20250814
platform = https://github.com/pioarduino/platform-espressif32/releases/download/55.03.30-2/platform-espressif32.zip ; latest latest
; platform = https://github.com/pioarduino/platform-espressif32/releases/download/stable/platform-espressif32.zip
; https://github.com/espressif/esp32-arduino-lib-builder/releases/download/idf-release_v5.5/esp32-arduino-libs-idf-release_v5.5-b66b5448-v1.zip
; platform = espressif32 @ 6.12.0 ... check https://github.com/platformio/platform-espressif32/releases
;; select arduino-esp32 v2.0.9 (arduino-esp32 2.0.10 thru 2.0.14 are buggy so avoid them)
; platform = https://github.com/tasmota/platform-espressif32/releases/download/2023.06.02/platform-espressif32.zip ;; Tasmota Arduino Core 2.0.9 with IPv6 support, based on IDF 4.4.4
;from 92% to 71% !!! Flash: [======= ] 71.8% (used 1412441 bytes from 1966080 bytes)
; platform = https://github.com/tasmota/platform-espressif32/releases/download/2024.06.00/platform-espressif32.zip
; platform = https://github.com/tasmota/platform-espressif32/releases/download/2025.05.30/platform-espressif32.zip ;; Platform Tasmota Arduino Core 3.1.3.250504based on IDF 5.3.3.250501platform_packages
; platform_packages = framework-arduinoespressif32 @ 3.1.3
build_flags =
${factory_settings.build_flags}
${features.build_flags}
-D BUILD_TARGET=\"$PIOENV\"
-D APP_NAME=\"MoonLight\" ; 🌙 Must only contain characters from [a-zA-Z0-9-_] as this is converted into a filename
-D APP_VERSION=\"0.5.9\" ; semver compatible version string
-D APP_DATE=\"2025091011\" ; 🌙
-D PLATFORM_VERSION=\"pioarduino-55.03.30-2\" ; 🌙 make sure it matches with above plaftform
-D FT_MOONBASE=1
; Move all networking stuff to the protocol core 0 and leave business logic on application core 1
-D ESP32SVELTEKIT_RUNNING_CORE=0
; Uncomment EMBED_WWW to embed the WWW data in the firmware binary
-D EMBED_WWW
; Uncomment to configure Cross-Origin Resource Sharing
-D ENABLE_CORS
-D CORS_ORIGIN=\"*\"
; Uncomment to enable informations from ESP32-Sveltekit in Serial Monitor
; -D SERIAL_INFO // 🌙 this looks redundant as ESP_LOG is also showing almost the same
; D E B U G B U I L D F L A G S
; ===============================
; These build flags are only for debugging purposes and should not be used in production
-D CONFIG_ARDUHAL_LOG_COLORS
; 🌙 Switch to ESP_IDF_LOG as 54.03.20 and newer mess up with arduino logging
-DUSE_ESP_IDF_LOG ; needed because framework = arduino
-DCONFIG_LOG_COLORS
-DLOG_LOCAL_LEVEL=ESP_LOG_DEBUG ; used in main,cpp
; -DTAG="\"♾️\"" ;Arduino IDF Log Tag, can be used to filter log messages in the Serial Monitor : causes FastLED conflicts
; -DESP_LOG_LEVEL=ESP_LOG_VERBOSE ; generates a ton of redefine warnings
; -DESP_LOG_LEVEL_LOCAL=ESP_LOG_VERBOSE ; generates a ton of redefine warnings
; Uncomment to show log messages from the ESP Arduino Core and ESP32-SvelteKit
; -D CORE_DEBUG_LEVEL=4 ; not used by ESP_IDF_LOG
; Serve config files from flash and access at /.config/filename.json
;-D SERVE_CONFIG_FILES
; Uncomment to teleplot all task high watermarks to Serial
; -D TELEPLOT_TASKS
; Uncomment and set right values if FT_BATTERY=1 and battery voltage is on pin
; -D BATTERY_PIN=35 ;🌙 not on env:esp32-s3-devkitc-1-n16r8v
; -D BATTERY_MV=4200 ;🌙
; Uncomment to use JSON instead of MessagePack for event messages. Default is MessagePack.
; -D EVENT_USE_JSON=1 ; 💫 switch off for FT_MONITOR
-D NROF_END_POINTS=160 ; 💫 increase number of endpoints to 160, default is 120
lib_compat_mode = strict
; Uncomment to include the a Root CA SSL Certificate Bundle for all SSL needs
; Needs -D FT_DOWNLOAD_FIRMWARE=1 and -D FT_NTP=1
board_build.embed_files = src/certs/x509_crt_bundle.bin
; Source for SSL Cert Store can bei either downloaded from Mozilla with 'mozilla' ('https://curl.se/ca/cacert.pem')
; or from a curated Adafruit repository with 'adafruit' (https://raw.githubusercontent.com/adafruit/certificates/main/data/roots.pem)
; or complied from a 'folder' full of *.pem / *.dem files stored in the ./ssl_certs folder
board_ssl_cert_source = adafruit
monitor_speed = 115200
monitor_filters =
esp32_exception_decoder
log2file
colorize ; 🌙
board_build.filesystem = littlefs
extra_scripts =
pre:scripts/build_interface.py
pre:scripts/generate_cert_bundle.py ; comment if no internet (or developing), GitHub CI complains about this since
scripts/merge_bin.py
scripts/rename_fw.py
scripts/save_elf.py
lib_deps =
ArduinoJson@>=7.0.0
elims/PsychicMqttClient@^0.2.3
;💫
[moonlight]
build_flags =
-D FT_MOONLIGHT=1
-D FT_MONITOR=1
; ML_CHIPSET: Used by FastLED driver.init
-D ML_CHIPSET=WS2812B ; RGB, for fairy lights or https://www.waveshare.com/wiki/ESP32-S3-Matrix
; -D ML_CHIPSET=APA106 ; for Cube202020 / some fairy curtain strings do not work with WS2812B
; -D ML_CHIPSET=SK6812 ; 🚧
-D ML_COLOR_ORDER=GRB ; define your color order here if needed (why WS2812 has GRB instead of RGB?) Only for FastLED, PD software configurable
; -D ML_RGBW=1 ; define whether to enable RGBW (1 = yes, 0 = no) ... could be derived from ML_CHIPSET???
lib_deps =
https://github.com/FastLED/FastLED.git#3.10.2 ; august 2025
https://github.com/netmindz/WLED-sync#48cb28f11632b217f9ccd9f72149373919c28af5 ; sourceIP
; 💫 currently only enabled on s3 as esp32dev runs over 100%
[livescripts]
build_flags =
-D HTTPD_STACK_SIZE=8192 ; default 4096 but not enough for more complex read and update
-D FT_LIVESCRIPT=1
lib_deps =
; https://github.com/hpwit/ESPLiveScript.git#39e9409 ; 1.3.2 / v4.2 15-02-2025 ; Comment if FT_LIVESCRIPT=0
; https://github.com/hpwit/ESPLiveScript.git#3b1d1b6 ; v4.3 07-03-2025 ; Comment if FT_LIVESCRIPT=0
; https://github.com/hpwit/ESPLiveScript.git#62ba8ac ; vjson 24-05-2025 ; Comment if FT_LIVESCRIPT=0
; https://github.com/hpwit/ESPLiveScript.git#afc1d6a ; vjson 24-05-2025 ; Comment if FT_LIVESCRIPT=0
; https://github.com/hpwit/ESPLiveScript.git#7286d31 ; vjson 24-05-2025 ; Comment if FT_LIVESCRIPT=0
; https://github.com/hpwit/ESPLiveScript.git#4074cb5 ; okay
; https://github.com/hpwit/ESPLiveScript.git#29ced05 ;
; https://github.com/hpwit/ESPLiveScript.git#7b97f74 ; okay
; https://github.com/hpwit/ESPLiveScript.git#7b52eca ; okay
; https://github.com/hpwit/ESPLiveScript.git#cccfc0b ; notokay
; https://github.com/hpwit/ESPLiveScript.git#4a0cb82 ; vjson 09-06-2025 ; Comment if FT_LIVESCRIPT=0
; https://github.com/hpwit/ESPLiveScript.git#6f86b6e ; vjson 09-06-2025 ; Comment if FT_LIVESCRIPT=0
https://github.com/hpwit/ESPLiveScript.git#9f002b4ec450cd47f5d417bfaddd616dd764d1f3 ; vjson 16-06-2025 ; Comment if FT_LIVESCRIPT=0
;For all boards
[ESP32_LEDSDRIVER]
build_flags =
-D ESP32_LEDSDRIVER
lib_deps =
; https://github.com/ewowi/I2SClocklessLedDriver.git#c9b12fc ;#dev 20240704 (latest at 20241023)
; https://github.com/hpwit/I2SClocklessLedDriver.git#5414935 ;#dev 20240704 (latest at 20241023)
https://github.com/ewowi/ESP32-LedsDriver.git
[HP_ALL_DRIVERS]
build_flags =
-D HP_ALL_DRIVERS
-D HP_ALL_VERSION=\"ewowi20250809hpwit20250801\"
lib_deps =
; https://github.com/ewowi/I2SClocklessLedDriver.git#5d5508ca38a15497392950d4249cd0d910c3505d
; https://github.com/ewowi/I2SClocklessLedDriver.git#d8cdb31f8b0d52c0562eb5b0ce4723e26f0dc62f
; https://github.com/hpwit/I2SClocklessLedDriver.git#6bf1400b2fece454bccc53a07bb84258c266b198 ; testint2, 20250804 10:14PM not working yet
; https://github.com/hpwit/I2SClocklessLedDriver.git#a7d3dafd005d059a8fb680927567cdd37914ed01 ; dev 20250804 12:05PM cache region crash
; https://github.com/hpwit/I2SClocklessLedDriver.git#4a6b4392206daaf56424f99627e4367b9d87af13 ; 20250804 3:53PM cache region crash
; https://github.com/hpwit/I2SClocklessLedDriver.git#1616a33295b3009033bf47d30d0c88619997220a ; dev 20250801 4:10PM (before test int), working 54.03.21
https://github.com/ewowi/I2SClocklessLedDriver.git#716ecd218215804cbe14753480ef657ad8e96a74 ; dev 20250809 11:52: correct gamma bug
; https://github.com/hpwit/I2SClocklessLedDriver.git#3dc6cea7b7e5c605f4303ff3c9ba79654bee4d85
; https://github.com/ewowi/I2SClocklessLedDriver.git#9beeedb2d4ef45206b55731e07066e4775434c0f ; testint3, 20250828 2:50
[HP_VIRTUAL_DRIVER]
build_flags =
-D HP_VIRTUAL_DRIVER
-D __NB_DMA_BUFFER=30 ; default 2 (2 causes flickering in case of mapping, 5 also, 10 a bit, 15 a bit, 20 not, on esp32devICLVD). For now stays at 10 as normal esp / 12288 LEDs is more stable
lib_deps =
https://github.com/ewowi/I2SClocklessVirtualLedDriver#ce6bd17 ; 2025-02-26
; to do
[MM_HUB75_DRIVER]
build_flags =
-D MM_HUB75_DRIVER
lib_deps =
; https://github.com/... ;#integration ;ewowi repo adds some proposed PR's and makes sure we don't have unexpected updates