rig.h File Reference

Hamlib rig data structures. More...

#include <stdio.h>
#include <stdarg.h>
#include <hamlib/riglist.h>
#include <hamlib/rig_dll.h>

Go to the source code of this file.

Data Structures

struct  confparams
 Configuration parameter structure. More...
union  value_t
 Universal approach for passing values. More...
struct  freq_range_list
 Frequency range. More...
struct  tuning_step_list
 Tuning step definition. More...
struct  filter_list
 Filter definition. More...
struct  ext_list
 Extension attribute definition. More...
struct  channel
 Channel structure. More...
struct  channel_cap
 Channel capability definition. More...
struct  chan_list
 Memory channel list definition. More...
struct  gran
 level/parm granularity definition More...
struct  cal_table
 Calibration table struct. More...
struct  rig_caps
 Rig data structure. More...
struct  hamlib_port_t
 Port definition. More...
struct  rig_state
 Rig state containing live data and customized fields. More...
struct  rig_callbacks
 Callback functions and args for rig event. More...
struct  rig
 The Rig structure. More...

Defines

#define NETRIGCTL_RET   "RPRT "
 Token in the netrigctl protocol for returning error code.
#define RIG_STATUS_NEW   RIG_STATUS_UNTESTED
 Map all deprecated RIG_STATUS_NEW references to RIG_STATUS_UNTESTED for backward compatibility.
#define PRIfreq   "f"
 printf(3) format to be used for freq_t type
#define SCNfreq   "lf"
 scanf(3) format to be used for freq_t type
#define RIG_VFO_NONE   0
 '' -- used in caps
#define RIG_VFO_CURR   (1<<29)
 currVFO -- current "tunable channel"/VFO
#define RIG_VFO_MEM   (1<<28)
 MEM -- means Memory mode, to be used with set_vfo
#define RIG_VFO_VFO   (1<<27)
 VFO -- means (last or any)VFO mode, with set_vfo
#define RIG_VFO_TX   RIG_VFO_TX_VFO(RIG_VFO_CURR)
 TX -- alias for split tx or uplink, of VFO_CURR
#define RIG_VFO_RX   RIG_VFO_CURR
 RX -- alias for split rx or downlink
#define RIG_VFO_MAIN   (1<<26)
 Main -- alias for MAIN
#define RIG_VFO_SUB   (1<<25)
 Sub -- alias for SUB
#define RIG_VFO_A   RIG_VFO_N(0)
 VFOA -- VFO A
#define RIG_VFO_B   RIG_VFO_N(1)
 VFOB -- VFO B
#define RIG_VFO_C   RIG_VFO_N(2)
 VFOC -- VFO C
#define RIG_MODE_SSB   (RIG_MODE_USB|RIG_MODE_LSB)
 macro for backends, not to be used by rig_set_mode et al.
#define RIG_MODE_ECSS   (RIG_MODE_ECSSUSB|RIG_MODE_ECSSLSB)
 macro for backends, not to be used by rig_set_mode et al.
#define RIG_CHFLAG_NONE   0
 Empty channel_t.flags field.
#define RIG_CHFLAG_SKIP   (1<<0)
 skip memory channel during scan (lock out), channel_t.flags
#define RIG_CHFLAG_DATA   (1<<1)
 DATA port mode flag.
#define RIG_MEM_CAPS_ALL   -1
 Special memory channel value to tell rig_lookup_mem_caps() to retrieve all the ranges.

Typedefs

typedef struct rig RIG
 Rig structure definition (see rig for details).
typedef unsigned int tone_t
 CTCSS and DCS type definition.
typedef enum rig_port_e rig_port_t
 Port type.
typedef double freq_t
 Frequency type, Frequency type unit in Hz, able to hold SHF frequencies.
typedef signed long shortfreq_t
 Short frequency type Frequency in Hz restricted to 31bits, suitable for offsets, shifts, etc..
typedef int vfo_t
 VFO definition.
typedef shortfreq_t pbwidth_t
 Passband width, in Hz.
typedef enum dcd_e dcd_t
 DCD status.
typedef long token_t
 configuration token
typedef int ant_t
 Antenna number.
typedef unsigned long setting_t
 Setting.
typedef struct freq_range_list freq_range_t
 Frequency range.
