Closed Willie-Corto closed 7 months ago
This is due to a newly introduced bug in the adafruit_hid
library. It mistakenly waits for USB to ready to make sure the HID device is ready to send to, even if the device is a BLE, not a USB device. I'll fix the library.
There is a fix in #122, not yet reviewed and released.
This is now released in https://github.com/adafruit/Adafruit_CircuitPython_HID/releases/tag/6.0.2 and will be updated in the bundle tonight.
CircuitPython version
Code/REPL
Behavior
When the ItsyBitsy NRF52840 Express is connected via USB to a PC, BLE keyboard functionality works as expected, allowing the device to send keystrokes to connected devices. However, when powered by a TP4056 module, a 3.7V lipo battery pack, or a USB charger (without data connection), the board will advertise BLE services and can be successfully paired, but it will not send keystrokes.
Description
Encountering an issue with the ItsyBitsy NRF52840 Express where BLE keyboard commands are not transmitted unless the device is connected to a PC via USB. Despite successful BLE service advertisement and pairing with external devices when powered through alternative means (such as a TP4056 module, a 3.7V lipo battery, or a USB charger without data), keystrokes are not sent. This problem persists across different boards and CircuitPython versions.
Additional information
The problem was replicated on other boards: Seeed Studio XIAO nRF52840 Sense and Feather nRF52840 Express. Bootloaders 0.7.0 and 0.8.0 were tested on all devices. The issue was confirmed by another Adafruit forum user, who replicated it on their ItsyBitsy NRF52840. https://forums.adafruit.com/viewtopic.php?t=205776 Original project: https://learn.adafruit.com/ble-hid-keyboard-buttons-with-circuitpython/ble-keyboard-buttons-libraries-and-code