Hamlib  3.0.1
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Files | Data Structures | Macros | Typedefs | Enumerations | Functions
Rotator API

Files

file  rot_conf.c
 Rotator Configuration Interface.
 
file  rotator.c
 Rotator interface.
 
file  rotator.h
 Hamlib rotator data structures.
 
file  rotlist.h
 Hamlib rotator model definitions.
 

Data Structures

struct  rot_caps
 Rotator data structure. More...
 
struct  rot_state
 Live data and customized fields. More...
 
struct  rot
 This is the master data structure, acting as a handle for the controlled rotator. More...
 

Macros

#define NETROTCTL_RET   "RPRT "
 Token in the netrotctl protocol for returning error code.
 
#define ROT_RESET_ALL   1
 A macro that returns the flag for the reset operation. More...
 
#define ROT_TYPE_MASK   (ROT_FLAG_AZIMUTH|ROT_FLAG_ELEVATION)
 
#define ROT_TYPE_OTHER   0
 
#define ROT_TYPE_AZIMUTH   ROT_FLAG_AZIMUTH
 
#define ROT_TYPE_ELEVATION   ROT_FLAG_ELEVATION
 
#define ROT_TYPE_AZEL   (ROT_FLAG_AZIMUTH|ROT_FLAG_ELEVATION)
 
#define ROT_MOVE_UP   (1<<1)
 A macro that returns the flag for the UP direction. More...
 
#define ROT_MOVE_DOWN   (1<<2)
 A macro that returns the flag for the DOWN direction. More...
 
#define ROT_MOVE_LEFT   (1<<3)
 A macro that returns the flag for the LEFT direction. More...
 
#define ROT_MOVE_CCW   ROT_MOVE_LEFT
 A macro that returns the flag for the counterclockwise direction. More...
 
#define ROT_MOVE_RIGHT   (1<<4)
 A macro that returns the flag for the RIGHT direction. More...
 
#define ROT_MOVE_CW   ROT_MOVE_RIGHT
 A macro that returns the flag for the clockwise direction. More...
 
#define rot_debug   rig_debug
 Convenience definition for debug level. More...
 
#define ROT_MODEL_NONE   0
 
#define ROT_MODEL_DUMMY   ROT_MAKE_MODEL(ROT_DUMMY, 1)
 A macro that returns the model number for the dummy backend. More...
 
#define ROT_MODEL_NETROTCTL   ROT_MAKE_MODEL(ROT_DUMMY, 2)
 A macro that returns the model number for the Network backend. More...
 
#define ROT_DUMMY   0
 
#define ROT_BACKEND_DUMMY   "dummy"
 
#define ROT_MODEL_EASYCOMM1   ROT_MAKE_MODEL(ROT_EASYCOMM, 1)
 A macro that returns the model number of the EasyComm 1 backend. More...
 
#define ROT_MODEL_EASYCOMM2   ROT_MAKE_MODEL(ROT_EASYCOMM, 2)
 A macro that returns the model number of the EasyComm 2 backend. More...
 
#define ROT_EASYCOMM   2
 
#define ROT_BACKEND_EASYCOMM   "easycomm"
 
#define ROT_MODEL_TRAKBOX   ROT_MAKE_MODEL(ROT_EASYCOMM, 3)
 
#define ROT_MODEL_EASYCOMM3   ROT_MAKE_MODEL(ROT_EASYCOMM, 4)
 
#define ROT_MODEL_FODTRACK   ROT_MAKE_MODEL(ROT_FODTRACK, 1)
 A macro that returns the model number of the Fodtrack backend. More...
 
#define ROT_FODTRACK   3
 
#define ROT_BACKEND_FODTRACK   "fodtrack"
 
#define ROT_MODEL_ROTOREZ   ROT_MAKE_MODEL(ROT_ROTOREZ, 1)
 A macro that returns the model number of the Rotor-EZ backend. More...
 
#define ROT_MODEL_ROTORCARD   ROT_MAKE_MODEL(ROT_ROTOREZ, 2)
 A macro that returns the model number of the Rotor Card backend. More...
 
#define ROT_MODEL_DCU   ROT_MAKE_MODEL(ROT_ROTOREZ, 3)
 A macro that returns the model number of the DCU backend. More...
 
