×

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

Bi-monthly release with minor bug fixes and improvements

Connect to driver from terminal. Minimal client

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

My electronics list for my observatory is coming to completion, but still some software to work out.

I'm using my custom usbrelay roof / power driver, that seems to work well in tesitng.
However my plan is to leave my raspi powered on at all times, as it's the power and roof controller, but have my odroid + camera, mount, etc power on remotely.
The relay driver has power mapping for connect, unpark and park, but as is, i will have to start kstars and ekos to connect to the driver, to initiate connect mapping.
This is a problem when writing my script for connecting everything with ssh tunnels and the raspi chained trough the odroid.

So is there anything i can do on the terminal just to connect to the driver, and then disconnect? I know there is a way to script INDI things in python, but not sure if this is possible. My startup script is BASH, but if i could make a simple executable in python i can execute it from the script?

Hope this makes sense, all tips appreciated :)
Proud owner of Observatory 17b - A remote Linux observatory.
Website: Observatory 17b
Build thread @ SGL: Starting summers observatory project
7 years 9 months ago #9122

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

You can use indi_setprop
7 years 9 months ago #9123

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

  • Posts: 314
  • Thank you received: 95
7 years 9 months ago #9124

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

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

Found the documentation indilib.org/develop/developer-manual/104...ting.html#h3-2-usage
What are the correct property and element for connection? CONNECTION and connected?

I guess it will be close to
indi_setprop 'USBRelay2 Roof Dome.CONNECTION.CONNECTED=true'

but it returns
No USBRelay2 Roof Dome.CONNECTION.CONNECTED from localhost:7624
2016-06-30T20:57:47: Client 0: read EOF
2016-06-30T20:57:47: Client 0: shut down complete - bye!

//Edit

That did work.. I will have to check my code. I have a hackish timerhit in my connect to do the connection powering on and off after the powermapping is loaded from the config. Think that is why the relay did not switch.
Proud owner of Observatory 17b - A remote Linux observatory.
Website: Observatory 17b
Build thread @ SGL: Starting summers observatory project
Last edit: 7 years 9 months ago by Magnus.
7 years 9 months ago #9125

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

Time to create page: 0.491 seconds