-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathplatformio.ini
More file actions
110 lines (101 loc) · 5.59 KB
/
Copy pathplatformio.ini
File metadata and controls
110 lines (101 loc) · 5.59 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
; 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 = Prod_Load
; Common - https://docs.platformio.org/en/latest/projectconf/sections/env/index.html#common-env
[env]
; See also: https://esp32s3.com/getting-started.html
platform = https://github.com/pioarduino/platform-espressif32/releases/download/stable/platform-espressif32.zip
framework = arduino
monitor_speed = 115200
monitor_filters = log2file, esp32_exception_decoder
; RECOMMENDED - Accept new functionality in a backwards compatible manner and patches
lib_deps =
adafruit/Adafruit BusIO @ ^1.17.4
adafruit/Adafruit INA260 Library @ ^1.5.3
adafruit/Adafruit NeoPixel @ ^1.15.2
ayushsharma82/ElegantOTA @ ^3.1.7
etlcpp/Embedded Template Library @ ^20.44.1
lennarthennigs/ESP Telnet @ ^2.2.3
; https://docs.platformio.org/en/latest/projectconf/sections/env/options/build/build_flags.html
; https://techoverflow.net/2021/12/14/how-to-print-all-preprocessor-flags-in-platformio/
; See also: https://interrupt.memfault.com/blog/best-and-worst-gcc-clang-compiler-flags
; Note: Not using -Wpedantic, -Wundef, -Wconversion, -Wsign-conversion, & -Wpadded as it causes to warnings in libraries. -Wshadow is also a bit too much. -Wstack-usage=<stack_limit> not used because it varies.
; build_flags =
; -O3 -ffunction-sections -fdata-sections -Wl,--gc-sections
; -std=gnu++23
; -Wall -Wextra -Wdouble-promotion -Wformat=2 -Wformat-overflow=2 -Wformat-truncation=2 -fno-common -fstack-usage -Woverloaded-virtual
; -E -dM -DCORE_DEBUG_LEVEL=ARDUHAL_LOG_LEVEL_DEBUG -D ELEGANTOTA_USE_ASYNC_WEBSERVER=1 -D CONFIG_ASYNC_TCP_STACK_SIZE=4096
; build_flags = -O3 -ffunction-sections -fdata-sections -Wl,--gc-sections -std=gnu++23 -latomic -D ELEGANTOTA_USE_ASYNC_WEBSERVER=1 -D CONFIG_ASYNC_TCP_STACK_SIZE=4096
build_flags =
-O3 -ffunction-sections -fdata-sections -Wl,--gc-sections
-std=gnu++23
-Wall -Wextra -Wdouble-promotion -Wformat=2 -Wformat-overflow=2 -Wformat-truncation=2 -fno-common -fstack-usage -Woverloaded-virtual
-DCORE_DEBUG_LEVEL=ARDUHAL_LOG_LEVEL_DEBUG -D ELEGANTOTA_USE_ASYNC_WEBSERVER=1 -D CONFIG_ASYNC_TCP_STACK_SIZE=4096
build_unflags =
-Os
-std=gnu++11 -std=gnu++14 -std=gnu++17 -std=gnu++20 -std=gnu++2b -std=gnu++2a
; https://docs.platformio.org/en/latest/advanced/static-code-analysis/index.html
; MISRA Rules: https://github.com/speeduino/speeduino/tree/master/misra
; PVS-Studio License Comments: https://pvs-studio.com/en/blog/posts/0614/
check_tool = clangtidy, cppcheck
; check_tool = clangtidy, cppcheck, pvs-studio
check_flags =
clangtidy: --checks=*
cppcheck: --enable=all --std=c++23 --inline-suppr --platform=unspecified --addon=misra.json --addon=cert.py
; pvs-studio: --analysis-mode=0 --platform=RV32 --lic-file = ./PVSStudio_Lic.txt
; debug_tool = esp-builtin ; cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa` or `custom`
; debug_init_break = tbreak setup
; Board Specific Environments
[env:Prod_Load]
; https://esp32s3.com/getting-started.html
board = um_pros3
; See: https://community.platformio.org/t/how-to-use-jtag-built-in-debugger-of-the-esp32-s3-in-platformio/36042
; See also: https://zadig.akeo.ie/#
debug_tool = esp-builtin
debug_init_break = break setup
build_type = debug
; Extra options already in boards file
build_flags =
-O3 -ffunction-sections -fdata-sections -Wl,--gc-sections
-std=gnu++23
-Wall
-DCORE_DEBUG_LEVEL=ARDUHAL_LOG_LEVEL_DEBUG
-I"${platformio.packages_dir}/framework-arduinoespressif32-libs/esp32s3/include/esp_driver_tsens/include/driver"
; -D ARDUINO_USB_MODE=1 ; CDC/JTAG USB mode
; -D ARDUINO_USB_CDC_ON_BOOT=1 ; Needed for USB to enumerate when user code starts
-D ELEGANTOTA_USE_ASYNC_WEBSERVER=1
; -D CONFIG_ASYNC_TCP_MAX_ACK_TIME=5000 ; (keep default)
; -D CONFIG_ASYNC_TCP_PRIORITY=10 ; (keep default)
; -D CONFIG_ASYNC_TCP_QUEUE_SIZE=64 ; (keep default)
-D CONFIG_ASYNC_TCP_RUNNING_CORE=1 ; force async_tcp task to be on same core as the app (default is core 0)
-D CONFIG_ASYNC_TCP_STACK_SIZE=4096 ; reduce the stack size (default is 16K)
; [env:Test_2024-25Prod]
; board = wt32-eth01
; upload_speed = 921600
; [env:Test_CPWP-1]
; board = esp32dev
; [env:Test_BSI-1]
; board = esp32-c3-devkitm-1
; Extra options already in boards file
; build_flags =
; -O3 -ffunction-sections -fdata-sections -Wl,--gc-sections
; -std=gnu++23
; -Wall -Wextra -Wdouble-promotion -Wformat=2 -Wformat-overflow=2 -Wformat-truncation=2 -fno-common -fstack-usage -Woverloaded-virtual
; -DCORE_DEBUG_LEVEL=ARDUHAL_LOG_LEVEL_DEBUG
; -I"${platformio.packages_dir}/framework-arduinoespressif32-libs/esp32/include/esp_driver_tsens/include/driver"
; ; -D ARDUINO_USB_MODE=1 ; CDC/JTAG USB mode
; ; -D ARDUINO_USB_CDC_ON_BOOT=1 ; Needed for USB to enumerate when user code starts
; -D ELEGANTOTA_USE_ASYNC_WEBSERVER=1
; ; -D CONFIG_ASYNC_TCP_MAX_ACK_TIME=5000 ; (keep default)
; ; -D CONFIG_ASYNC_TCP_PRIORITY=10 ; (keep default)
; ; -D CONFIG_ASYNC_TCP_QUEUE_SIZE=64 ; (keep default)
; -D CONFIG_ASYNC_TCP_RUNNING_CORE=1 ; force async_tcp task to be on same core as the app (default is core 0)
; -D CONFIG_ASYNC_TCP_STACK_SIZE=4096 ; reduce the stack size (default is 16K)