Closed matthudsonau closed 6 months ago
@matthudsonau OK, I've refactored the context blahs to completely remove the global variables. I'll be using this in a future refactor to try and make the UI code less messy.
In testing I found the reconnection to work well, good job!
However, if the reconnection fails, bad things happen. Specifically, if I switch off the camera (and leave it off) whilst connected, the reconnecting progress bar is either:
permanently stalled OR screen blanks It looks like it exits either remote_control() or remote_interval() and ends up stuck in menu_remote() in the runOnce()) call and doesn't redraw the screen.
Are you able to look into it?
Yeah, I'll have a run at it tonight. Although the easiest way to fix it is probably just resetting the program if the connection doesn't restore
Yeah, I'll have a run at it tonight. Although the easiest way to fix it is probably just resetting the program if the connection doesn't restore
This absolutely the right answer and have implemented it, thanks!
LGTM, merged!
Monitors the Bluetooth connection status for the device and attempts an automatic reconnect whenever the connection drops
Some changes requires to M5ez to add functionality to get the current buttons
Device class is also updated to support querying connection status