×

INDI Library v2.0.6 is Released (02 Feb 2024)

Bi-monthly release with minor bug fixes and improvements

How to control a mount from indi_setprop

  • Posts: 69
  • Thank you received: 12
Hello

I want to control a mount using indi_setprop. I did the following but it seemed that the mount didn't change coordinates. The problem also occurred with EQMOD. What is wrong with my command sequence? Thank you.

indi_setprop "Telescope Simulator.CONNECTION.CONNECT=On"
indi_setprop "Telescope Simulator.ON_COORD_SET.TRACK=On"
indi_setprop "Telescope Simulator.EQUATORIAL_EOD_COORD.RA=12.56"
indi_setprop "Telescope Simulator.EQUATORIAL_EOD_COORD.DEC=14"
 
indi_getprop "Telescope Simulator.EQUATORIAL_EOD_COORD.*"                                   
Telescope Simulator.EQUATORIAL_EOD_COORD.RA=330.95805199999955448
Telescope Simulator.EQUATORIAL_EOD_COORD.DEC=4907.3707799999974668

Anat
Last edit: 7 years 5 months ago by anat.
7 years 5 months ago #10736

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

Quotes around device name if it has space in it.

indi_setprop "Telescope Simulator".CONNECTION.CONNECT=On
7 years 5 months ago #10738

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

  • Posts: 69
  • Thank you received: 12
Hi Jasem,