#define ROT_MODEL_ERC   ROT_MAKE_MODEL(ROT_ROTOREZ, 4)
 A macro that returns the model number of the ERC backend. More...
 
#define ROT_MODEL_RT21   ROT_MAKE_MODEL(ROT_ROTOREZ, 5)
 A macro that returns the model number of the RT21 backend. More...
 
#define ROT_ROTOREZ   4
 
#define ROT_BACKEND_ROTOREZ   "rotorez"
 
#define ROT_MODEL_SARTEK1   ROT_MAKE_MODEL(ROT_SARTEK, 1)
 A macro that returns the model number of the SARtek-1 backend. More...
 
#define ROT_SARTEK   5
 
#define ROT_BACKEND_SARTEK   "sartek"
 
#define ROT_MODEL_GS232A   ROT_MAKE_MODEL(ROT_GS232A, 1)
 A macro that returns the model number of the GS-232A backend. More...
 
#define ROT_MODEL_GS232   ROT_MAKE_MODEL(ROT_GS232A, 2) /* Not A or B */
 A macro that returns the model number of the GS-232 backend. More...
 
#define ROT_MODEL_GS232B   ROT_MAKE_MODEL(ROT_GS232A, 3)
 A macro that returns the model number of the GS-232B backend. More...
 
#define ROT_MODEL_F1TETRACKER   ROT_MAKE_MODEL(ROT_GS232A, 4)
 A macro that returns the model number of the F1TETRACKER backend. More...
 
#define ROT_GS232A   6
 
#define ROT_BACKEND_GS232A   "gs232a"
 
#define ROT_MODEL_PCROTOR   ROT_MAKE_MODEL(ROT_KIT, 1)
 A macro that returns the model number of the PcRotor/WA6UFQ backend. More...
 
#define ROT_KIT   7
 
#define ROT_BACKEND_KIT   "kit"
 
#define ROT_MODEL_HD1780   ROT_MAKE_MODEL(ROT_HEATHKIT, 1)
 A macro that returns the model number of the HD 1780 backend.
 
#define ROT_HEATHKIT   8
 
#define ROT_BACKEND_HEATHKIT   "heathkit"
 
#define ROT_MODEL_SPID_ROT2PROG   ROT_MAKE_MODEL(ROT_SPID, 1)
 A macro that returns the model number of the ROT2PROG backend. More...
 
#define ROT_MODEL_SPID_ROT1PROG   ROT_MAKE_MODEL(ROT_SPID, 2)
 A macro that returns the model number of the ROT1PROG backend. More...
 
#define ROT_SPID   9
 
#define ROT_BACKEND_SPID   "spid"
 
#define ROT_MODEL_RC2800   ROT_MAKE_MODEL(ROT_M2, 1)
 A macro that returns the model number of the RC2800 backend. More...
 
#define ROT_M2   10
 
#define ROT_BACKEND_M2   "m2"
 
#define ROT_MODEL_RCI_AZEL   ROT_MAKE_MODEL(ROT_ARS, 1)
 A macro that returns the model number of the RCI_AZEL backend. More...
 
#define ROT_MODEL_RCI_AZ   ROT_MAKE_MODEL(ROT_ARS, 2)
 A macro that returns the model number of the RCI_AZ backend. More...
 
#define ROT_ARS   11
 
#define ROT_BACKEND_ARS   "ars"
 
#define ROT_MODEL_IF100   ROT_MAKE_MODEL(ROT_AMSAT, 1)
 A macro that returns the model number of the IF-100 backend. More...
 
#define ROT_AMSAT   12
 
#define ROT_BACKEND_AMSAT   "amsat"
 
#define ROT_MODEL_TS7400   ROT_MAKE_MODEL(ROT_TS7400, 1)
 A macro that returns the model number of the TS7400 backend. More...
 
#define ROT_TS7400   13
 
#define ROT_BACKEND_TS7400   "ts7400"
 
#define ROT_MODEL_NEXSTAR   ROT_MAKE_MODEL(ROT_CELESTRON, 1)
 A macro that returns the model number of the NEXSTAR backend. More...
 
#define ROT_CELESTRON   14
 
#define ROT_BACKEND_CELESTRON   "celestron"
 
