OpenC3 / cosmos

OpenC3 COSMOS
https://openc3.com
Other
111 stars 31 forks source link

How to check the connection status of a target in a script #1706

Closed hmaclachlan closed 1 week ago

hmaclachlan commented 1 week ago

Hello,

Is there a method to checking the connection status of a target in a script? In digging through the code of the CmdTlmServer, it seems as though you can use item.connected to determine connection status, I am unsure how to configure to be used in script runner.

image

Thanks

jmthomas commented 1 week ago

See https://docs.openc3.com/docs/guides/scripting-api#interfaces

interface = get_interface("INST_INT")
puts interface['state']