typedef struct channel channel_t
 Channel structure typedef.
typedef struct channel_cap channel_cap_t
 Channel cap.
typedef struct chan_list chan_t
 chan_t type
typedef struct gran gran_t
 gran_t type
typedef struct cal_table cal_table_t
 calibration table type

Enumerations

enum  rig_errcode_e {
  RIG_OK = 0, RIG_EINVAL, RIG_ECONF, RIG_ENOMEM,
  RIG_ENIMPL, RIG_ETIMEOUT, RIG_EIO, RIG_EINTERNAL,
  RIG_EPROTO, RIG_ERJCTED, RIG_ETRUNC, RIG_ENAVAIL,
  RIG_ENTARGET, RIG_BUSERROR, RIG_BUSBUSY, RIG_EARG,
  RIG_EVFO, RIG_EDOM
}
 

Hamlib error codes Error code definition that can be returned by the Hamlib functions. Unless stated otherwise, Hamlib functions return the negative value of rig_errcode_e definitions in case of error, or 0 when successful.

More...
enum  rig_debug_level_e {
  RIG_DEBUG_NONE = 0, RIG_DEBUG_BUG, RIG_DEBUG_ERR, RIG_DEBUG_WARN,
  RIG_DEBUG_VERBOSE, RIG_DEBUG_TRACE
}
 

Hamlib debug levels.

More...
enum  rig_port_e {
  RIG_PORT_NONE = 0, RIG_PORT_SERIAL, RIG_PORT_NETWORK, RIG_PORT_DEVICE,
  RIG_PORT_PACKET, RIG_PORT_DTMF, RIG_PORT_ULTRA, RIG_PORT_RPC,
  RIG_PORT_PARALLEL, RIG_PORT_USB
}
 

Port type.

More...
enum  serial_parity_e { RIG_PARITY_NONE = 0, RIG_PARITY_ODD, RIG_PARITY_EVEN }
 

Serial parity.

More...
enum  serial_handshake_e { RIG_HANDSHAKE_NONE = 0, RIG_HANDSHAKE_XONXOFF, RIG_HANDSHAKE_HARDWARE }
 

Serial handshake.

More...
enum  serial_control_state_e { RIG_SIGNAL_UNSET = 0, RIG_SIGNAL_ON, RIG_SIGNAL_OFF }
 

Serial control state.

More...
enum  rig_type_t {
  RIG_FLAG_RECEIVER = (1<<1), RIG_FLAG_TRANSMITTER = (1<<2), RIG_FLAG_SCANNER = (1<<3), RIG_FLAG_MOBILE = (1<<4),
  RIG_FLAG_HANDHELD = (1<<5), RIG_FLAG_COMPUTER = (1<<6), RIG_FLAG_TRUNKING = (1<<7), RIG_FLAG_APRS = (1<<8),
  RIG_FLAG_TNC = (1<<9), RIG_FLAG_DXCLUSTER = (1<<10), RIG_FLAG_TUNER = (1<<11)
}
 

Rig type flags.

More...
enum  rig_status_e {
  RIG_STATUS_ALPHA = 0, RIG_STATUS_UNTESTED, RIG_STATUS_BETA, RIG_STATUS_STABLE,
  RIG_STATUS_BUGGY
}
 

Development status of the backend.

More...
enum  rptr_shift_t { RIG_RPT_SHIFT_NONE = 0, RIG_RPT_SHIFT_MINUS, RIG_RPT_SHIFT_PLUS }
 

Repeater shift type.

More...
enum  split_t { RIG_SPLIT_OFF = 0, RIG_SPLIT_ON }
 

Split mode.

More...
enum  dcd_e { RIG_DCD_OFF = 0, RIG_DCD_ON }
 

DCD status.

More...
enum  dcd_type_t {
  RIG_DCD_NONE = 0, RIG_DCD_RIG, RIG_DCD_SERIAL_DSR, RIG_DCD_SERIAL_CTS,
  RIG_DCD_SERIAL_CAR, RIG_DCD_PARALLEL
}
 

DCD type.

More...
enum  ptt_t { RIG_PTT_OFF = 0, RIG_PTT_ON }
 

PTT status.

