×

INDI Library v2.0.7 is Released (01 Apr 2024)

Bi-monthly release with minor bug fixes and improvements

Watchdog choice to park dome fiirst or mount first

  • Posts: 271
  • Thank you received: 72
Hi.
I have been testing watchdog and i really like it.
Only issue is that i need to be able to park my mount before my dome. i made an update where the user can choose.
Have tested all the different combinations of dome and or mount, and does not seem to have added any bugs.

Disadvantages park dome then mount: If roof cannot be closed without possibly hitting mount this will not be safe
Disadvantages park mount then dome: If the mount fails to park the dome will not. This can leave the dome open.

Changes i made.
1. Option tab switch "Park order" with options Dome first or Mount first
2. Rearrange Main tab Shutdown switch order.
3. Updates to TimerHit to allow for the two different shutdown procedures
4. Necessary changes to code.

Posted it as a Gist in case it's of any interest.
gist.github.com/magnue/65317ea1fe3893341540
Proud owner of Observatory 17b - A remote Linux observatory.
Website: Observatory 17b
Build thread @ SGL: Starting summers observatory project
Last edit: 8 years 3 months ago by Magnus.
8 years 3 months ago #6431

Please Log in or Create an account to join the conversation.

It parks mount before dome by default, it didn't in your case?!
8 years 3 months ago #6432

Please Log in or Create an account to join the conversation.

  • Posts: 271
  • Thank you received: 72
Had to check i had the nevest version when starting...

The code that initiates the shutdown looks like
case WATCHDOG_CLIENT_STARTED:
        // Check if client is ready
        if (watchdogClient->isConnected())
        {
            DEBUGF(INDI::Logger::DBG_DEBUG, "Connected to INDI server %s @ %s", SettingsT[0].text, SettingsT[1].text);
 
            if (ShutdownProcedureS[PARK_DOME].s == ISS_ON)
                parkDome();
            else if (ShutdownProcedureS[PARK_MOUNT].s == ISS_ON)
                parkMount();
            else if (ShutdownProcedureS[EXECUTE_SCRIPT].s == ISS_ON)
                executeScript();
        }
        else
            DEBUG(INDI::Logger::DBG_DEBUG, "Waiting for INDI server connection...");
        break;

And in the main tab the switches are: Dome, Mount, Script.
Have i not updated after pulling or something?
Proud owner of Observatory 17b - A remote Linux observatory.
Website: Observatory 17b
Build thread @ SGL: Starting summers observatory project
8 years 3 months ago #6433

Please Log in or Create an account to join the conversation.

No, I am surprised I implemented it as this before as it it against what Ekos Scheduler performs when doing shutdown procedure. At any rate, park/dome swapped now, but not tested. Update code.
8 years 3 months ago #6434

Please Log in or Create an account to join the conversation.

  • Posts: 271
  • Thank you received: 72
Ok.

Did you look at the gist i posted?
Is it not a good idea to let the user choose?
If you have a dome that can be parked without parking the mount first, then the safest thing is to park the dome first in case the mount fails to park.

Or do you not like the "slightly" ugly code of the multiple switch properties that does the same thing :)
Proud owner of Observatory 17b - A remote Linux observatory.
Website: Observatory 17b
Build thread @ SGL: Starting summers observatory project
Last edit: 8 years 3 months ago by Magnus.
8 years 3 months ago #6435

Please Log in or Create an account to join the conversation.

Currently the procedure just stops if there is an error. Perhaps it could be expanded to tackle errors in parking the mount and dome as well. Because the dome parking could fail as well resulting in an overall failure for the shutdown procedure.
8 years 3 months ago #6436

Please Log in or Create an account to join the conversation.

  • Posts: 271
  • Thank you received: 72
It would be difficult as there is no way of knowing why the dome or mount could have failed parking.
A given dome driver could fail to park, just because it failed to update the parkstatus when done, or it could have failed because it could not connect to motor controller or similar.

A possibility could be to reconnect and try again, or issue a unpark before retrying to park. Not sure if there are any real life senarios where it would help.
Assuming its safe to park dome on a failure to park mount could result in a crashed scope. I'll rather face an hours drive to fix it manually than to risk that.

It's worth mentioning that i so far have not experienced my celestron mount or the telescope simulator failing to park :)

Tested the update and it works as expected.
Proud owner of Observatory 17b - A remote Linux observatory.
Website: Observatory 17b
Build thread @ SGL: Starting summers observatory project
Last edit: 8 years 3 months ago by Magnus. Reason: Tested the update and it works as expected.
8 years 3 months ago #6437

Please Log in or Create an account to join the conversation.

  • Posts: 2255
  • Thank you received: 223
I have no played with the Watchdog yet (interested in it), in my situation if the mount is not parked and the observatory closes... that's going to be quite a disaster.
I've done lots of testing with the Ekos Scheduler and worked with Jasem, the order should be park mount first then close observatory roof.
For you it's 1 hour drive, for me it's close to 10 hours, drive through 3 country to reach the destination... lol, you got it easy ;)

I have in the mount dovetail bar, a 3 axis gyro which I can monitor (no indi driver for it yet), it tells me exactly where the scope is pointing to in relation to horizontal.
You could add micro switches to the mount too that would stop the observatory to close. Lots of options.

Back to the watchdog, can someone gives me some pointers on how to use it correctly please?
8 years 3 months ago #6441

Please Log in or Create an account to join the conversation.

  • Posts: 271
  • Thank you received: 72
A 10 hour drive would be a problem :)

In my testing it is just to set the correct snoopdevices and port. As its running on the same server as dome and mount then the default localhost is ok.

Check off mount an dome in the main tab. Then i think you must save settings. If you then disconnect from the server it will start shutdown in x minutes 'the heartbeat value'. When it starts shutdown procedure it acts as a client an connect to lokalhost and issue park-mount and park-dome
Proud owner of Observatory 17b - A remote Linux observatory.
Website: Observatory 17b
Build thread @ SGL: Starting summers observatory project
8 years 3 months ago #6445

Please Log in or Create an account to join the conversation.

  • Posts: 2255
  • Thank you received: 223
I shall test this with my observatory and mount, last time I was playing with the watchdog without knowing how it worked was with the simulator stuff.
8 years 3 months ago #6446

Please Log in or Create an account to join the conversation.

  • Posts: 271
  • Thank you received: 72
Probably smart to do a final simulated test, to make sure nothing goes wrong.

What type of gyro do you use? Does it come with some sort of cpp interface, or some communication dokumentation?

On my phone, so no english spell check...
Proud owner of Observatory 17b - A remote Linux observatory.
Website: Observatory 17b
Build thread @ SGL: Starting summers observatory project
Last edit: 8 years 3 months ago by Magnus.
8 years 3 months ago #6447

Please Log in or Create an account to join the conversation.

  • Posts: 2255
  • Thank you received: 223
Time to create page: 0.187 seconds