[Bug] Bluetooth may remain disabled after running short program #1667
Labels
bug
Something isn't working
hub: primehub/inventorhub
Issues related to the LEGO SPIKE Prime hub and LEGO MINDSTORMS Robot Invetor hub
topic: bluetooth
Issues involving bluetooth
Describe the bug
While working on pybricks/pybricks-micropython#247 (comment) I noticed that sometimes Bluetooth would not come back on on Prime Hub.
It turns out this was already the case in the stable firmware such as
3.5.0
.This isn't entirely an edge case, either. Sometimes an offline program will fail due to an immediate exception such as a motor not being plugged in. When connecting to fix the issue, sometimes the hub won't appear in Pybricks Code.
To reproduce
Keep an eye on the Chrome scan window, or keep NRF connect open and occasionally refresh.
The hub will appear in a connectable state (blinking), but not advertise.
Expected behavior
Work normally.
Screenshots
There is a saying that a picture is worth a 1000 words. Screenshots really help to identify and solve problems.
Additional context
Since it's so rare, it's been hard to identify for sure, but I think this is where it gets stuck in
pbsys/bluetooth
:Now that we know this easier reproduction scenario, maybe we can find out for sure.
The text was updated successfully, but these errors were encountered: