forked from uxjulia/CrossInk
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathplatformio.ini
More file actions
266 lines (247 loc) · 8.38 KB
/
Copy pathplatformio.ini
File metadata and controls
266 lines (247 loc) · 8.38 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
257
258
259
260
261
262
263
264
265
266
[platformio]
default_envs = default, sticky
extra_configs = platformio.local.ini
[crossink]
version = 1.5.0
[base]
platform = https://github.com/pioarduino/platform-espressif32/releases/download/55.03.37/platform-espressif32.zip
board = esp32-c3-devkitm-1
framework = arduino
monitor_speed = 115200
upload_speed = 921600
check_tool = cppcheck
check_flags = --enable=all --suppress=missingInclude --suppress=missingIncludeSystem --suppress=unusedFunction --suppress=unmatchedSuppression --suppress=*:*/.pio/* --inline-suppr
check_skip_packages = yes
board_upload.flash_size = 16MB
board_upload.maximum_size = 6553600
board_upload.offset_address = 0x10000
; Rebuild the Arduino/ESP-IDF SDK with lower runtime RAM reservations. Timer
; stacks are still substantially above their measured high-water marks, while
; disabling WiFi IRAM placement trades some throughput for more usable heap.
custom_sdkconfig =
CONFIG_ESP_TIMER_TASK_STACK_SIZE=4096
CONFIG_FREERTOS_TIMER_TASK_STACK_DEPTH=2560
CONFIG_ESP_WIFI_IRAM_OPT=n
CONFIG_ESP_WIFI_RX_IRAM_OPT=n
CONFIG_ARDUINO_SELECTIVE_COMPILATION=y
CONFIG_ARDUINO_SELECTIVE_RainMaker=n
CONFIG_ARDUINO_SELECTIVE_Insights=n
CONFIG_ARDUINO_SELECTIVE_ESP_SR=n
; These managed ESP-IDF components support Arduino cloud, diagnostics, and
; radio-co-processor features that CrossInk does not use.
custom_component_remove =
espressif/esp_insights
espressif/esp_rainmaker
espressif/esp_diagnostics
espressif/esp_diag_data_store
espressif/esp_schedule
espressif/esp_rcp_update
espressif/esp_secure_cert_mgr
espressif/cbor
build_flags =
-Iinclude
-DARDUINO_USB_MODE=1
-DARDUINO_USB_CDC_ON_BOOT=1
-DEINK_DISPLAY_SINGLE_BUFFER_MODE=1
-DDISABLE_FS_H_WARNING=1
-DDESTRUCTOR_CLOSES_FILE=1
# https://libexpat.github.io/doc/api/latest/#XML_GE
-DXML_GE=0
-DXML_CONTEXT_BYTES=1024
-std=gnu++2a
# Enable UTF-8 long file names in SdFat
-DUSE_UTF8_LONG_NAMES=1
# Increase PNG scanline buffer to support up to 2048px wide images
# Default is (320*4+1)*2=2562, we need more for larger images
-DPNG_MAX_BUFFERED_PIXELS=16416
-DFREEINK_NET_WOLFSSL=1
-DWOLFSSL_USER_SETTINGS
-DWOLFSSL_OPTIONS_H
-DWOLFSSL_CLIENT_EXAMPLE
-DWOLFSSL_TLS13
-DWOLFSSL_HAVE_SP_ECC
-DWOLFSSL_SP_SMALL
# Arduino-wolfSSL's user_settings.h enables TLS extensions, supported curves,
# HKDF, and RSA-PSS when WOLFSSL_TLS13 is set. Do not repeat those defines here:
# GCC reports every library translation unit as a macro redefinition.
-DHAVE_FFDHE_2048
-DHAVE_CURVE25519
-DHAVE_SNI
-Wno-bidi-chars
-Wl,--wrap=panic_print_backtrace,--wrap=panic_abort,--wrap=bootloader_common_check_efuse_blk_validity
-fno-exceptions
build_unflags =
-std=gnu++11
-fexceptions
; Board configuration
board_build.flash_mode = dio
board_build.flash_size = 16MB
board_build.partitions = partitions.csv
extra_scripts =
pre:scripts/patch_wolfssl.py
pre:scripts/build_web.py
pre:scripts/gen_i18n.py
pre:scripts/git_branch.py
pre:scripts/patch_jpegdec.py
pre:scripts/patch_websockets.py
post:scripts/check_firmware_size.py
post:scripts/check_app_touch_gate.py
post:scripts/rename_firmware.py
; Libraries
lib_deps =
BatteryMonitor=symlink://freeink-sdk/libs/hardware/BatteryMonitor
InputManager=symlink://freeink-sdk/libs/hardware/InputManager
EInkDisplay=symlink://freeink-sdk/libs/display/FreeInkDisplay
SDCardManager=symlink://freeink-sdk/libs/hardware/SDCardManager
BoardConfig=symlink://freeink-sdk/libs/hardware/BoardConfig
XteinkDetect=symlink://freeink-sdk/libs/hardware/XteinkDetect
PowerManager=symlink://freeink-sdk/libs/hardware/PowerManager
Rtc=symlink://freeink-sdk/libs/hardware/Rtc
Imu=symlink://freeink-sdk/libs/hardware/Imu
FrontlightManager=symlink://freeink-sdk/libs/hardware/FrontlightManager
XteinkDetect=symlink://freeink-sdk/libs/hardware/XteinkDetect
SecureNet=symlink://freeink-sdk/libs/network/SecureNet
NearbyTransfer=symlink://freeink-sdk/libs/network/NearbyTransfer
FreeInkUI=symlink://freeink-sdk/libs/ui/FreeInkUI
Icons=symlink://freeink-sdk/libs/assets/Icons
bblanchon/ArduinoJson @ 7.4.2
ricmoo/QRCode @ 0.0.1
bitbank2/PNGdec @ 1.1.6
https://github.com/bitbank2/JPEGDEC.git#86282979224c8a32fd51e091ed5a35b0c699a52b
links2004/WebSockets @ 2.7.3
wolfssl/Arduino-wolfSSL @ 5.7.2
lib_ignore =
BLE
HalClockSim
[env:default]
extends = base
custom_firmware_device_type = x3-x4
build_flags =
${base.build_flags}
-DFREEINK_DEVICE_X4=1
-DFREEINK_DEVICE_X3=1
-DCROSSINK_APP_CAP_TOUCH=0
; CROSSINK_VERSION is set by scripts/git_branch.py (includes current branch)
-DCROSSINK_FIRMWARE_DEVICE_TYPE=\"x3-x4\"
-DENABLE_SERIAL_LOG
-DLOG_LEVEL=1 ; Set log level to debug for development builds
[env:debug]
extends = base
custom_firmware_device_type = x3-x4
build_flags =
${base.build_flags}
-DFREEINK_DEVICE_X4=1
-DFREEINK_DEVICE_X3=1
-DCROSSINK_APP_CAP_TOUCH=0
; CROSSINK_VERSION injected by scripts/git_branch.py
; (uses $CROSSINK_RC_HASH env var in CI, or git short hash locally)
-DCROSSINK_FIRMWARE_DEVICE_TYPE=\"x3-x4\"
-DCROSSINK_BUILD_ENV=\"debug\"
-DCROSSINK_ENABLE_READING_STATS_TOGGLE
-DCROSSINK_SHOW_SLEEP_BUILD_INFO
-DENABLE_SERIAL_LOG
-DLOG_LEVEL=2 ; Set log level to debug for development builds
[simulator-base]
platform = native
custom_run_simulator_target_owner = project
lib_compat_mode = off
build_src_filter =
+<*>
-<network/FirmwareFlasher.cpp>
-<network/OtaBootSwitch.cpp>
-<network/OtaUpdater.cpp>
-<platform/skip_efuse_blk_check.c>
build_flags =
-std=gnu++2a
!sdl2-config --cflags --libs
-DSIMULATOR
-DCROSSPOINT_SIMULATOR_PROJECT_WEBSERVER
-Wno-c++11-narrowing
-DCROSSINK_VERSION=\"${crossink.version}\"
-DENABLE_SERIAL_LOG
-DLOG_LEVEL=2
-DEINK_DISPLAY_SINGLE_BUFFER_MODE=1
-DMINIZ_NO_ZLIB_COMPATIBLE_NAMES=1
-DXML_GE=0
-DXML_CONTEXT_BYTES=1024
-DUSE_UTF8_LONG_NAMES=1
-DPNG_MAX_BUFFERED_PIXELS=16416
-DDISABLE_FS_H_WARNING=1
-DDESTRUCTOR_CLOSES_FILE=1
;-DSIMULATOR_DEVICE_X3 ; uncomment to simulate X3 screen size
-Iinclude
-Isrc
;-DOMIT_EMOJI_FONTS ; uncomment to omit emoji/symbols glyphs from reading fonts
-DCROSSPOINT_SIM_USE_NATIVE_DECODERS
-Dmemcpy_P=memcpy ; For native JPEGDEC
lib_ignore = hal, WebSockets
extra_scripts =
pre:scripts/gen_i18n.py
pre:scripts/git_branch.py
pre:scripts/build_web.py
post:.pio/libdeps/$PIOENV/simulator/run_simulator_project.py
lib_deps =
simulator=https://github.com/uxjulia/crossink-simulator
FreeInkUI=symlink://freeink-sdk/libs/ui/FreeInkUI
Icons=symlink://freeink-sdk/libs/assets/Icons
NearbyTransfer=symlink://freeink-sdk/libs/network/NearbyTransfer
bblanchon/ArduinoJson @ 7.4.2
ricmoo/QRCode @ ^0.0.1
bitbank2/PNGdec @ 1.1.6
https://github.com/bitbank2/JPEGDEC.git#86282979224c8a32fd51e091ed5a35b0c699a52b
links2004/WebSockets @ 2.7.3
[env:simulator]
extends = simulator-base
build_flags =
${simulator-base.build_flags}
-DCROSSINK_APP_CAP_TOUCH=0
-DCROSSINK_FIRMWARE_DEVICE_TYPE=\"x3-x4\"
[env:simulator-X3]
extends = simulator-base
build_flags =
${simulator-base.build_flags}
-DCROSSINK_APP_CAP_TOUCH=0
-DCROSSINK_FIRMWARE_DEVICE_TYPE=\"x3-x4\"
-DSIMULATOR_DEVICE_X3
[env:sticky-simulator]
extends = simulator-base
build_flags =
${simulator-base.build_flags}
-DSIMULATOR_DEVICE_STICKY
-DFREEINK_DEVICE_STICKY=1
-DCROSSINK_APP_CAP_TOUCH=1
-DCROSSINK_FIRMWARE_DEVICE_TYPE=\"sticky\"
; pio run -e sticky-simulator -t run_simulator
; --- Seeed Sticky - ESP32-S3R8, 3.97" 800x480 SSD1677 + GT911 touch -----------
; Different MCU family than the C3 envs (one binary per family). The SDK
; auto-enables CAP_TOUCH (GT911) and the BQ27220 gauge for this device. The
; framebuffer is placed in PSRAM to leave more internal DRAM for EPUB rendering.
; pio run -e sticky -t upload
[env:sticky]
extends = base
custom_firmware_device_type = sticky
board = esp32-s3-devkitc1-n16r8
board_build.mcu = esp32s3
build_flags =
${base.build_flags}
-DFREEINK_DEVICE_STICKY=1
-DCROSSINK_APP_CAP_TOUCH=1
-DFREEINK_FB_PSRAM=1
-DCROSSINK_VERSION=\"${crossink.version}-sticky\"
-DCROSSINK_FIRMWARE_DEVICE_TYPE=\"sticky\"
-DENABLE_SERIAL_LOG
-DLOG_LEVEL=1
[env:sticky-debug]
extends = base
custom_firmware_device_type = sticky
board = esp32-s3-devkitc1-n16r8
board_build.mcu = esp32s3
build_flags =
${base.build_flags}
-DFREEINK_DEVICE_STICKY=1
-DCROSSINK_APP_CAP_TOUCH=1
-DFREEINK_FB_PSRAM=1
; CROSSINK_VERSION injected by scripts/git_branch.py
-DCROSSINK_FIRMWARE_DEVICE_TYPE=\"sticky\"
-DENABLE_SERIAL_LOG
-DLOG_LEVEL=2