Hello Simon,
That's great to here. Please share some photos of this observatory with us. I am doing exactly the same thing in my home observatory, so I'm not using the Pegasus, since I built my observatory back in 2015 and went to
Digital Loggers Power Switch
to turn on/off the equipment when the observatory is started/closed. To answer you question:
1. Yes, it's possible, you can use indi_setprop to toggle UPB ports on/off. Though that means that A) Pegasus has to be powered at all times, and
indiserver running UPB must be up and running.
2. Yes, as described above.
Unfortunately, I don't have such a script ready since I use the web power switch to do this and not Pegasus. Figuring out how to use indi_setprop is probably the easy part. In order to start the drivers for your equipment *after* you power them up, you also need to ask INDI server to start the respective drivers. So it goes something like this.
mkfifo /tmp/indififo
indiserver -v -f /tmp/indififo
This starts INDI server in FIFO mode.
Then open another console
echo "start indi_pegasus_upb" > /tmp/indififo
This would case the INDI server to start this driver. Next you'd use indi_setprop to toggle the 12v for them on/off. Say, you turned power for the QHY camera, then you'd this:
echo "start indi_qhy_ccd" > /tmp/indififo
Then that would start is on the server and so forth. I hope this helps.