-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathplatformio.ini
More file actions
89 lines (84 loc) · 2.67 KB
/
platformio.ini
File metadata and controls
89 lines (84 loc) · 2.67 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
; 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]
default_envs = esp32dev, espa-v1, espa-v2
; data_dir = {$PROJECT_DIR}/data
[env:spa-base]
platform = espressif32
framework = arduino
monitor_speed = 115200
lib_ldf_mode = deep
board_build.filesystem = spiffs
lib_deps =
https://github.com/ktos/RemoteDebug.git@^3.0.7
tzapu/WiFiManager@^2.0.17
knolleary/PubSubClient@^2.8
bblanchon/ArduinoJson@^7.4.2
;links2004/WebSockets@^2.7.1
paulstoffregen/Time@^1.6.1
https://github.com/me-no-dev/ESPAsyncWebServer.git
extra_scripts =
pre:get_version.py
post:merge-bin.py
[env:esp32dev]
extends = env:spa-base
board = esp32-s3-devkitc-1
build_flags =
-D RX_PIN=16
-D TX_PIN=17
-D EN_PIN=0
-D LED_PIN=2
-D SPA_SERIAL=Serial2
[env:espa-v1]
extends = env:spa-base
board = esp32-s3-devkitc-1
build_flags =
-D ARDUINO_USB_CDC_ON_BOOT=1
-D ESPA_V1=1
-D RX_PIN=16
-D TX_PIN=15
-D EN_PIN=0
-D SPA_SERIAL=Serial2
[env:espa-v2]
extends = env:spa-base
# ESP32-C6 DevKitC-1 board (ESPA_V2 hardware)
#
# Key differences from ESPA_V1 (ESP32-S3):
# - Uses Hardware CDC (HWCDC) for USB serial instead of native USB CDC
# - Only has UART0 and UART1 (no UART2), so spa serial uses Serial1
# - Single WS2812 RGB NeoPixel LED on GPIO10 instead of 4 separate LEDs
# - General purpose button on GPIO21 (GP_PIN) for future functionality
#
# USB Serial Configuration:
# - ARDUINO_USB_CDC_ON_BOOT=1: Routes Serial to USB CDC
# - ARDUINO_USB_MODE=1: Selects Hardware CDC (HWCDCSerial) over native USB
#
# Deferred Initialization:
# Global objects (SpaInterface, MultiBlinker) must defer hardware init to
# setup() because ESP32-C6 constructors run before Arduino framework is ready.
#
platform = https://github.com/pioarduino/platform-espressif32/releases/download/stable/platform-espressif32.zip
framework = arduino
board = esp32-c6-devkitc-1
board_build.flash_size = 8MB
board_build.partitions = partitions/espa_v2_partitions.csv
lib_deps =
${env:spa-base.lib_deps}
adafruit/Adafruit NeoPixel@^1.12.0
build_flags =
-D ARDUINO_USB_CDC_ON_BOOT=1
-D ARDUINO_USB_MODE=1
-D ESPA_V2=1
-D RGB_LED_PIN=10 ; WS2812 NeoPixel on GPIO10
-D RX_PIN=19 ; Spa serial RX
-D TX_PIN=20 ; Spa serial TX
-D EN_PIN=9 ; Enable/config button
-D GP_PIN=21 ; General purpose button (reserved)
-D SPA_SERIAL=Serial1 ; ESP32-C6 only has UART0/UART1, no UART2