More...
enum  ptt_type_t {
  RIG_PTT_NONE = 0, RIG_PTT_RIG, RIG_PTT_SERIAL_DTR, RIG_PTT_SERIAL_RTS,
  RIG_PTT_PARALLEL
}
 

PTT type.

More...
enum  powerstat_t { RIG_POWER_OFF = 0, RIG_POWER_ON = (1<<0), RIG_POWER_STANDBY = (1<<1) }
 

Radio power state.

More...
enum  reset_t {
  RIG_RESET_NONE = 0, RIG_RESET_SOFT = (1<<0), RIG_RESET_VFO = (1<<1), RIG_RESET_MCALL = (1<<2),
  RIG_RESET_MASTER = (1<<3)
}
 

Reset operation.

More...
enum  vfo_op_t {
  RIG_OP_NONE = 0, RIG_OP_CPY = (1<<0), RIG_OP_XCHG = (1<<1), RIG_OP_FROM_VFO = (1<<2),
  RIG_OP_TO_VFO = (1<<3), RIG_OP_MCL = (1<<4), RIG_OP_UP = (1<<5), RIG_OP_DOWN = (1<<6),
  RIG_OP_BAND_UP = (1<<7), RIG_OP_BAND_DOWN = (1<<8), RIG_OP_LEFT = (1<<9), RIG_OP_RIGHT = (1<<10),
  RIG_OP_TUNE = (1<<11), RIG_OP_TOGGLE = (1<<12)
}
 

VFO operation.

More...
enum  scan_t {
  RIG_SCAN_NONE = 0, RIG_SCAN_STOP = RIG_SCAN_NONE, RIG_SCAN_MEM = (1<<0), RIG_SCAN_SLCT = (1<<1),
  RIG_SCAN_PRIO = (1<<2), RIG_SCAN_PROG = (1<<3), RIG_SCAN_DELTA = (1<<4), RIG_SCAN_VFO = (1<<5),
  RIG_SCAN_PLT = (1<<6)
}
 

Rig Scan operation.

More...
enum  rig_conf_e {
  RIG_CONF_STRING, RIG_CONF_COMBO, RIG_CONF_NUMERIC, RIG_CONF_CHECKBUTTON,
  RIG_CONF_BUTTON
}
 

parameter types

More...
enum  ann_t {
  RIG_ANN_NONE = 0, RIG_ANN_OFF = RIG_ANN_NONE, RIG_ANN_FREQ = (1<<0), RIG_ANN_RXMODE = (1<<1),
  RIG_ANN_CW = (1<<2), RIG_ANN_ENG = (1<<3), RIG_ANN_JAP = (1<<4)
}
 

Announce.

More...
enum  agc_level_e { , RIG_AGC_USER }
 

AGC delay settings.

More...
enum  meter_level_e
 

Level display meters.


enum  rig_level_e {
  RIG_LEVEL_NONE = 0, RIG_LEVEL_PREAMP = (1<<0), RIG_LEVEL_ATT = (1<<1), RIG_LEVEL_VOX = (1<<2),
  RIG_LEVEL_AF = (1<<3), RIG_LEVEL_RF = (1<<4), RIG_LEVEL_SQL = (1<<5), RIG_LEVEL_IF = (1<<6),
  RIG_LEVEL_APF = (1<<7), RIG_LEVEL_NR = (1<<8), RIG_LEVEL_PBT_IN = (1<<9), RIG_LEVEL_PBT_OUT = (1<<10),
  RIG_LEVEL_CWPITCH = (1<<11), RIG_LEVEL_RFPOWER = (1<<12), RIG_LEVEL_MICGAIN = (1<<13), RIG_LEVEL_KEYSPD = (1<<14),
  RIG_LEVEL_NOTCHF = (1<<15), RIG_LEVEL_COMP = (1<<16), RIG_LEVEL_AGC = (1<<17), RIG_LEVEL_BKINDL = (1<<18),
  RIG_LEVEL_BALANCE = (1<<19), RIG_LEVEL_METER = (1<<20), RIG_LEVEL_VOXGAIN = (1<<21), RIG_LEVEL_VOXDELAY = RIG_LEVEL_VOX,
  RIG_LEVEL_ANTIVOX = (1<<22), RIG_LEVEL_SLOPE_LOW = (1<<23), RIG_LEVEL_SLOPE_HIGH = (1<<24), RIG_LEVEL_BKIN_DLYMS = (1<<25),
  RIG_LEVEL_RAWSTR = (1<<26), RIG_LEVEL_SQLSTAT = (1<<27), RIG_LEVEL_SWR = (1<<28), RIG_LEVEL_ALC = (1<<29),
  RIG_LEVEL_STRENGTH = (1<<30)
}
 

