Ken replied to the topic 'Linear 1 Pass gives wrong solution' in the forum. 1 year ago

I'm on a roll tonight!

Something else comes to mind in this sequence.

[2022-11-02T20:46:48.516 Atlantic Daylight Time DEBG ][ org.kde.kstars.indi] - MyFocuserPro2 : "[DEBUG] CMD <:00#> "
[2022-11-02T20:46:48.557 Atlantic Daylight Time DEBG ][ org.kde.kstars.indi] - MyFocuserPro2 : "[DEBUG] RES <P10184#> "
[2022-11-02T20:46:48.558 Atlantic Daylight Time DEBG ][ org.kde.kstars.ekos.focus] - Abs Focuser position changed to 10184 State: Busy
[2022-11-02T20:46:48.558 Atlantic Daylight Time DEBG ][ org.kde.kstars.indi] - MyFocuserPro2 : "[DEBUG] CMD <:01#> "
[2022-11-02T20:46:48.606 Atlantic Daylight Time DEBG ][ org.kde.kstars.indi] - MyFocuserPro2 : "[DEBUG] RES <I1#> "
[2022-11-02T20:46:48.646 Atlantic Daylight Time DEBG ][ org.kde.kstars.indi] - MyFocuserPro2 : "[DEBUG] CMD <:01#> "
[2022-11-02T20:46:48.687 Atlantic Daylight Time DEBG ][ org.kde.kstars.indi] - MyFocuserPro2 : "[DEBUG] RES <I1#> "
[2022-11-02T20:46:50.658 Atlantic Daylight Time DEBG ][ org.kde.kstars.indi] - MyFocuserPro2 : "[DEBUG] CMD <:01#> "
[2022-11-02T20:46:50.709 Atlantic Daylight Time DEBG ][ org.kde.kstars.indi] - MyFocuserPro2 : "[DEBUG] RES <I0#> "
[2022-11-02T20:46:50.750 Atlantic Daylight Time DEBG ][ org.kde.kstars.ekos.focus] - "Linear: un-doing extension. Moving back in by 100"
[2022-11-02T20:46:50.750 Atlantic Daylight Time INFO ][ org.kde.kstars.ekos.focus] - "Focusing inward by 100 steps..."
[2022-11-02T20:46:50.752 Atlantic Daylight Time INFO ][ org.kde.kstars.indi] - MyFocuserPro2 : "[INFO] Focuser reached requested position. "
[2022-11-02T20:46:50.791 Atlantic Daylight Time DEBG ][ org.kde.kstars.indi] - MyFocuserPro2 : "[DEBUG] CMD <:01#> "
[2022-11-02T20:46:50.921 Atlantic Daylight Time DEBG ][ org.kde.kstars.indi] - MyFocuserPro2 : "[DEBUG] RES <I0#> "
[2022-11-02T20:46:50.961 Atlantic Daylight Time DEBG ][ org.kde.kstars.indi] - MyFocuserPro2 : "[DEBUG] CMD <:0510084#> "
[2022-11-02T20:46:50.962 Atlantic Daylight Time INFO ][ org.kde.kstars.indi] - MyFocuserPro2 : "[INFO] Focuser is moving to position 10084 "

So Ekos requested 10285. Then asked the focuser "where are you?" The focuser responds with 10184 but is still moving. Ekos waits until it stops moving but never asks the focuser "where are you?" again. What if Ekos is using the last known ABS position it received rather than assuming the focuser is in fact at 10285 when it stops? It never asks again, then subtracts 100 from 10184 and issues a move absolute command to 10084 which the focuser does. You see the focuser never reports it's position after the 10184 response. It may in fact be at 10285 when it stops but Ekos may not be making this assumption.

This may explain why sometimes it seems to work. Maybe if the move is small, or if I increase the speed of the stepper motor it will work more reliably?

Just a theory. Ok, enough for tonight!

Thanks
Ken

Read More...