Thanks. It still didn't work as shown below.
root@iAstroHub:~# indi_setprop "Telescope Simulator".EQUATORIAL_EOD_COORD.RA=12.56
root@iAstroHub:~# indi_setprop "Telescope Simulator".EQUATORIAL_EOD_COORD.DEC=14
root@iAstroHub:~# indi_getprop
Telescope Simulator.CONNECTION.CONNECT=On
Telescope Simulator.CONNECTION.DISCONNECT=Off
Telescope Simulator.DRIVER_INFO.DRIVER_NAME=Telescope Simulator
Telescope Simulator.DRIVER_INFO.DRIVER_EXEC=indi_simulator_telescope
Telescope Simulator.DRIVER_INFO.DRIVER_VERSION=1.0
Telescope Simulator.DRIVER_INFO.DRIVER_INTERFACE=5
Telescope Simulator.DEBUG.ENABLE=Off
Telescope Simulator.DEBUG.DISABLE=On
Telescope Simulator.CONFIG_PROCESS.CONFIG_LOAD=Off
Telescope Simulator.CONFIG_PROCESS.CONFIG_SAVE=Off
Telescope Simulator.CONFIG_PROCESS.CONFIG_DEFAULT=Off
Telescope Simulator.DEVICE_PORT.PORT=/dev/ttyUSB0
Telescope Simulator.TELESCOPE_BAUD_RATE.9600=On
Telescope Simulator.TELESCOPE_BAUD_RATE.19200=Off
Telescope Simulator.TELESCOPE_BAUD_RATE.38400=Off
Telescope Simulator.TELESCOPE_BAUD_RATE.57600=Off
Telescope Simulator.TELESCOPE_BAUD_RATE.115200=Off
Telescope Simulator.TELESCOPE_BAUD_RATE.230400=Off
Telescope Simulator.ACTIVE_DEVICES.ACTIVE_GPS=GPS Simulator
Telescope Simulator.ON_COORD_SET.TRACK=On
Telescope Simulator.ON_COORD_SET.SLEW=Off
Telescope Simulator.ON_COORD_SET.SYNC=Off
Telescope Simulator.EQUATORIAL_EOD_COORD.RA=0.017006837282000000083
Telescope Simulator.EQUATORIAL_EOD_COORD.DEC=90
Telescope Simulator.TELESCOPE_ABORT_MOTION.ABORT=Off
Telescope Simulator.TELESCOPE_MOTION_NS.MOTION_NORTH=Off
Telescope Simulator.TELESCOPE_MOTION_NS.MOTION_SOUTH=Off
Telescope Simulator.TELESCOPE_MOTION_WE.MOTION_WEST=Off
Telescope Simulator.TELESCOPE_MOTION_WE.MOTION_EAST=Off
Telescope Simulator.TELESCOPE_SLEW_RATE.SLEW_GUIDE=Off
Telescope Simulator.TELESCOPE_SLEW_RATE.SLEW_CENTERING=Off
Telescope Simulator.TELESCOPE_SLEW_RATE.SLEW_FIND=Off
Telescope Simulator.TELESCOPE_SLEW_RATE.SLEW_MAX=On
Telescope Simulator.TIME_UTC.UTC=
Telescope Simulator.TIME_UTC.OFFSET=
Telescope Simulator.GEOGRAPHIC_COORD.LAT=0
Telescope Simulator.GEOGRAPHIC_COORD.LONG=0
Telescope Simulator.GEOGRAPHIC_COORD.ELEV=0
Telescope Simulator.TELESCOPE_PARK.PARK=Off
Telescope Simulator.TELESCOPE_PARK.UNPARK=On
Telescope Simulator.TELESCOPE_PARK_POSITION.PARK_RA=13.726686511344775354
Telescope Simulator.TELESCOPE_PARK_POSITION.PARK_DEC=90
Telescope Simulator.TELESCOPE_PARK_OPTION.PARK_CURRENT=Off
Telescope Simulator.TELESCOPE_PARK_OPTION.PARK_DEFAULT=Off
Telescope Simulator.TELESCOPE_PARK_OPTION.PARK_WRITE_DATA=Off
Telescope Simulator.TELESCOPE_INFO.TELESCOPE_APERTURE=120
Telescope Simulator.TELESCOPE_INFO.TELESCOPE_FOCAL_LENGTH=900
Telescope Simulator.TELESCOPE_INFO.GUIDER_APERTURE=120
Telescope Simulator.TELESCOPE_INFO.GUIDER_FOCAL_LENGTH=900
Telescope Simulator.TARGET_EOD_COORD.RA=0
Telescope Simulator.TARGET_EOD_COORD.DEC=0
Telescope Simulator.USEJOYSTICK.ENABLE=Off
Telescope Simulator.USEJOYSTICK.DISABLE=On
Telescope Simulator.TELESCOPE_TIMED_GUIDE_NS.TIMED_GUIDE_N=0
Telescope Simulator.TELESCOPE_TIMED_GUIDE_NS.TIMED_GUIDE_S=0
Telescope Simulator.TELESCOPE_TIMED_GUIDE_WE.TIMED_GUIDE_W=0
Telescope Simulator.TELESCOPE_TIMED_GUIDE_WE.TIMED_GUIDE_E=0
Telescope Simulator.GUIDE_RATE.GUIDE_RATE_WE=0.2999999999999999889
Telescope Simulator.GUIDE_RATE.GUIDE_RATE_NS=0.2999999999999999889
Telescope Simulator.EQUATORIAL_PE.RA_PE=15
Telescope Simulator.EQUATORIAL_PE.DEC_PE=15
Telescope Simulator.PE_NS.PE_N=Off
Telescope Simulator.PE_NS.PE_S=Off
Telescope Simulator.PE_WE.PE_W=Off
Telescope Simulator.PE_WE.PE_E=Off
Telescope Simulator.DEVICE_PORT.PORT=/dev/ttyUSB0
Telescope Simulator.TELESCOPE_BAUD_RATE.9600=On
Telescope Simulator.TELESCOPE_BAUD_RATE.19200=Off
Telescope Simulator.TELESCOPE_BAUD_RATE.38400=Off
Telescope Simulator.TELESCOPE_BAUD_RATE.57600=Off
Telescope Simulator.TELESCOPE_BAUD_RATE.115200=Off
Telescope Simulator.TELESCOPE_BAUD_RATE.230400=Off
Telescope Simulator.ACTIVE_DEVICES.ACTIVE_GPS=GPS Simulator
Telescope Simulator.ON_COORD_SET.TRACK=On
Telescope Simulator.ON_COORD_SET.SLEW=Off
Telescope Simulator.ON_COORD_SET.SYNC=Off
Telescope Simulator.EQUATORIAL_EOD_COORD.RA=0.017006837282000000083
Telescope Simulator.EQUATORIAL_EOD_COORD.DEC=90
Telescope Simulator.TELESCOPE_ABORT_MOTION.ABORT=Off
Telescope Simulator.TIME_UTC.UTC=
Telescope Simulator.TIME_UTC.OFFSET=
Telescope Simulator.GEOGRAPHIC_COORD.LAT=0
Telescope Simulator.GEOGRAPHIC_COORD.LONG=0
Telescope Simulator.GEOGRAPHIC_COORD.ELEV=0
Telescope Simulator.TELESCOPE_PARK.PARK=Off
Telescope Simulator.TELESCOPE_PARK.UNPARK=On
Telescope Simulator.TELESCOPE_PARK_POSITION.PARK_RA=13.726686511344775354
Telescope Simulator.TELESCOPE_PARK_POSITION.PARK_DEC=90
Telescope Simulator.TELESCOPE_PARK_OPTION.PARK_CURRENT=Off
Telescope Simulator.TELESCOPE_PARK_OPTION.PARK_DEFAULT=Off
Telescope Simulator.TELESCOPE_PARK_OPTION.PARK_WRITE_DATA=Off
Telescope Simulator.TELESCOPE_MOTION_NS.MOTION_NORTH=Off
Telescope Simulator.TELESCOPE_MOTION_NS.MOTION_SOUTH=Off
Telescope Simulator.TELESCOPE_MOTION_WE.MOTION_WEST=Off
Telescope Simulator.TELESCOPE_MOTION_WE.MOTION_EAST=Off
Telescope Simulator.TELESCOPE_SLEW_RATE.SLEW_GUIDE=Off
Telescope Simulator.TELESCOPE_SLEW_RATE.SLEW_CENTERING=Off
Telescope Simulator.TELESCOPE_SLEW_RATE.SLEW_FIND=Off
Telescope Simulator.TELESCOPE_SLEW_RATE.SLEW_MAX=On
Telescope Simulator.TELESCOPE_INFO.TELESCOPE_APERTURE=120
Telescope Simulator.TELESCOPE_INFO.TELESCOPE_FOCAL_LENGTH=900
Telescope Simulator.TELESCOPE_INFO.GUIDER_APERTURE=120
Telescope Simulator.TELESCOPE_INFO.GUIDER_FOCAL_LENGTH=900
Telescope Simulator.TARGET_EOD_COORD.RA=0
Telescope Simulator.TARGET_EOD_COORD.DEC=0
Telescope Simulator.USEJOYSTICK.ENABLE=Off
Telescope Simulator.USEJOYSTICK.DISABLE=On
Telescope Simulator.TELESCOPE_TIMED_GUIDE_NS.TIMED_GUIDE_N=0
Telescope Simulator.TELESCOPE_TIMED_GUIDE_NS.TIMED_GUIDE_S=0
Telescope Simulator.TELESCOPE_TIMED_GUIDE_WE.TIMED_GUIDE_W=0
Telescope Simulator.TELESCOPE_TIMED_GUIDE_WE.TIMED_GUIDE_E=0
Telescope Simulator.GUIDE_RATE.GUIDE_RATE_WE=0.2999999999999999889
Telescope Simulator.GUIDE_RATE.GUIDE_RATE_NS=0.2999999999999999889
Telescope Simulator.EQUATORIAL_PE.RA_PE=15
Telescope Simulator.EQUATORIAL_PE.DEC_PE=15
Telescope Simulator.PE_NS.PE_N=Off
Telescope Simulator.PE_NS.PE_S=Off
Telescope Simulator.PE_WE.PE_W=Off
Telescope Simulator.PE_WE.PE_E=Off
7 years 5 months ago #10741

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

