From ece8eda70d41c626d9f4823765cdc642bb798b59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Fillod=2C=20F8CFE?= Date: Fri, 5 Jan 2001 18:21:39 +0000 Subject: [PATCH] * added targetable_vfo field in caps git-svn-id: https://hamlib.svn.sourceforge.net/svnroot/hamlib/trunk@316 7ae35d74-ebe9-4afe-98af-79ac388436b8 --- aor/ar8200.c | 4 ++-- icom/ic706.c | 14 ++++++++++---- include/hamlib/rig.h | 5 ++++- kenwood/ts870s.c | 6 +++--- 4 files changed, 19 insertions(+), 10 deletions(-) diff --git a/aor/ar8200.c b/aor/ar8200.c index 08fe9095a..1132d3496 100644 --- a/aor/ar8200.c +++ b/aor/ar8200.c @@ -7,7 +7,7 @@ * using the serial interface. * * - * $Id: ar8200.c,v 1.1 2000-11-01 23:23:56 f4cfe Exp $ + * $Id: ar8200.c,v 1.2 2001-01-05 18:18:17 f4cfe Exp $ * * * @@ -56,7 +56,7 @@ const struct rig_caps ar8200_caps = { RIG_MODEL_AR8200, "AR8200", "AOR", "0.1", RIG_STATUS_UNTESTED, RIG_TYPE_SCANNER, RIG_PTT_NONE, 9600, 19200, 8, 2, RIG_PARITY_NONE, RIG_HANDSHAKE_XONXOFF, 0, 0, 2000, 3, AR8200_FUNC_ALL, AR8200_LEVEL_ALL, - AR8200_LEVEL_ALL, 1000, RIG_TRN_ON, + AR8200_LEVEL_ALL, 0, 1000, RIG_TRN_ON, { {KHz(100),MHz(2040),AR8200_ALL_MODES,-1,-1}, {0,0,0,0,0}, diff --git a/icom/ic706.c b/icom/ic706.c index 8652583dc..2c33bf41c 100644 --- a/icom/ic706.c +++ b/icom/ic706.c @@ -7,7 +7,7 @@ * using the "CI-V" interface. * * - * $Id: ic706.c,v 1.8 2000-11-28 22:26:20 f4cfe Exp $ + * $Id: ic706.c,v 1.9 2001-01-05 18:18:50 f4cfe Exp $ * * * @@ -64,7 +64,7 @@ const struct rig_caps ic706_caps = { RIG_MODEL_IC706, "IC-706", "Icom", "0.2", RIG_STATUS_ALPHA, RIG_TYPE_MOBILE, RIG_PTT_NONE, 300, 19200, 8, 1, RIG_PARITY_NONE, RIG_HANDSHAKE_NONE, 0, 0, 2000, 3, IC706_FUNC_ALL, IC706_LEVEL_ALL, - IC706_LEVEL_ALL, 101, RIG_TRN_ON, + IC706_LEVEL_ALL, 0, 101, RIG_TRN_ON, { {KHz(30),199999999,IC706_ALL_RX_MODES,-1,-1},{0,0,0,0,0}, }, /* rx range */ { {KHz(1800),1999999,IC706_OTHER_TX_MODES,5000,100000}, /* 100W class */ {KHz(1800),1999999,IC706_AM_TX_MODES,2000,40000}, /* 40W class */ @@ -111,7 +111,7 @@ const struct rig_caps ic706mkii_caps = { RIG_MODEL_IC706MKII, "IC-706MKII", "Icom", "0.2", RIG_STATUS_ALPHA, RIG_TYPE_MOBILE, RIG_PTT_NONE, 300, 19200, 8, 1, RIG_PARITY_NONE, RIG_HANDSHAKE_NONE, 0, 0, 2000, 3, IC706_FUNC_ALL, IC706_LEVEL_ALL, - IC706_LEVEL_ALL, 101, RIG_TRN_ON, + IC706_LEVEL_ALL, 0, 101, RIG_TRN_ON, { {30000,199999999,IC706_ALL_RX_MODES,-1,-1}, {0,0,0,0,0}, }, /* rx range */ { {1800000,1999999,IC706_OTHER_TX_MODES,5000,100000}, /* 100W class */ {1800000,1999999,IC706_AM_TX_MODES,2000,40000}, /* 40W class */ @@ -163,7 +163,7 @@ const struct rig_caps ic706mkiig_caps = { RIG_MODEL_IC706MKIIG, "IC-706MKIIG", "Icom", "0.2", RIG_STATUS_ALPHA, RIG_TYPE_MOBILE, RIG_PTT_NONE, 300, 19200, 8, 1, RIG_PARITY_NONE, RIG_HANDSHAKE_NONE, 0, 0, 2000, 3, IC706_FUNC_ALL|RIG_FUNC_NR|RIG_FUNC_ANF, - IC706_LEVEL_ALL, IC706_LEVEL_ALL, 101, RIG_TRN_ON, + IC706_LEVEL_ALL, IC706_LEVEL_ALL, 0, 101, RIG_TRN_ON, { {30000,199999999,IC706_ALL_RX_MODES,-1,-1}, /* this trx also has UHF */ {400000000,470000000,IC706_ALL_RX_MODES,-1,-1}, {0,0,0,0,0}, }, { {1800000,1999999,IC706_OTHER_TX_MODES,5000,100000}, /* 100W class */ @@ -208,6 +208,12 @@ const struct rig_caps ic706mkiig_caps = { icom_init, icom_cleanup, NULL, NULL, NULL /* probe not supported yet */, icom_set_freq, icom_get_freq, icom_set_mode, icom_get_mode, icom_set_vfo, NULL, + /* + * FIXME: + * the use of the following GNU extension (field: value) + * is bad manner in portable code but admit it, quite handy + * when testing stuff. --SF + */ decode_event: icom_decode_event, set_level: icom_set_level, get_level: icom_get_level, diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index 1ac55fc0e..3d934422b 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -5,7 +5,7 @@ * will be used for obtaining rig capabilities. * * - * $Id: rig.h,v 1.11 2000-12-05 22:01:03 f4cfe Exp $ * + * $Id: rig.h,v 1.12 2001-01-05 18:21:39 f4cfe Exp $ * * * * This program is free software; you can redistribute it and/or @@ -46,6 +46,7 @@ #define RIG_ERJCTED 9 /* Command rejected by the rig */ #define RIG_ETRUNC 10 /* Command performed, but arg truncated */ #define RIG_ENAVAIL 11 /* function not available */ +#define RIG_ENTARGET 12 /* VFO not targetable */ /* Forward struct references */ @@ -394,6 +395,7 @@ struct rig_caps { setting_t has_func; /* bitwise OR'ed RIG_FUNC_FAGC, NG, etc. */ setting_t has_level; /* bitwise OR'ed RIG_LEVEL_* */ setting_t has_set_level; /* bitwise OR'ed RIG_LEVEL_* */ + int targetable_vfo; int chan_qty; /* number of channels */ #if 0 int chan_desc_sz; /* memory channel size, 0 if none */ @@ -530,6 +532,7 @@ struct rig_state { FILE *stream; /* serial port/socket (buffered) stream handle */ int transceive; /* wether the transceive mode is on */ int hold_decode;/* set to 1 to hold the event decoder (async) otherwise 0 */ + int current_vfo; /* * Pointer to private data * tuff like CI_V_address for Icom goes in this *priv 51 area diff --git a/kenwood/ts870s.c b/kenwood/ts870s.c index c6d495e5c..b7dce20c1 100644 --- a/kenwood/ts870s.c +++ b/kenwood/ts870s.c @@ -7,7 +7,7 @@ * using the serial interface. * * - * $Id: ts870s.c,v 1.1 2000-12-23 08:40:14 f4cfe Exp $ + * $Id: ts870s.c,v 1.2 2001-01-05 18:20:50 f4cfe Exp $ * * * @@ -56,12 +56,12 @@ const struct rig_caps ts870s_caps = { RIG_MODEL_TS870S, "TS-870S", "Kenwood", "0.1", RIG_STATUS_UNTESTED, RIG_TYPE_TRANSCEIVER, RIG_PTT_RIG, 1200, 57600, 8, 1, RIG_PARITY_NONE, RIG_HANDSHAKE_NONE, 0, 0, 2000, 3, TS870S_FUNC_ALL, TS870S_LEVEL_ALL, - TS870S_LEVEL_ALL, 1000, RIG_TRN_ON, + TS870S_LEVEL_ALL, 0, 1000, RIG_TRN_ON, { {KHz(100),MHz(2040),TS870S_ALL_MODES,-1,-1}, {0,0,0,0,0}, }, /* rx range */ - { {0,0,0,0,0} }, /* no tx range, this is a scanner! */ + { {0,0,0,0,0} }, /* FIXME: no tx range yet! */ { {TS870S_ALL_MODES,50}, {TS870S_ALL_MODES,100},