Repository navigation
Expand file tree
/
Copy pathplatformio.ini
More file actions
35 lines (33 loc) · 1.65 KB
/
Copy pathplatformio.ini
File metadata and controls
35 lines (33 loc) · 1.65 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
; Cardputer-Keyboard-Mouse — USB/BLE HID firmware for M5Stack Cardputer Adv
[platformio]
default_envs = cardputer-adv
[env:cardputer-adv]
platform = https://github.com/pioarduino/platform-espressif32/releases/download/55.03.37/platform-espressif32.zip
board = m5stack-stamps3 ; ESP32-S3, 8MB flash, no PSRAM
framework = arduino
monitor_speed = 115200
board_build.partitions = default_8MB.csv
build_unflags =
-DARDUINO_USB_MODE=1 ; board json presets MODE=1; drop it to avoid macro-redefined warnings
build_flags =
-DARDUINO_USB_MODE=0 ; native USB-OTG (TinyUSB) — required for USB HID
-DARDUINO_USB_CDC_ON_BOOT=1 ; CDC console on the same composite device
-DUSB_PRODUCT='"Cardputer-Keyboard-Mouse"' ; runtime USB.productName() is too late (D12)
-DCORE_DEBUG_LEVEL=2
; NimBLE-Arduino 2.x tuning (MYNEWT_VAL_* names; the 1.x CONFIG_BT_NIMBLE_* names are silently ignored)
-DMYNEWT_VAL_BLE_STORE_MAX_BONDS=6
-DMYNEWT_VAL_BLE_STORE_MAX_CCCDS=18 ; 3 slots x (kbd+mouse+battery CCCD) = 9 minimum; default 8 loses bonds
; Role trimming: NimBLE-Arduino 2.5 derives MYNEWT_VAL_BLE_ROLE_* from the
; CONFIG_BT_NIMBLE_ROLE_*_DISABLED switches (setting MYNEWT_VAL_BLE_ROLE_*
; directly is redefined by esp_nimble_cfg.h and has no effect).
-DCONFIG_BT_NIMBLE_ROLE_CENTRAL_DISABLED
-DCONFIG_BT_NIMBLE_ROLE_OBSERVER_DISABLED
lib_deps =
m5stack/M5Cardputer @ ^1.1.1 ;
h2zero/NimBLE-Arduino @ ^2.5.0
[env:native]
platform = native
test_framework = unity
build_flags = -std=c++17 -DNATIVE_TEST
build_src_filter = +<core/> ; core logic only — no Arduino headers allowed there
test_build_src = yes