Mako: clear stale errors on connect; one loop thread at a time
- Errors from while the camera was unreachable were never cleared, so
make_response returned HTTP 500 for every later request: the loop
switch turned itself off even though the loop had started. Clear
self.error once the connection succeeds.
- stop_looping() now joins the loop thread instead of waiting for
state 0, and _run_loop() exits when a newer loop thread replaced it:
a quick off/on no longer leaves two threads acquiring together
(VmbError.NotFound every second).
Co-Authored-By:
Claude Opus 5.5 <noreply@anthropic.com>