#define ROT_MODEL_ETHER6   ROT_MAKE_MODEL(ROT_ETHER6, 1)
 A macro that returns the model number of the Ether6 backend. More...
 
#define ROT_ETHER6   15
 
#define ROT_BACKEND_ETHER6   "ether6"
 
#define ROT_MODEL_CNCTRK   ROT_MAKE_MODEL(ROT_CNCTRK, 1)
 A macro that returns the model number of the CNCTRK backend. More...
 
#define ROT_CNCTRK   16
 
#define ROT_BACKEND_CNCTRK   "cnctrk"
 

Typedefs

typedef struct rot ROT
 Rotator structure definition (see rot for details).
 
typedef float elevation_t
 Type definition for elevation. More...
 
typedef float azimuth_t
 Type definition for azimuth. More...
 
typedef int rot_reset_t
 Type definition for rotator reset. More...
 
typedef int rot_model_t
 Convenience type definition for rotator model.
 

Enumerations

enum  rot_type_t { ROT_FLAG_AZIMUTH = (1<<1), ROT_FLAG_ELEVATION = (1<<2) }
 Rotator type flags. More...
 

Functions

int frontrot_set_conf (ROT *rot, token_t token, const char *val)
 Set rotator state info from alpha input. More...
 
int frontrot_get_conf (ROT *rot, token_t token, char *val)
 Get data from rotator state in alpha form. More...
 
int rot_token_foreach (ROT *rot, int(*cfunc)(const struct confparams *, char *), char *data)
 Executes cfunc on all the elements stored in the conf table. More...
 
const struct confparamsrot_confparam_lookup (ROT *rot, const char *name)
 lookup conf token by its name, return pointer to confparams struct. More...
 
token_t rot_token_lookup (ROT *rot, const char *name)
 Simple lookup returning token id associated with name. More...
 
int rot_set_conf (ROT *rot, token_t token, const char *val)
 set a rotator configuration parameter More...
 
int rot_get_conf (ROT *rot, token_t token, char *val)
 get the value of a configuration parameter More...
 
int foreach_opened_rot (int(*cfunc)(ROT *, char *), char *data)
 execs cfunc() on each opened rot More...
 
ROTrot_init (rot_model_t rot_model)
 allocate a new ROT handle More...
 
int rot_open (ROT *rot)
 open the communication to the rot More...
 
int rot_close (ROT *rot)
 close the communication to the rot More...
 
int rot_cleanup (ROT *rot)
 release a rot handle and free associated memory More...
 
int rot_set_position (ROT *rot, azimuth_t azimuth, elevation_t elevation)
 set the azimuth and elevation of the rotator More...
 
int rot_get_position (ROT *rot, azimuth_t *azimuth, elevation_t *elevation)
 get the azimuth and elevation of the rotator More...
 
int rot_park (ROT *rot)
 park the antenna More...
 
int rot_stop (ROT *rot)
 stop the rotator More...
 
int rot_reset (ROT *rot, rot_reset_t reset)
 reset the rotator More...
 
int rot_move (ROT *rot, int direction, int speed)
 move the rotator in the specified direction More...
 
const char * rot_get_info (ROT *rot)
 get general information from the rotator More...
 
ROTrot_init ()
 
int rot_open ()
 
int rot_close ()
 
int rot_cleanup ()
 
int rot_set_conf ()
 
int rot_get_conf ()
 
int rot_set_position ()
 
int rot_get_position ()
 
int rot_stop ()
 
int rot_park ()
 
int rot_reset ()
 
int rot_move ()
 
const char * rot_get_info ()
 
int rot_register ()
 
int rot_unregister ()
 
int rot_list_foreach ()
 
int rot_load_backend ()
 
int rot_check_backend ()
 
int rot_load_all_backends ()
 
rot_model_t rot_probe_all ()
 
int rot_token_foreach ()
 
const struct confparamsrot_confparam_lookup ()
 
token_t rot_token_lookup ()
 
const struct rot_capsrot_get_caps ()
 
int qrb ()
 
double distance_long_path ()
 
double azimuth_long_path ()
 
int longlat2locator ()
 
int locator2longlat ()
 
double dms2dec ()
 
int dec2dms ()
 
int dec2dmmm ()
 
