| Category | Source | Purpose |
|---|---|---|
| Connection events | manager.on() | Camera discovery and connection state |
| Property & action events | EventStream | Camera settings changes, warnings, transfers |
Connection Events
Emitted by CameraManager (both server and browser variants). Use these to monitor camera discovery, connection state, and errors.Events table
| Event | Payload | When |
|---|---|---|
camera-found | { camera } | New camera detected by polling |
camera-lost | { camera } | Camera no longer detected (unplugged/offline) |
camera-connecting | { cameraId } | Connection attempt started |
camera-ready | { cameraId, camera } | Connected and ready for commands |
camera-disconnected | { cameraId, error? } | Disconnected (explicit or unexpected) |
connection-failed | { cameraId, error, attempt } | Connection attempt failed |
error | { message } | Manager-level error (poll failure, SSE error) |
Subscribing
Unsubscribing
Property & Action Events
Real-time notifications from the camera via SSE. UseEventStream to subscribe to property changes, warnings, autofocus status, file transfers, and errors.
Events table
| Event | Payload | When |
|---|---|---|
connected | { cameraId } | Camera connection established (SSE callback from server) |
disconnected | { error } | Camera disconnected (SSE callback from server) |
propertyChanged | { codes } | Camera settings changed (ISO, aperture, etc.) |
warning | { code } | Camera warning (code 0x20011 = photo captured) |
afStatus | { state } | Autofocus state changed ('focused' | 'unlocked' | 'tracking') |
downloadComplete | { filename } | File saved to host PC |
transferProgress | { percent, filename } | File transfer progress |
error | { code } | SSE connection error |

