Dithering while crossing the meridian recognized as guiding
ClosedPublic

Authored by wreissenberger on Nov 1 2019, 12:51 PM.

Details

Summary

Restarting guiding after a meridian flip currently currently only happens, when the guider is in the guiding mode. For example, in the case that the meridian is crossed while dithering, the capture module does not recognize this as part of the guiding procedure and hence does not restart guiding as soon as the meridian flip is finished. This change fixes this and considers dithering, but also re-acquiring and calibrating as an indication that guiding should resume after meridian flip.

As a side effect, this fixes also the situation when dithering fails in the middle of a capture sequence. Without this fix, a failed dithering is ignored and capturing resumes without restart guiding.

Additionally, a possible a weakness that may cause null pointer exceptions in starting focus execution is fixed. And last but not least, some dead code has been eliminated.

And last but not least, dead code is removed.

Test Plan

Test case 1: Enable dithering, move the scope close but east of the meridian and start a capturing sequence. In order to ensure, that the meridian is crossed while dithering, run kstars inside the debugger and set a breakpoint before the call of dithering. Check, if after the meridian flip guiding is restarted.

Test case 2: Enable dithering and create a schedule that uses a capture sequence with more than one capture. Start the schedule and interrupt guiding after the first capture while dithering. Check, if capturing and guiding resume. Test this with and without the option for aborting guiding after dither failure set.

Diff Detail

Repository
R321 KStars
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
wreissenberger created this revision.Nov 1 2019, 12:51 PM
Restricted Application added a project: KDE Edu. · View Herald TranscriptNov 1 2019, 12:51 PM
Restricted Application added a subscriber: kde-edu. · View Herald Transcript
wreissenberger requested review of this revision.Nov 1 2019, 12:51 PM
mutlaqja accepted this revision.Nov 2 2019, 7:11 AM
This revision is now accepted and ready to land.Nov 2 2019, 7:11 AM
wreissenberger planned changes to this revision.Nov 2 2019, 3:36 PM

When dithering is interrupted in the middle of a capture sequence, both the Capture module and the Schedule module restart capturing, which needs to be fixed.

  • Resume capture after dithering only if nothing else happened inbetween
  • Dead code removed
This revision is now accepted and ready to land.Nov 2 2019, 4:51 PM
wreissenberger edited the summary of this revision. (Show Details)Nov 2 2019, 5:04 PM
wreissenberger edited the test plan for this revision. (Show Details)

Ok I think these changes make a lot of sense. Making a method for checking if guiding is active instead of just checking the state is a very good idea because then we can do what you did and check a number of guide states at the same time, but also if we need to check something else besides the state we could do that too. So I like that.

I also agree that a lot of that dead code can go, it is taking up room and you have to get around it to find the code that you want to work on. When I was making my recent changes for PHD2, I was surprised at how much commented out code there was. But some of it did prove useful actually and I used it for a reference of how what I was trying to do used to be done. But now, yes, I think it can go.

Part of the dead code you are removing is related to rapid guide, something Jasem had been working on that he said did not work well. I don't know if he ultimately has decided to abandon it. If he is fine with having that code removed, then great.

lancaster accepted this revision.Nov 2 2019, 5:20 PM
mutlaqja accepted this revision.Nov 2 2019, 6:31 PM
This revision was automatically updated to reflect the committed changes.