double dmmm2dec ()
 

Detailed Description

Rotator interface

Rotator can be any kind of azimuth or azimuth and elevation controlled antenna system.

Macro Definition Documentation

#define rot_debug   rig_debug

Convenience definition for debug level.

This is just as convenience definition of the rotator debug level, and is the same as for the rig debug level.

See also
rig_debug
#define ROT_MODEL_CNCTRK   ROT_MAKE_MODEL(ROT_CNCTRK, 1)

A macro that returns the model number of the CNCTRK backend.

The CNCTRK backend can be used with rotators that support, the LinuxCNC running Axis GUI interface.

#define ROT_MODEL_DCU   ROT_MAKE_MODEL(ROT_ROTOREZ, 3)

A macro that returns the model number of the DCU backend.

The Rotor-EZ backend can be used with rotators that support the DCU command set by Hy-Gain (currently the DCU-1).

#define ROT_MODEL_DUMMY   ROT_MAKE_MODEL(ROT_DUMMY, 1)

A macro that returns the model number for the dummy backend.

The dummy backend, as the name suggests, is a backend which performs no hardware operations and always behaves as one would expect. It can be thought of as a hardware simulator and is very usefull for testing client applications.

#define ROT_MODEL_EASYCOMM1   ROT_MAKE_MODEL(ROT_EASYCOMM, 1)

A macro that returns the model number of the EasyComm 1 backend.

The EasyComm 1 backend can be used with rotators that support the EASYCOMM I Standard.

#define ROT_MODEL_EASYCOMM2   ROT_MAKE_MODEL(ROT_EASYCOMM, 2)

A macro that returns the model number of the EasyComm 2 backend.

The EasyComm 2 backend can be used with rotators that support the EASYCOMM II Standard.

#define ROT_MODEL_ERC   ROT_MAKE_MODEL(ROT_ROTOREZ, 4)

A macro that returns the model number of the ERC backend.

The Rotor-EZ backend can be used with rotators that support the DCU command set by DF9GR (currently the ERC).

#define ROT_MODEL_ETHER6   ROT_MAKE_MODEL(ROT_ETHER6, 1)

A macro that returns the model number of the Ether6 backend.

The Ether6 backend can be used with rotators that support the Ether6 protocol and alike.

#define ROT_MODEL_F1TETRACKER   ROT_MAKE_MODEL(ROT_GS232A, 4)

A macro that returns the model number of the F1TETRACKER backend.

The F1TETRACKER backend can be used with rotators that support the F1TETRACKER protocol.

#define ROT_MODEL_FODTRACK   ROT_MAKE_MODEL(ROT_FODTRACK, 1)

A macro that returns the model number of the Fodtrack backend.

The Fodtrack backend can be used with rotators that support the FODTRACK Standard.

#define ROT_MODEL_GS232   ROT_MAKE_MODEL(ROT_GS232A, 2) /* Not A or B */

A macro that returns the model number of the GS-232 backend.

The GS-232 backend can be used with rotators that support the GS-232 protocol.

#define ROT_MODEL_GS232A   ROT_MAKE_MODEL(ROT_GS232A, 1)

A macro that returns the model number of the GS-232A backend.

The GS-232A backend can be used with rotators that support the GS-232A protocol.

#define ROT_MODEL_GS232B   ROT_MAKE_MODEL(ROT_GS232A, 3)

A macro that returns the model number of the GS-232B backend.

The GS-232B backend can be used with rotators that support the GS-232B protocol.

#define ROT_MODEL_IF100   ROT_MAKE_MODEL(ROT_AMSAT, 1)

A macro that returns the model number of the IF-100 backend.

The AMSAT backend can be used with rotators that support, among other, the IF-100 interface.

#define ROT_MODEL_NETROTCTL   ROT_MAKE_MODEL(ROT_DUMMY, 2)

A macro that returns the model number for the Network backend.

This backend allows use of the rotctld daemon through the normal Hamlib API.

#define ROT_MODEL_NEXSTAR   ROT_MAKE_MODEL(ROT_CELESTRON, 1)

A macro that returns the model number of the NEXSTAR backend.

The CELESTRON backend can be used with rotators that support the Celestron protocol and alike.