Rig Level Settings.

More...
enum  rig_parm_e {
  RIG_PARM_NONE = 0, RIG_PARM_ANN = (1<<0), RIG_PARM_APO = (1<<1), RIG_PARM_BACKLIGHT = (1<<2),
  RIG_PARM_BEEP = (1<<4), RIG_PARM_TIME = (1<<5), RIG_PARM_BAT = (1<<6), RIG_PARM_KEYLIGHT = (1<<7)
}
 

Rig Parameters.

More...
enum  rig_func_e {
  RIG_FUNC_NONE = 0, RIG_FUNC_FAGC = (1<<0), RIG_FUNC_NB = (1<<1), RIG_FUNC_COMP = (1<<2),
  RIG_FUNC_VOX = (1<<3), RIG_FUNC_TONE = (1<<4), RIG_FUNC_TSQL = (1<<5), RIG_FUNC_SBKIN = (1<<6),
  RIG_FUNC_FBKIN = (1<<7), RIG_FUNC_ANF = (1<<8), RIG_FUNC_NR = (1<<9), RIG_FUNC_AIP = (1<<10),
  RIG_FUNC_APF = (1<<11), RIG_FUNC_MON = (1<<12), RIG_FUNC_MN = (1<<13), RIG_FUNC_RF = (1<<14),
  RIG_FUNC_ARO = (1<<15), RIG_FUNC_LOCK = (1<<16), RIG_FUNC_MUTE = (1<<17), RIG_FUNC_VSC = (1<<18),
  RIG_FUNC_REV = (1<<19), RIG_FUNC_SQL = (1<<20), RIG_FUNC_ABM = (1<<21), RIG_FUNC_BC = (1<<22),
  RIG_FUNC_MBC = (1<<23), RIG_FUNC_AFC = (1<<25), RIG_FUNC_SATMODE = (1<<26), RIG_FUNC_SCOPE = (1<<27),
  RIG_FUNC_RESUME = (1<<28), RIG_FUNC_TBURST = (1<<29), RIG_FUNC_TUNER = (1<<30)
}
 

Rig Function Settings.

More...
enum  rmode_t {
  RIG_MODE_NONE = 0, RIG_MODE_AM = (1<<0), RIG_MODE_CW = (1<<1), RIG_MODE_USB = (1<<2),
  RIG_MODE_LSB = (1<<3), RIG_MODE_RTTY = (1<<4), RIG_MODE_FM = (1<<5), RIG_MODE_WFM = (1<<6),
  RIG_MODE_CWR = (1<<7), RIG_MODE_RTTYR = (1<<8), RIG_MODE_AMS = (1<<9), RIG_MODE_PKTLSB = (1<<10),
  RIG_MODE_PKTUSB = (1<<11), RIG_MODE_PKTFM = (1<<12), RIG_MODE_ECSSUSB = (1<<13), RIG_MODE_ECSSLSB = (1<<14),
  RIG_MODE_FAX = (1<<15), RIG_MODE_SAM = (1<<16), RIG_MODE_SAL = (1<<17), RIG_MODE_SAH = (1<<18),
  RIG_MODE_DSB = (1<<19), RIG_MODE_TESTS_MAX
}
 

Radio mode.

More...
enum  chan_type_t {
  RIG_MTYPE_NONE = 0, RIG_MTYPE_MEM, RIG_MTYPE_EDGE, RIG_MTYPE_CALL,
  RIG_MTYPE_MEMOPAD, RIG_MTYPE_SAT, RIG_MTYPE_BAND, RIG_MTYPE_PRIO
}
 

Memory channel type definition.

More...

Detailed Description

Hamlib rig data structures.

This file contains the data structures and definitions for the Hamlib rig API. see the rig.c file for more details on the rig API.

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines

Hamlib documentation for version 1.2.10 -- Sun May 9 11:40:19 2010
Project page: http://hamlib.org