Skip to content

Focus timer bug version 2

John Evans requested to merge johnevans/kstars:FocusTimerBug2 into master

This is a follow up to the recent fix for focus motion timeouts and provides a more complete treatment.

If set correctly, say 30 secs, this should only occur when there are comms issues with the focuser.

To try to avoid conflicts where someone may have inadvertently set the focuser motion timeout too low (e.g. 1 second) which then conflicts with the focuser polling period (say 1 second) the focus GUI now has a minimum of 5 seconds for the focuser motion timeout (which is consistent with the capture timeout.

When a focus motion timeout occurs: Step 1: Just retry the last requested move. If the issue is a transient one-off issue this should resolve it. Step 2: Step 1 didn't resolve the issue so try to restart the focus driver. In this case abort the inflight autofocus run and let it retry from the start. It will try to return the focuser to the start (last successful autofocus) position. Step 3: Step 2 didn't work either because the driver restart wasn't successful or we are still getting timeouts. In this case just stop the autoFocus process and return control to either the Scheduer or GUI. Note that here we cannot reset the focuser to the previous good position so if the focuser miraculously fixes itself the next autofocus run won't start from the best place.

I have tested this on the sim and ASI EAF.

Edited by John Evans

Merge request reports