#define ROT_MODEL_PCROTOR   ROT_MAKE_MODEL(ROT_KIT, 1)

A macro that returns the model number of the PcRotor/WA6UFQ backend.

The kit backend can be used with home brewed rotators.

#define ROT_MODEL_RC2800   ROT_MAKE_MODEL(ROT_M2, 1)

A macro that returns the model number of the RC2800 backend.

The M2 backend can be used with rotators that support the RC2800 protocol and alike.

#define ROT_MODEL_RCI_AZ   ROT_MAKE_MODEL(ROT_ARS, 2)

A macro that returns the model number of the RCI_AZ backend.

The ARS backend can be used with rotators that support the ARS protocol.

#define ROT_MODEL_RCI_AZEL   ROT_MAKE_MODEL(ROT_ARS, 1)

A macro that returns the model number of the RCI_AZEL backend.

The ARS backend can be used with rotators that support the ARS protocol.

#define ROT_MODEL_ROTORCARD   ROT_MAKE_MODEL(ROT_ROTOREZ, 2)

A macro that returns the model number of the Rotor Card backend.

The Rotor-EZ backend can be used with Yaesu rotators that support the extended DCU command set by Idiom Press Rotor Card board.

#define ROT_MODEL_ROTOREZ   ROT_MAKE_MODEL(ROT_ROTOREZ, 1)

A macro that returns the model number of the Rotor-EZ backend.

The Rotor-EZ backend can be used with Hy-Gain rotators that support the extended DCU command set by Idiom Press Rotor-EZ board.

#define ROT_MODEL_RT21   ROT_MAKE_MODEL(ROT_ROTOREZ, 5)

A macro that returns the model number of the RT21 backend.

The Rotor-EZ backend can be used with rotators that support the DCU command set by Green Heron (currently the RT-21).

#define ROT_MODEL_SARTEK1   ROT_MAKE_MODEL(ROT_SARTEK, 1)

A macro that returns the model number of the SARtek-1 backend.

The sartek backend can be used with rotators that support the SARtek protocol.

#define ROT_MODEL_SPID_ROT1PROG   ROT_MAKE_MODEL(ROT_SPID, 2)

A macro that returns the model number of the ROT1PROG backend.

The SPID backend can be used with rotators that support the SPID protocol.

#define ROT_MODEL_SPID_ROT2PROG   ROT_MAKE_MODEL(ROT_SPID, 1)

A macro that returns the model number of the ROT2PROG backend.

The SPID backend can be used with rotators that support the SPID protocol.

#define ROT_MODEL_TS7400   ROT_MAKE_MODEL(ROT_TS7400, 1)

A macro that returns the model number of the TS7400 backend.

The TS-7400 backend supports and embedded ARM board using the TS-7400 Linux board. More information is at http://www.embeddedarm.com

#define ROT_MOVE_CCW   ROT_MOVE_LEFT

A macro that returns the flag for the counterclockwise direction.

This macro defines the value of the counterclockwise direction which can be used with the rot_move() function. This value is equivalent to ROT_MOVE_LEFT .

See also
rot_move(), ROT_MOVE_UP, ROT_MOVE_DOWN, ROT_MOVE_LEFT, ROT_MOVE_RIGHT, ROT_MOVE_CW
#define ROT_MOVE_CW   ROT_MOVE_RIGHT

A macro that returns the flag for the clockwise direction.

This macro defines the value of the clockwise direction wich can be used with the rot_move() function. This value is equivalent to ROT_MOVE_RIGHT .

See also
rot_move(), ROT_MOVE_UP, ROT_MOVE_DOWN, ROT_MOVE_LEFT, ROT_MOVE_CCW, ROT_MOVE_RIGHT
#define ROT_MOVE_DOWN   (1<<2)

A macro that returns the flag for the DOWN direction.

This macro defines the value of the DOWN direction which can be used with the rot_move() function.

See also
rot_move(), ROT_MOVE_UP, ROT_MOVE_LEFT, ROT_MOVE_CCW, ROT_MOVE_RIGHT, ROT_MOVE_CW
#define ROT_MOVE_LEFT   (1<<3)

A macro that returns the flag for the LEFT direction.

This macro defines the value of the LEFT direction which can be used with the rot_move function.

