earlephilhower / arduino-pico

Raspberry Pi Pico Arduino core, for all RP2040 boards
GNU Lesser General Public License v2.1
1.88k stars 394 forks source link

Avoid deadlock BT/LE HID send when disconnected #2252

Closed earlephilhower closed 1 week ago

earlephilhower commented 1 week ago

Fixes #2251

The 2-phase send could get out of whack if transmission was attempted when no device was connected. Clear things up so if things aren't connected, then no data gets set as pending.