As explained in INDI Developer Manual scripting examples , you need to set both values at once. You cannot set partial value for property, it must be for all elements (RA/DEC in this case)
The following user(s) said Thank You: anat
7 years 5 months ago #10744

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

  • Posts: 69
  • Thank you received: 12

Thanks. Note that the quote has to cover the whole command:
root@iAstroHub:~# indi_setprop "Telescope Simulator.EQUATORIAL_EOD_COORD.RA;DEC=2;1"
root@iAstroHub:~# indi_setprop "Telescope Simulator".EQUATORIAL_EOD_COORD.RA;DEC=2;1
Malformed assignment: RA
Purpose: set one or more writable INDI properties
$Revision: 1.6 $
Usage: indi_setprop [options] {[type] spec} ...
Options:
  -d f  : use file descriptor f already open to server
  -h h  : alternate host, default is localhost
  -p p  : alternate port, default is 7624
  -t t  : max time to wait, default is 2 secs
  -v    : verbose (more are cumulative)
Each spec optionally preceded by its type is sent without first confirming
its structure. This is much more efficient but there is no error checking.
Types are indicated with the following flags:
  -x    : Text
  -n    : Number
  -s    : Switch
Spec may be either:
    device.property.e1[;e2...]=v1[;v2...]
  or
    device.property.e1=v1[;e2=v2...]
Exit status:
  0: all settings successful
  1: at least one setting was invalid
  2: real trouble, try repeating with -v
-bash: 1: command not found
root@iAstroHub:~#
7 years 5 months ago #10747

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

  • Posts: 2247
  • Thank you received: 223
The following user(s) said Thank You: anat
7 years 5 months ago #10750

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

  • Posts: 69
  • Thank you received: 12

Hi Stephane

Good to hear from you. It works as expected now. Thanks.

Best regards,
Anat
7 years 5 months ago #10752

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

Time to create page: 0.629 seconds