See also
rot_move(), ROT_MOVE_UP, ROT_MOVE_DOWN, ROT_MOVE_CCW, ROT_MOVE_RIGHT, ROT_MOVE_CW
#define ROT_MOVE_RIGHT   (1<<4)

A macro that returns the flag for the RIGHT direction.

This macro defines the value of the RIGHT direction which can be used with the rot_move() function.

See also
rot_move(), ROT_MOVE_UP, ROT_MOVE_DOWN, ROT_MOVE_LEFT, ROT_MOVE_CCW, ROT_MOVE_CW
#define ROT_MOVE_UP   (1<<1)

A macro that returns the flag for the UP direction.

This macro defines the value of the UP direction which can be used with the rot_move() function.

See also
rot_move(), ROT_MOVE_DOWN, ROT_MOVE_LEFT, ROT_MOVE_CCW, ROT_MOVE_RIGHT, ROT_MOVE_CW
#define ROT_RESET_ALL   1

A macro that returns the flag for the reset operation.

See also
rot_reset(), rot_reset_t

Typedef Documentation

typedef float azimuth_t

Type definition for azimuth.

The azimuth_t type is used as parameter for the rot_set_position() and rot_get_position() functions.

Unless specified otherwise, the unit of azimuth_t is decimal degrees.

typedef float elevation_t

Type definition for elevation.

The elevation_t type is used as parameter for the rot_set_position() and rot_get_position() functions.

Unless specified otherwise, the unit of elevation_t is decimal degrees.

typedef int rot_reset_t

Type definition for rotator reset.

The rot_reset_t type is used as parameter for the rot_reset() API function.

Enumeration Type Documentation

enum rot_type_t

Rotator type flags.

Enumerator
ROT_FLAG_AZIMUTH 

Azimuth

ROT_FLAG_ELEVATION 

Elevation

Function Documentation

int foreach_opened_rot ( int(*)(ROT *, char *)  cfunc,
char *  data 
)

execs cfunc() on each opened rot

Parameters
cfuncThe function to be executed on each rot
dataData pointer to be passed to cfunc()

Calls cfunc() function for each opened rot. The contents of the opened rot table is processed in random order according to a function pointed to by cfunc, whic is called with two arguments, the first pointing to the ROT handle, the second to a data pointer data. If data is not needed, then it can be set to NULL. The processing of the opened rot table is stopped when cfunc() returns 0.

int frontrot_get_conf ( ROT rot,
token_t  token,
char *  val 
)

Get data from rotator state in alpha form.

Parameters
rotnon-null
tokenTOK_... specifying which data to get
valresult non-null
Returns
RIG_OK or < 0 if error
int frontrot_set_conf ( ROT rot,
token_t  token,
const char *  val 
)

Set rotator state info from alpha input.

Parameters
rot
tokenTOK_... specifying which info to set
valinput
Returns
RIG_OK or < 0 error

assumes rot!=NULL, val!=NULL

int rot_cleanup ( ROT rot)

release a rot handle and free associated memory

Parameters
rotThe ROT handle of the radio to be closed

Releases a rot struct which port has eventualy been closed already with rot_close().

Returns
RIG_OK if the operation has been sucessful, otherwise a negative value if an error occured (in which case, cause is set appropriately).
See also
rot_init(), rot_close()
int rot_close ( ROT rot)

close the communication to the rot

Parameters
rotThe ROT handle of the rotator to be closed

Closes communication to a rotator which ROT handle has been passed by argument that was previously open with rot_open().

Returns
RIG_OK if the operation has been sucessful, otherwise a negative value if an error occured (in which case, cause is set appropriately).
See also
rot_cleanup(), rot_open()
const struct confparams* rot_confparam_lookup ( ROT rot,
const char *  name 
)

lookup conf token by its name, return pointer to confparams struct.

Parameters
rot
name
Returns
confparams or NULL

lookup backend config table first, then fall back to frontend. TODO: should use Lex to speed it up, strcmp hurts!

int rot_get_conf ( ROT rot,
token_t  token,
char *  val 
)

get the value of a configuration parameter

Parameters
rotThe rot handle
tokenThe parameter
valThe location where to store the value of config token

Retrieves the value of a configuration paramter associated with token.

