Skip to content

Commit b5aa1b2

Browse files
authored
Fix autotracking calibration crash when zooming is disabled (#19776)
1 parent f62feeb commit b5aa1b2

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

frigate/ptz/autotrack.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -369,12 +369,13 @@ async def _calibrate_camera(self, camera):
369369
logger.info(f"Camera calibration for {camera} in progress")
370370

371371
# zoom levels test
372+
self.zoom_time[camera] = 0
373+
372374
if (
373375
self.config.cameras[camera].onvif.autotracking.zooming
374376
!= ZoomingModeEnum.disabled
375377
):
376378
logger.info(f"Calibration for {camera} in progress: 0% complete")
377-
self.zoom_time[camera] = 0
378379

379380
for i in range(2):
380381
# absolute move to 0 - fully zoomed out

0 commit comments

Comments
 (0)