ASCOM Commands

Feature requests / 3rd party software development
Post Reply
clwas1
Posts: 8
Joined: Fri Feb 19, 2021 8:11 pm

ASCOM Commands

Post by clwas1 »

Do you have or can you publish the ASCOM commands I can use to control the On/Off power switches, initiate a connection, etc. plus examples? I am looking to turn on and off one of the four power outlets from ACP in a JavaScript.

Thanks.
clwas1
Posts: 8
Joined: Fri Feb 19, 2021 8:11 pm

Re: ASCOM Commands

Post by clwas1 »

I have figured out the scripting for anyone who is interested.

function main()
{
var Pegasus = new ActiveXObject("ASCOM.pegasus_upb.Switch");
Console.PrintLine("Pegasus variable set..." );


Pegasus.Connected = true;
Console.PrintLine("Pegasus Connected..." );
Pegasus.SetSwitch(2, true); // Switch # starts at 0
Console.PrintLine("Switch #3 On..." );

Util.WaitForMilliseconds(10000); // Pause 10 seconds
Pegasus.SetSwitch(2, false);
Console.PrintLine("Switch #3 Off..." );


Pegasus.Connected = false;
Console.PrintLine("Pegasus Disconnected..." );

}

Thanks.
johnakers
Posts: 1
Joined: Fri Nov 12, 2021 3:01 pm

Re: ASCOM Commands

Post by johnakers »

Can you provide more advance level commands.
Post Reply