Returns
RIG_OK if the operation has been sucessful, otherwise a negative value if an error occured (in which case, cause is set appropriately).
See also
rot_set_conf()
const char* rot_get_info ( ROT rot)

get general information from the rotator

Parameters
rotThe rot handle

Retrieves some general information from the rotator. This can include firmware revision, exact model name, or just nothing.

Returns
a pointer to static memory containing the ASCIIZ string if the operation has been sucessful, otherwise NULL if an error occured or get_info not part of capabilities.
int rot_get_position ( ROT rot,
azimuth_t azimuth,
elevation_t elevation 
)

get the azimuth and elevation of the rotator

Parameters
rotThe rot handle
azimuthThe location where to store the current azimuth
elevationThe location where to store the current elevation

Retrieves the current azimuth and elevation of the rotator.

Returns
RIG_OK if the operation has been sucessful, otherwise a negative value if an error occured (in which case, cause is set appropriately).
See also
rot_set_position()
ROT* rot_init ( rot_model_t  rot_model)

allocate a new ROT handle

Parameters
rot_modelThe rot model for this new handle

Allocates a new ROT handle and initializes the associated data for rot_model.

Returns
a pointer to the ROT handle otherwise NULL if memory allocation failed or rot_model is unknown (e.g. backend autoload failed).
See also
rot_cleanup(), rot_open()
int rot_move ( ROT rot,
int  direction,
int  speed 
)

move the rotator in the specified direction

Parameters
rotThe rot handle
directionDirection of movement
speedSpeed of movement

Move the rotator in the specified direction. The speed is a value between 1 and 100.

int rot_open ( ROT rot)

open the communication to the rot

Parameters
rotThe ROT handle of the rotator to be opened

Opens communication to a rotator which ROT handle has been passed by argument.

Returns
RIG_OK if the operation has been sucessful, otherwise a negative value if an error occured (in which case, cause is set appropriately).
Return values
RIG_EINVALrot is NULL or unconsistent.
RIG_ENIMPLport type communication is not implemented yet.
See also
rot_init(), rot_close()
int rot_park ( ROT rot)

park the antenna

Parameters
rotThe rot handle

Park the antenna.

Returns
RIG_OK if the operation has been sucessful, otherwise a negative value if an error occured (in which case, cause is set appropriately).
int rot_reset ( ROT rot,
rot_reset_t  reset 
)

reset the rotator

Parameters
rotThe rot handle
resetThe reset operation to perform

Resets the rotator.

Returns
RIG_OK if the operation has been sucessful, otherwise a negative value if an error occured (in which case, cause is set appropriately).
int rot_set_conf ( ROT rot,
token_t  token,
const char *  val 
)

set a rotator configuration parameter

Parameters
rotThe rot handle
tokenThe parameter
valThe value to set the parameter to

Sets a configuration parameter.

Returns
RIG_OK if the operation has been sucessful, otherwise a negative value if an error occured (in which case, cause is set appropriately).
See also
rot_get_conf()
int rot_set_position ( ROT rot,
azimuth_t  azimuth,
elevation_t  elevation 
)

set the azimuth and elevation of the rotator

Parameters
rotThe rot handle
azimuthThe azimuth to set to
elevationThe elevation to set to

Sets the azimuth and elevation of the rotator.

Returns
RIG_OK if the operation has been sucessful, otherwise a negative value if an error occured (in which case, cause is set appropriately).
See also
rot_get_position()
int rot_stop ( ROT rot)

stop the rotator

Parameters
rotThe rot handle

Stop the rotator.

Returns
RIG_OK if the operation has been sucessful, otherwise a negative value if an error occured (in which case, cause is set appropriately).
int rot_token_foreach ( ROT rot,
int(*)(const struct confparams *, char *)  cfunc,
char *  data 
)

Executes cfunc on all the elements stored in the conf table.

Parameters
rotnon-null
cfuncfunction(..)
datastart first with backend conf table, then finish with frontend table
token_t rot_token_lookup ( ROT rot,
const char *  name 
)

Simple lookup returning token id associated with name.

Parameters
rot
name
Returns
token enum

Generated by doxygen 1.8.8

Hamlib documentation for version 3.0.1 -- Wed Jan 13 2016 15:05:23
Project page: http://www.hamlib.org