41 lines
1.4 KiB
INI
41 lines
1.4 KiB
INI
; TranspOtter (BLE gamepad build) — ESP32-C3 Supermini driving a hoverboard
|
|
; mainboard running hoverboard-firmware-hack-FOC, controlled by a Bluetooth LE
|
|
; gamepad paired through a USB serial terminal.
|
|
;
|
|
; The C3 has no Bluetooth Classic, so only BLE HID controllers work here.
|
|
;
|
|
; pio run build
|
|
; pio run -t upload flash over USB-C
|
|
; pio device monitor open the console (115200)
|
|
|
|
[env:supermini-ble]
|
|
platform = espressif32
|
|
board = esp32-c3-devkitm-1
|
|
framework = arduino
|
|
|
|
monitor_speed = 115200
|
|
monitor_filters = send_on_enter, colorize
|
|
; The C3's native USB-Serial-JTAG is not a real UART, so a baud change is both
|
|
; pointless and harmful — esptool's stub loses the link mid-handshake. 115200 is
|
|
; esptool's default, so it skips the renegotiation entirely.
|
|
upload_speed = 115200
|
|
|
|
; Reset over USB rather than toggling DTR/RTS like a UART bridge. Without this,
|
|
; a half-finished upload leaves the chip desynced and every later attempt hangs
|
|
; in esptool's `Connecting....` until it is physically unplugged.
|
|
board_upload.before_reset = usb_reset
|
|
|
|
; Splices --no-stub into the esptool invocation; see the script for why.
|
|
extra_scripts = post:scripts/no_stub.py
|
|
|
|
lib_deps =
|
|
h2zero/NimBLE-Arduino
|
|
|
|
build_flags =
|
|
; The Supermini's USB-C is the C3's native USB, so the console is USB CDC
|
|
; and UART1 stays free for the hoverboard link.
|
|
-DARDUINO_USB_MODE=1
|
|
-DARDUINO_USB_CDC_ON_BOOT=1
|
|
-Wall
|
|
-Wextra
|