Blink the Pico onboard LED at 1 Hz when the connected DualSense
reports PowerPercent <= 1 (i.e. <= 10%) and PowerState == Discharging.
Source data is byte 52 of the BT 0x31 input report, already copied
into interrupt_in_data; no new BT parsing required.
The new module owns the LED only while it is actively blinking; it
detects controller disconnection via stale-report timeout and steps
out, so bt.cpp's existing connect/disconnect LED handling stays in
charge in all other states. Honors disable_pico_led.
Gated by -DENABLE_BATT_LED=ON (default). With the option off, the
source file is not compiled and behavior is identical to upstream.
CI gains a compile-only check for the OFF flavor.
(cherry picked from commit 2f8ea73c9fb695e24e7cc3329db7cb925e82e1c9)
- Increased HID polling rate from 250Hz (4ms) to 1000Hz (1ms) in
the configuration descriptor to match wired DualSense performance.
- Fixed a potential race condition between Bluetooth data callbacks
and the USB task using pico/critical_section.
- Implemented a 'dirty flag' mechanism to prevent sending redundant
duplicate reports, ensuring the dongle only transmits to the host
when fresh Bluetooth data is received.
- Added a fallback retry logic in interrupt_loop to ensure data
integrity if a USB report fails to queue.