diff --git a/alinco/alinco.c b/alinco/alinco.c index 01e788726..57512cb9e 100644 --- a/alinco/alinco.c +++ b/alinco/alinco.c @@ -1,8 +1,8 @@ /* * Hamlib Alinco backend - main file - * Copyright (c) 2001,2002 by Stephane Fillod + * Copyright (c) 2001-2003 by Stephane Fillod * - * $Id: alinco.c,v 1.13 2002-03-13 23:37:12 fillods Exp $ + * $Id: alinco.c,v 1.14 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -332,7 +332,7 @@ int alinco_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width) * alinco_set_split * Assumes rig!=NULL */ -int alinco_set_split(RIG *rig, vfo_t vfo, split_t split) +int alinco_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo) { int cmd_len; char cmdbuf[BUFSZ]; @@ -347,7 +347,7 @@ int alinco_set_split(RIG *rig, vfo_t vfo, split_t split) * alinco_get_split * Assumes rig!=NULL, split!=NULL */ -int alinco_get_split(RIG *rig, vfo_t vfo, split_t *split) +int alinco_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo) { int splt_len, retval; char spltbuf[BUFSZ]; diff --git a/alinco/alinco.h b/alinco/alinco.h index 97c3acf30..915a5a136 100644 --- a/alinco/alinco.h +++ b/alinco/alinco.h @@ -1,8 +1,8 @@ /* * Hamlib Alinco backend - main header - * Copyright (c) 2001,2002 by Stephane Fillod + * Copyright (c) 2001-2003 by Stephane Fillod * - * $Id: alinco.h,v 1.10 2001-12-28 20:28:02 fillods Exp $ + * $Id: alinco.h,v 1.11 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -37,8 +37,8 @@ int alinco_set_freq(RIG *rig, vfo_t vfo, freq_t freq); int alinco_get_freq(RIG *rig, vfo_t vfo, freq_t *freq); int alinco_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width); int alinco_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width); -int alinco_set_split(RIG *rig, vfo_t vfo, split_t split); -int alinco_get_split(RIG *rig, vfo_t vfo, split_t *split); +int alinco_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo); +int alinco_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo); int alinco_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq); int alinco_get_split_freq(RIG *rig, vfo_t vfo, freq_t *tx_freq); int alinco_set_func(RIG *rig, vfo_t vfo, setting_t func, int status); diff --git a/alinco/dx77.c b/alinco/dx77.c index 32ccf8a58..8f1787e62 100644 --- a/alinco/dx77.c +++ b/alinco/dx77.c @@ -1,8 +1,8 @@ /* * Hamlib Alinco backend - DX77 description - * Copyright (c) 2001,2002 by Stephane Fillod + * Copyright (c) 2001-2003 by Stephane Fillod * - * $Id: dx77.c,v 1.5 2002-11-04 22:40:54 fillods Exp $ + * $Id: dx77.c,v 1.6 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -169,8 +169,8 @@ const struct rig_caps dx77_caps = { .get_mode = alinco_get_mode, .set_vfo = alinco_set_vfo, .get_vfo = alinco_get_vfo, -.set_split = alinco_set_split, -.get_split = alinco_get_split, +.set_split_vfo = alinco_set_split_vfo, +.get_split_vfo = alinco_get_split_vfo, .set_split_freq = alinco_set_split_freq, .get_split_freq = alinco_get_split_freq, .set_ctcss_tone = alinco_set_ctcss_tone, diff --git a/c++/rigclass.cc b/c++/rigclass.cc index 61f77b7e1..55dfba9e3 100644 --- a/c++/rigclass.cc +++ b/c++/rigclass.cc @@ -2,16 +2,16 @@ * \file src/rigclass.cc * \brief Ham Radio Control Libraries C++ interface * \author Stephane Fillod - * \date 2001 + * \date 2001-2003 * * Hamlib C++ interface is a frontend implementing wrapper functions. */ /* * Hamlib C++ bindings - main file - * Copyright (c) 2001-2002 by Stephane Fillod + * Copyright (c) 2001-2003 by Stephane Fillod * - * $Id: rigclass.cc,v 1.10 2002-09-22 11:41:49 fillods Exp $ + * $Id: rigclass.cc,v 1.11 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -312,14 +312,14 @@ rmode_t Rig::getSplitMode(pbwidth_t& width, vfo_t vfo) { return mode; } -void Rig::setSplit(split_t split, vfo_t vfo) { - CHECK_RIG(rig_set_split(theRig, vfo, split)); +void Rig::setSplitVFO(split_t split, vfo_t vfo, vfo_t tx_vfo) { + CHECK_RIG(rig_set_split_vfo(theRig, vfo, split, tx_vfo)); } -split_t Rig::getSplit(vfo_t vfo) { +split_t Rig::getSplitVFO(vfo_t &tx_vfo, vfo_t vfo) { split_t split; - CHECK_RIG( rig_get_split(theRig, vfo, &split) ); + CHECK_RIG( rig_get_split_vfo(theRig, vfo, &split, &tx_vfo) ); return split; } @@ -661,37 +661,37 @@ powerstat_t Rig::getPowerStat (void) rmode_t Rig::RngRxModes (freq_t freq) { - rmode_t modes = RIG_MODE_NONE; + unsigned modes = RIG_MODE_NONE; freq_range_t *rng; int i; for (i=0; istate.rx_range_list[i]; if (RIG_IS_FRNG_END(*rng)) { - return modes; + return (rmode_t)modes; } if (freq >= rng->start && freq <= rng->end) - modes |= rng->modes; + modes |= (unsigned)rng->modes; } - return modes; + return (rmode_t)modes; } rmode_t Rig::RngTxModes (freq_t freq) { - rmode_t modes = RIG_MODE_NONE; + unsigned modes = RIG_MODE_NONE; freq_range_t *rng; int i; for (i=0; istate.tx_range_list[i]; if (RIG_IS_FRNG_END(*rng)) { - return modes; + return (rmode_t)modes; } if (freq >= rng->start && freq <= rng->end) - modes |= rng->modes; + modes |= (unsigned)rng->modes; } - return modes; + return (rmode_t)modes; } diff --git a/dummy/dummy.c b/dummy/dummy.c index 497e36636..38629c2a1 100644 --- a/dummy/dummy.c +++ b/dummy/dummy.c @@ -1,8 +1,8 @@ /* * Hamlib Dummy backend - main file - * Copyright (c) 2001,2002 by Stephane Fillod + * Copyright (c) 2001-2003 by Stephane Fillod * - * $Id: dummy.c,v 1.31 2003-02-23 22:43:01 fillods Exp $ + * $Id: dummy.c,v 1.32 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -480,7 +480,7 @@ static int dummy_get_split_mode(RIG *rig, vfo_t vfo, rmode_t *tx_mode, pbwidth_t return RIG_OK; } -static int dummy_set_split(RIG *rig, vfo_t vfo, split_t split) +static int dummy_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo) { struct dummy_priv_data *priv = (struct dummy_priv_data *)rig->state.priv; channel_t *curr = priv->curr; @@ -492,7 +492,7 @@ static int dummy_set_split(RIG *rig, vfo_t vfo, split_t split) } -static int dummy_get_split(RIG *rig, vfo_t vfo, split_t *split) +static int dummy_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo) { struct dummy_priv_data *priv = (struct dummy_priv_data *)rig->state.priv; channel_t *curr = priv->curr; @@ -1117,8 +1117,8 @@ const struct rig_caps dummy_caps = { .get_split_freq = dummy_get_split_freq, .set_split_mode = dummy_set_split_mode, .get_split_mode = dummy_get_split_mode, - .set_split = dummy_set_split, - .get_split = dummy_get_split, + .set_split_vfo = dummy_set_split_vfo, + .get_split_vfo = dummy_get_split_vfo, .set_rit = dummy_set_rit, .get_rit = dummy_get_rit, .set_xit = dummy_set_xit, diff --git a/icom/ic706.c b/icom/ic706.c index 94010bd68..6b95df632 100644 --- a/icom/ic706.c +++ b/icom/ic706.c @@ -1,8 +1,8 @@ /* * Hamlib CI-V backend - description of IC-706 and variations - * Copyright (c) 2000-2002 by Stephane Fillod + * Copyright (c) 2000-2003 by Stephane Fillod * - * $Id: ic706.c,v 1.30 2002-11-04 22:40:54 fillods Exp $ + * $Id: ic706.c,v 1.31 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -224,7 +224,7 @@ const struct rig_caps ic706_caps = { .get_split_freq = icom_get_split_freq, .set_split_mode = icom_set_split_mode, .get_split_mode = icom_get_split_mode, -.set_split = icom_set_split, +.set_split_vfo = icom_set_split_vfo, }; @@ -358,7 +358,7 @@ const struct rig_caps ic706mkii_caps = { .get_split_freq = icom_get_split_freq, .set_split_mode = icom_set_split_mode, .get_split_mode = icom_get_split_mode, -.set_split = icom_set_split, +.set_split_vfo = icom_set_split_vfo, }; @@ -516,7 +516,7 @@ const struct rig_caps ic706mkiig_caps = { .get_split_freq = icom_get_split_freq, .set_split_mode = icom_set_split_mode, .get_split_mode = icom_get_split_mode, -.set_split = icom_set_split, +.set_split_vfo = icom_set_split_vfo, }; diff --git a/icom/ic718.c b/icom/ic718.c index 05b29d5ed..6a3721d24 100644 --- a/icom/ic718.c +++ b/icom/ic718.c @@ -1,9 +1,9 @@ /* * Hamlib CI-V backend - description of IC-718 caps - * Copyright (c) 2000-2002 by Stephane Fillod + * Copyright (c) 2000-2003 by Stephane Fillod * Caps submitted by Chuck Gilkes WD0FCL/4 * - * $Id: ic718.c,v 1.3 2002-11-04 22:40:54 fillods Exp $ + * $Id: ic718.c,v 1.4 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -194,8 +194,8 @@ const struct rig_caps ic718_caps = { .get_split_freq = icom_get_split_freq, .set_split_mode = icom_set_split_mode, .get_split_mode = icom_get_split_mode, -.set_split = icom_set_split, -.get_split = icom_get_split, +.set_split_vfo = icom_set_split_vfo, +.get_split_vfo = icom_get_split_vfo, }; diff --git a/icom/ic725.c b/icom/ic725.c index 22e0d7cc2..36229744b 100644 --- a/icom/ic725.c +++ b/icom/ic725.c @@ -1,8 +1,8 @@ /* * Hamlib CI-V backend - description of IC-725 and variations - * Copyright (c) 2000-2002 by Stephane Fillod + * Copyright (c) 2000-2003 by Stephane Fillod * - * $Id: ic725.c,v 1.2 2002-12-26 11:43:20 fillods Exp $ + * $Id: ic725.c,v 1.3 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -145,7 +145,7 @@ const struct rig_caps ic725_caps = { .set_mode = icom_set_mode, .get_mode = icom_get_mode, .set_vfo = icom_set_vfo, -.set_split = icom_set_split, +.set_split_vfo = icom_set_split_vfo, .set_split_freq = icom_set_split_freq, .get_split_freq = icom_get_split_freq, .set_split_mode = icom_set_split_mode, diff --git a/icom/ic736.c b/icom/ic736.c index e785286f5..71fa29af3 100644 --- a/icom/ic736.c +++ b/icom/ic736.c @@ -2,7 +2,7 @@ * Hamlib CI-V backend - description of IC-736 and variations * Copyright (c) 2000-2003 by Stephane Fillod * - * $Id: ic736.c,v 1.1 2003-02-19 23:56:56 fillods Exp $ + * $Id: ic736.c,v 1.2 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -182,7 +182,7 @@ const struct rig_caps ic736_caps = { .get_split_freq = icom_get_split_freq, .set_split_mode = icom_set_split_mode, .get_split_mode = icom_get_split_mode, -.set_split = icom_set_split, +.set_split_vfo = icom_set_split_vfo, }; diff --git a/icom/ic737.c b/icom/ic737.c index 88d516be3..18ad3036a 100644 --- a/icom/ic737.c +++ b/icom/ic737.c @@ -1,8 +1,8 @@ /* * Hamlib CI-V backend - description of IC-737 and variations - * Copyright (c) 2000-2002 by Stephane Fillod + * Copyright (c) 2000-2003 by Stephane Fillod * - * $Id: ic737.c,v 1.1 2002-11-16 14:05:53 fillods Exp $ + * $Id: ic737.c,v 1.2 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -176,7 +176,7 @@ const struct rig_caps ic737_caps = { .get_split_freq = icom_get_split_freq, .set_split_mode = icom_set_split_mode, .get_split_mode = icom_get_split_mode, -.set_split = icom_set_split, +.set_split_vfo = icom_set_split_vfo, }; diff --git a/icom/ic756.c b/icom/ic756.c index d01ea3406..8869899af 100644 --- a/icom/ic756.c +++ b/icom/ic756.c @@ -1,8 +1,8 @@ /* * Hamlib CI-V backend - description of IC-756 and variations - * Copyright (c) 2000-2002 by Stephane Fillod + * Copyright (c) 2000-2003 by Stephane Fillod * - * $Id: ic756.c,v 1.6 2002-11-04 22:40:54 fillods Exp $ + * $Id: ic756.c,v 1.7 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -214,8 +214,8 @@ const struct rig_caps ic756_caps = { .get_split_freq = icom_get_split_freq, .set_split_mode = icom_set_split_mode, .get_split_mode = icom_get_split_mode, -.set_split = icom_set_split, -.get_split = icom_get_split, +.set_split_vfo = icom_set_split_vfo, +.get_split_vfo = icom_get_split_vfo, }; @@ -368,8 +368,8 @@ const struct rig_caps ic756pro_caps = { .get_split_freq = icom_get_split_freq, .set_split_mode = icom_set_split_mode, .get_split_mode = icom_get_split_mode, -.set_split = icom_set_split, -.get_split = icom_get_split, +.set_split_vfo = icom_set_split_vfo, +.get_split_vfo = icom_get_split_vfo, }; @@ -557,8 +557,8 @@ const struct rig_caps ic756pro2_caps = { .get_split_freq = icom_get_split_freq, .set_split_mode = icom_set_split_mode, .get_split_mode = icom_get_split_mode, -.set_split = icom_set_split, -.get_split = icom_get_split, +.set_split_vfo = icom_set_split_vfo, +.get_split_vfo = icom_get_split_vfo, .set_ext_parm = ic756pro2_set_ext_parm, .get_ext_parm = ic756pro2_get_ext_parm, diff --git a/icom/icom.c b/icom/icom.c index 09bb84451..8ba9896df 100644 --- a/icom/icom.c +++ b/icom/icom.c @@ -2,7 +2,7 @@ * Hamlib CI-V backend - main file * Copyright (c) 2000-2003 by Stephane Fillod * - * $Id: icom.c,v 1.72 2003-03-10 08:26:08 fillods Exp $ + * $Id: icom.c,v 1.73 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -1362,7 +1362,7 @@ int icom_get_split_mode(RIG *rig, vfo_t vfo, rmode_t *tx_mode, pbwidth_t *tx_wid * icom_set_split * Assumes rig!=NULL, rig->state.priv!=NULL */ -int icom_set_split(RIG *rig, vfo_t vfo, split_t split) +int icom_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo) { struct icom_priv_data *priv; struct rig_state *rs; @@ -1404,7 +1404,7 @@ int icom_set_split(RIG *rig, vfo_t vfo, split_t split) * icom_get_split * Assumes rig!=NULL, rig->state.priv!=NULL, split!=NULL */ -int icom_get_split(RIG *rig, vfo_t vfo, split_t *split) +int icom_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo) { struct icom_priv_data *priv; struct rig_state *rs; diff --git a/icom/icom.h b/icom/icom.h index 5aa8931af..2addff9b3 100644 --- a/icom/icom.h +++ b/icom/icom.h @@ -1,8 +1,8 @@ /* * Hamlib CI-V backend - main header - * Copyright (c) 2000-2002 by Stephane Fillod + * Copyright (c) 2000-2003 by Stephane Fillod * - * $Id: icom.h,v 1.53 2003-03-10 08:26:08 fillods Exp $ + * $Id: icom.h,v 1.54 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -110,8 +110,8 @@ int icom_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq); int icom_get_split_freq(RIG *rig, vfo_t vfo, freq_t *tx_freq); int icom_set_split_mode(RIG *rig, vfo_t vfo, rmode_t tx_mode, pbwidth_t tx_width); int icom_get_split_mode(RIG *rig, vfo_t vfo, rmode_t *tx_mode, pbwidth_t *tx_width); -int icom_set_split(RIG *rig, vfo_t vfo, split_t split); -int icom_get_split(RIG *rig, vfo_t vfo, split_t *split); +int icom_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo); +int icom_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo); int icom_set_ts(RIG *rig, vfo_t vfo, shortfreq_t ts); int icom_get_ts(RIG *rig, vfo_t vfo, shortfreq_t *ts); int icom_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt); diff --git a/include/hamlib/rig.h b/include/hamlib/rig.h index ec25c61d5..e416e7a2c 100644 --- a/include/hamlib/rig.h +++ b/include/hamlib/rig.h @@ -2,7 +2,7 @@ * Hamlib Interface - API header * Copyright (c) 2000-2003 by Stephane Fillod and Frank Singleton * - * $Id: rig.h,v 1.77 2003-03-24 23:06:26 fillods Exp $ + * $Id: rig.h,v 1.78 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -818,6 +818,8 @@ struct channel { pbwidth_t tx_width; /*!< Transmit passband width associated with mode */ split_t split; /*!< Split mode */ + vfo_t tx_vfo; /*!< Split transmit VFO */ + rptr_shift_t rptr_shift; /*!< Repeater shift */ shortfreq_t rptr_offs; /*!< Repeater offset */ shortfreq_t tuning_step; /*!< Tuning step */ @@ -855,6 +857,7 @@ struct channel_cap { unsigned tx_width:1; /*!< Transmit passband width associated with mode */ unsigned split:1; /*!< Split mode */ + unsigned tx_vfo:1; /*!< Split transmit VFO */ unsigned rptr_shift:1; /*!< Repeater shift */ unsigned rptr_offs:1; /*!< Repeater offset */ unsigned tuning_step:1; /*!< Tuning step */ @@ -1058,8 +1061,8 @@ struct rig_caps { int (*get_split_mode) (RIG * rig, vfo_t vfo, rmode_t * tx_mode, pbwidth_t * tx_width); - int (*set_split) (RIG * rig, vfo_t vfo, split_t split); - int (*get_split) (RIG * rig, vfo_t vfo, split_t * split); + int (*set_split_vfo) (RIG * rig, vfo_t vfo, split_t split, vfo_t tx_vfo); + int (*get_split_vfo) (RIG * rig, vfo_t vfo, split_t * split, vfo_t *tx_vfo); int (*set_rit) (RIG * rig, vfo_t vfo, shortfreq_t rit); int (*get_rit) (RIG * rig, vfo_t vfo, shortfreq_t * rit); @@ -1343,8 +1346,10 @@ extern HAMLIB_EXPORT(int) rig_set_split_freq HAMLIB_PARAMS((RIG *rig, vfo_t vfo, extern HAMLIB_EXPORT(int) rig_get_split_freq HAMLIB_PARAMS((RIG *rig, vfo_t vfo, freq_t *tx_freq)); extern HAMLIB_EXPORT(int) rig_set_split_mode HAMLIB_PARAMS((RIG *rig, vfo_t vfo, rmode_t tx_mode, pbwidth_t tx_width)); extern HAMLIB_EXPORT(int) rig_get_split_mode HAMLIB_PARAMS((RIG *rig, vfo_t vfo, rmode_t *tx_mode, pbwidth_t *tx_width)); -extern HAMLIB_EXPORT(int) rig_set_split HAMLIB_PARAMS((RIG *rig, vfo_t vfo, split_t split)); -extern HAMLIB_EXPORT(int) rig_get_split HAMLIB_PARAMS((RIG *rig, vfo_t vfo, split_t *split)); +extern HAMLIB_EXPORT(int) rig_set_split_vfo HAMLIB_PARAMS((RIG*, vfo_t rx_vfo, split_t split, vfo_t tx_vfo)); +extern HAMLIB_EXPORT(int) rig_get_split_vfo HAMLIB_PARAMS((RIG*, vfo_t rx_vfo, split_t *split, vfo_t *tx_vfo)); +#define rig_set_split(r,v,s) rig_set_split_vfo((r),(v),(s),RIG_VFO_CURR) +#define rig_get_split(r,v,s) ({ vfo_t _tx_vfo; rig_get_split_vfo((r),(v),(s),&_tx_vfo); }) extern HAMLIB_EXPORT(int) rig_set_rit HAMLIB_PARAMS((RIG *rig, vfo_t vfo, shortfreq_t rit)); extern HAMLIB_EXPORT(int) rig_get_rit HAMLIB_PARAMS((RIG *rig, vfo_t vfo, shortfreq_t *rit)); diff --git a/include/hamlib/rigclass.h b/include/hamlib/rigclass.h index c6bbebc4b..9abedef72 100644 --- a/include/hamlib/rigclass.h +++ b/include/hamlib/rigclass.h @@ -2,7 +2,7 @@ * Hamlib C++ bindings - API header * Copyright (c) 2001-2002 by Stephane Fillod * - * $Id: rigclass.h,v 1.12 2002-11-14 19:27:35 fillods Exp $ + * $Id: rigclass.h,v 1.13 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -134,8 +134,8 @@ public: freq_t getSplitFreq (vfo_t vfo = RIG_VFO_CURR); void setSplitMode(rmode_t, pbwidth_t width = RIG_PASSBAND_NORMAL, vfo_t vfo = RIG_VFO_CURR); rmode_t getSplitMode(pbwidth_t&, vfo_t vfo = RIG_VFO_CURR); - void setSplit(split_t split, vfo_t vfo = RIG_VFO_CURR); - split_t getSplit(vfo_t vfo = RIG_VFO_CURR); + void setSplitVFO(split_t split, vfo_t vfo = RIG_VFO_CURR, vfo_t tx_vfo = RIG_VFO_CURR); + split_t getSplitVFO(vfo_t &tx_vfo, vfo_t vfo = RIG_VFO_CURR); void setRit (shortfreq_t rit, vfo_t vfo = RIG_VFO_CURR); shortfreq_t getRit (vfo_t vfo = RIG_VFO_CURR); diff --git a/rpcrig/rpcrig.x b/rpcrig/rpcrig.x index 9ded9f896..9995656bb 100644 --- a/rpcrig/rpcrig.x +++ b/rpcrig/rpcrig.x @@ -2,7 +2,7 @@ % * Hamlib Interface - RPC definitions % * Copyright (c) 2000-2002 by Stephane Fillod and Frank Singleton % * -% * $Id: rpcrig.x,v 1.5 2002-09-13 07:01:25 fillods Exp $ +% * $Id: rpcrig.x,v 1.6 2003-04-06 18:40:35 fillods Exp $ % * % * This library is free software; you can redistribute it and/or modify % * it under the terms of the GNU Library General Public License as @@ -100,10 +100,11 @@ default: struct split_arg { vfo_x vfo; split_x split; + vfo_x tx_vfo; }; union split_res switch (int rigstatus) { case 0: - split_x split; + split_arg split; default: void; }; @@ -299,8 +300,8 @@ program RIGPROG { freq_res GETSPLITFREQ(vfo_x) = 17; int SETSPLITMODE(mode_arg) = 18; mode_res GETSPLITMODE(vfo_x) = 19; - int SETSPLIT(split_arg) = 20; - split_res GETSPLIT(vfo_x) = 21; + int SETSPLITVFO(split_arg) = 20; + split_res GETSPLITVFO(vfo_x) = 21; int SETPTT(ptt_arg) = 22; ptt_res GETPTT(vfo_x) = 23; dcd_res GETDCD(vfo_x) = 24; diff --git a/rpcrig/rpcrig_backend.c b/rpcrig/rpcrig_backend.c index fa4905a3c..6f5bb9dfd 100644 --- a/rpcrig/rpcrig_backend.c +++ b/rpcrig/rpcrig_backend.c @@ -1,8 +1,8 @@ /* * Hamlib RPC backend - main file - * Copyright (c) 2001,2002 by Stephane Fillod + * Copyright (c) 2001-2003 by Stephane Fillod * - * $Id: rpcrig_backend.c,v 1.11 2002-12-16 22:06:50 fillods Exp $ + * $Id: rpcrig_backend.c,v 1.12 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -487,15 +487,47 @@ static int rpcrig_get_split_mode(RIG *rig, vfo_t vfo, rmode_t *tx_mode, pbwidth_ return mres->rigstatus; } -static int rpcrig_set_split(RIG *rig, vfo_t vfo, split_t split) +static int rpcrig_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo) { - SETBODYVFO1(setsplit, split, split); + struct rpcrig_priv_data *priv; + int *result; + split_arg arg; + + priv = (struct rpcrig_priv_data*)rig->state.priv; + + arg.vfo = vfo; + arg.split = split; + arg.tx_vfo = tx_vfo; + result = setsplitvfo_1(&arg, priv->cl); + if (result == NULL) { + clnt_perror(priv->cl, "setsplitvfo_1"); + return -RIG_EPROTO; + } + + return *result; } -static int rpcrig_get_split(RIG *rig, vfo_t vfo, split_t *split) +static int rpcrig_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo) { - GETBODYVFO1(getsplit, split, split); + struct rpcrig_priv_data *priv; + split_res *res; + vfo_x v; + + priv = (struct rpcrig_priv_data*)rig->state.priv; + + v = vfo; + res = getsplitvfo_1(&v, priv->cl); + if (res == NULL) { + clnt_perror(priv->cl, "getsplitvfo_1"); + return -RIG_EPROTO; + } + if (res->rigstatus == RIG_OK) { + *split = res->split_res_u.split.split; + *tx_vfo = res->split_res_u.split.tx_vfo; + } + + return res->rigstatus; } @@ -1047,8 +1079,8 @@ struct rig_caps rpcrig_caps = { .get_split_freq = rpcrig_get_split_freq, .set_split_mode = rpcrig_set_split_mode, .get_split_mode = rpcrig_get_split_mode, - .set_split = rpcrig_set_split, - .get_split = rpcrig_get_split, + .set_split_vfo = rpcrig_set_split_vfo, + .get_split_vfo = rpcrig_get_split_vfo, .set_rit = rpcrig_set_rit, .get_rit = rpcrig_get_rit, .set_xit = rpcrig_set_xit, diff --git a/rpcrig/rpcrig_proc.c b/rpcrig/rpcrig_proc.c index 97acb311d..3ca787fa3 100644 --- a/rpcrig/rpcrig_proc.c +++ b/rpcrig/rpcrig_proc.c @@ -1,8 +1,8 @@ /* * Hamlib RPC server - procedures - * Copyright (c) 2001-2002 by Stephane Fillod + * Copyright (c) 2001-2003 by Stephane Fillod * - * $Id: rpcrig_proc.c,v 1.6 2002-08-23 20:01:09 fillods Exp $ + * $Id: rpcrig_proc.c,v 1.7 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -249,8 +249,28 @@ mode_res *getsplitmode_1_svc(vfo_x *vfo, struct svc_req *svc) return &res; } -DECLARESETV1(setsplit, rig_set_split, split) -DECLAREGETV1(getsplit, rig_get_split, split, split_t) +int *setsplitvfo_1_svc(split_arg *arg, struct svc_req *svc) +{ + static int res; + + res = rig_set_split_vfo(the_rpc_rig, arg->vfo, arg->split, arg->tx_vfo); + + return &res; +} + +split_res *getsplitvfo_1_svc(vfo_x *vfo, struct svc_req *svc) +{ + static split_res res; + split_t arg; + vfo_t tx_vfo; + + res.rigstatus = rig_get_split_vfo(the_rpc_rig, *vfo, &arg, &tx_vfo); + res.split_res_u.split.split = arg; + res.split_res_u.split.tx_vfo = tx_vfo; + + return &res; +} + DECLARESETV1(setptt, rig_set_ptt, ptt) DECLAREGETV1(getptt, rig_get_ptt, ptt, ptt_t) diff --git a/src/mem.c b/src/mem.c index 9c96d922e..9c7c96927 100644 --- a/src/mem.c +++ b/src/mem.c @@ -3,16 +3,16 @@ * \ingroup rig * \brief Memory and channel interface * \author Stephane Fillod - * \date 2000-2002 + * \date 2000-2003 * * Hamlib interface is a frontend implementing wrapper functions. */ /* * Hamlib Interface - mem/channel calls - * Copyright (c) 2000-2002 by Stephane Fillod + * Copyright (c) 2000-2003 by Stephane Fillod * - * $Id: mem.c,v 1.1 2002-11-04 22:21:42 fillods Exp $ + * $Id: mem.c,v 1.2 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -242,7 +242,7 @@ int generic_save_channel(RIG *rig, channel_t *chan) rig_get_mode(rig, RIG_VFO_CURR, &chan->mode, &chan->width); chan->split = RIG_SPLIT_OFF; - rig_get_split(rig, RIG_VFO_CURR, &chan->split); + rig_get_split_vfo(rig, RIG_VFO_CURR, &chan->split, &chan->tx_vfo); if (chan->split != RIG_SPLIT_OFF) { rig_get_split_freq(rig, RIG_VFO_CURR, &chan->tx_freq); rig_get_split_mode(rig, RIG_VFO_CURR, &chan->tx_mode, &chan->tx_width); @@ -296,7 +296,7 @@ int generic_restore_channel(RIG *rig, const channel_t *chan) rig_set_vfo(rig, chan->vfo); rig_set_freq(rig, RIG_VFO_CURR, chan->freq); rig_set_mode(rig, RIG_VFO_CURR, chan->mode, chan->width); - rig_set_split(rig, RIG_VFO_CURR, chan->split); + rig_set_split_vfo(rig, RIG_VFO_CURR, chan->split, chan->tx_vfo); if (chan->split != RIG_SPLIT_OFF) { rig_set_split_freq(rig, RIG_VFO_CURR, chan->tx_freq); rig_set_split_mode(rig, RIG_VFO_CURR, chan->tx_mode, chan->tx_width); diff --git a/src/rig.c b/src/rig.c index be7f5c2cf..070ba95b9 100644 --- a/src/rig.c +++ b/src/rig.c @@ -2,7 +2,7 @@ * Hamlib Interface - main file * Copyright (c) 2000-2003 by Stephane Fillod and Frank Singleton * - * $Id: rig.c,v 1.68 2003-03-10 08:26:09 fillods Exp $ + * $Id: rig.c,v 1.69 2003-04-06 18:40:35 fillods Exp $ * * This library is free software; you can redistribute it and/or modify * it under the terms of the GNU Library General Public License as @@ -1581,9 +1581,9 @@ int rig_get_split_mode(RIG *rig, vfo_t vfo, rmode_t *tx_mode, pbwidth_t *tx_widt * a negative value if an error occured (in which case, cause is * set appropriately). * - * \sa rig_get_split() + * \sa rig_get_split_vfo() */ -int rig_set_split(RIG *rig, vfo_t vfo, split_t split) +int rig_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo) { const struct rig_caps *caps; int retcode; @@ -1594,12 +1594,12 @@ int rig_set_split(RIG *rig, vfo_t vfo, split_t split) caps = rig->caps; - if (caps->set_split == NULL) + if (caps->set_split_vfo == NULL) return -RIG_ENAVAIL; if ((caps->targetable_vfo&RIG_TARGETABLE_ALL) || vfo == RIG_VFO_CURR || vfo == rig->state.current_vfo) - return caps->set_split(rig, vfo, split); + return caps->set_split_vfo(rig, vfo, split, tx_vfo); if (!caps->set_vfo) return -RIG_ENTARGET; @@ -1608,7 +1608,7 @@ int rig_set_split(RIG *rig, vfo_t vfo, split_t split) if (retcode != RIG_OK) return retcode; - retcode = caps->set_split(rig, vfo, split); + retcode = caps->set_split_vfo(rig, vfo, split, tx_vfo); caps->set_vfo(rig, curr_vfo); return retcode; } @@ -1625,9 +1625,9 @@ int rig_set_split(RIG *rig, vfo_t vfo, split_t split) * a negative value if an error occured (in which case, cause is * set appropriately). * - * \sa rig_set_split() + * \sa rig_set_split_vfo() */ -int rig_get_split(RIG *rig, vfo_t vfo, split_t *split) +int rig_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo) { const struct rig_caps *caps; int retcode; @@ -1638,12 +1638,12 @@ int rig_get_split(RIG *rig, vfo_t vfo, split_t *split) caps = rig->caps; - if (caps->get_split == NULL) + if (caps->get_split_vfo == NULL) return -RIG_ENAVAIL; if ((caps->targetable_vfo&RIG_TARGETABLE_ALL) || vfo == RIG_VFO_CURR || vfo == rig->state.current_vfo) - return caps->get_split(rig, vfo, split); + return caps->get_split_vfo(rig, vfo, split, tx_vfo); if (!caps->set_vfo) return -RIG_ENTARGET; @@ -1652,7 +1652,7 @@ int rig_get_split(RIG *rig, vfo_t vfo, split_t *split) if (retcode != RIG_OK) return retcode; - retcode = caps->get_split(rig, vfo, split); + retcode = caps->get_split_vfo(rig, vfo, split, tx_vfo); caps->set_vfo(rig, curr_vfo); return retcode; } @@ -2222,7 +2222,8 @@ int rig_reset(RIG *rig, reset_t reset) return rig->caps->reset(rig, reset); } - +extern int rig_probe_first(port_t *p); +extern int rig_probe_all_backends(port_t *p, rig_probe_func_t cfunc, rig_ptr_t data); /** * \brief try to guess a rig * \param port A pointer describing a port linking the host to the rig diff --git a/tests/dumpcaps.c b/tests/dumpcaps.c index fbf26e25d..cfdfcc9ed 100644 --- a/tests/dumpcaps.c +++ b/tests/dumpcaps.c @@ -1,9 +1,9 @@ /* - * dumpcaps.c - Copyright (C) 2000-2002 Stephane Fillod + * dumpcaps.c - Copyright (C) 2000-2003 Stephane Fillod * This programs dumps the capabilities of a backend rig. * * - * $Id: dumpcaps.c,v 1.36 2003-03-19 23:44:37 fillods Exp $ + * $Id: dumpcaps.c,v 1.37 2003-04-06 18:40:35 fillods Exp $ * * * This program is free software; you can redistribute it and/or @@ -359,8 +359,8 @@ int dumpcaps (RIG* rig) printf("Can get split freq:\t%c\n",caps->get_split_freq!=NULL?'Y':'N'); printf("Can set split mode:\t%c\n",caps->set_split_mode!=NULL?'Y':'N'); printf("Can get split mode:\t%c\n",caps->get_split_mode!=NULL?'Y':'N'); - printf("Can set split:\t%c\n",caps->set_split!=NULL?'Y':'N'); - printf("Can get split:\t%c\n",caps->get_split!=NULL?'Y':'N'); + printf("Can set split vfo:\t%c\n",caps->set_split_vfo!=NULL?'Y':'N'); + printf("Can get split vfo:\t%c\n",caps->get_split_vfo!=NULL?'Y':'N'); printf("Can set tuning step:\t%c\n",caps->set_ts!=NULL?'Y':'N'); printf("Can get tuning step:\t%c\n",caps->get_ts!=NULL?'Y':'N'); printf("Can set RIT:\t%c\n",caps->set_rit!=NULL?'Y':'N'); diff --git a/tests/rigctl.1 b/tests/rigctl.1 index 30efab1a7..f55c1550b 100644 --- a/tests/rigctl.1 +++ b/tests/rigctl.1 @@ -178,11 +178,18 @@ Set TX frequency, in Hz. .B i, get_split_freq Get TX frequency. .TP -.B S, set_split -Set split mode, 0 or 1. +.B X, set_split_mode +Set transmit mode/passband: AM, FM, CW, CWR, USB, LSB, RTTY, RTTYR, WFM. +The passband is the exact passband in Hz, or 0 for the default. .TP -.B s, get_split -Get split mode. +.B x, get_split_mode +Get transmit mode/passband. +.TP +.B S, set_split_vfo +Set split mode, 0 or 1, and transmit VFO. +.TP +.B s, get_split_vfo +Get split mode and transmit VFO. .TP .B N, set_ts Set tuning step, in Hz. diff --git a/tests/rigctl.c b/tests/rigctl.c index 7f217dca3..6c97a8ef6 100644 --- a/tests/rigctl.c +++ b/tests/rigctl.c @@ -5,7 +5,7 @@ * It takes commands in interactive mode as well as * from command line options. * - * $Id: rigctl.c,v 1.41 2003-03-27 23:44:20 fillods Exp $ + * $Id: rigctl.c,v 1.42 2003-04-06 18:40:35 fillods Exp $ * * * This program is free software; you can redistribute it and/or @@ -116,8 +116,8 @@ declare_proto_rig(set_split_freq); declare_proto_rig(get_split_freq); declare_proto_rig(set_split_mode); declare_proto_rig(get_split_mode); -declare_proto_rig(set_split); -declare_proto_rig(get_split); +declare_proto_rig(set_split_vfo); +declare_proto_rig(get_split_vfo); declare_proto_rig(set_ts); declare_proto_rig(get_ts); declare_proto_rig(power2mW); @@ -175,8 +175,8 @@ struct test_table test_list[] = { { 'i', "get_split_freq", get_split_freq, ARG_OUT, "Tx frequency" }, { 'X', "set_split_mode", set_split_mode, ARG_IN, "Mode", "Passband" }, { 'x', "get_split_mode", get_split_mode, ARG_OUT, "Mode", "Passband" }, - { 'S', "set_split", set_split, ARG_IN, "Split mode" }, - { 's', "get_split", get_split, ARG_OUT, "Split mode" }, + { 'S', "set_split_vfo", set_split_vfo, ARG_IN, "Split mode", "TxVFO" }, + { 's', "get_split_vfo", get_split_vfo, ARG_OUT, "Split mode", "TxVFO" }, { 'N', "set_ts", set_ts, ARG_IN, "Tuning step" }, { 'n', "get_ts", get_ts, ARG_OUT, "Tuning step" }, { 'L', "set_level", set_level, ARG_IN, "Level", "Value" }, @@ -1047,26 +1047,30 @@ declare_proto_rig(get_split_mode) } -declare_proto_rig(set_split) +declare_proto_rig(set_split_vfo) { split_t split; sscanf(arg1, "%d", (int*)&split); - return rig_set_split(rig, vfo, split); + return rig_set_split_vfo(rig, vfo, split, parse_vfo(arg2)); } -declare_proto_rig(get_split) +declare_proto_rig(get_split_vfo) { int status; split_t split; + vfo_t tx_vfo; - status = rig_get_split(rig, vfo, &split); + status = rig_get_split_vfo(rig, vfo, &split, &tx_vfo); if (status != RIG_OK) return status; if (interactive) printf("%s: ", cmd->arg1); printf("%d\n", split); + if (interactive) + printf("%s: ", cmd->arg2); + printf("%s\n", strvfo(tx_vfo)); return status; } diff --git a/yaesu/ft100.c b/yaesu/ft100.c index fcf40dcd9..f8b9089af 100644 --- a/yaesu/ft100.c +++ b/yaesu/ft100.c @@ -1,5 +1,5 @@ /* - * hamlib - (C) Frank Singleton 2000-2002 + * hamlib - (C) Frank Singleton 2000-2003 * * ft100.c - (C) Chris Karpinsky 2001 (aa1vl@arrl.net) * This shared library provides an API for communicating @@ -7,7 +7,7 @@ * The starting point for this code was Frank's ft847 implementation. * * - * $Id: ft100.c,v 1.8 2003-03-10 08:26:20 fillods Exp $ + * $Id: ft100.c,v 1.9 2003-04-06 18:40:35 fillods Exp $ * * * This library is free software; you can redistribute it and/or @@ -270,8 +270,8 @@ const struct rig_caps ft100_caps = { .get_split_freq = NULL, .set_split_mode = NULL, .get_split_mode = NULL, - .set_split = ft100_set_split, - .get_split = NULL, + .set_split_vfo = ft100_set_split_vfo, + .get_split_vfo = NULL, .set_rit = NULL, .get_rit = NULL, .set_xit = NULL, @@ -688,7 +688,7 @@ int ft100_get_parm(RIG *rig, setting_t parm, value_t *val) { /* kc2ivl */ -int ft100_set_split(RIG *rig, vfo_t vfo, split_t split) { +int ft100_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo) { unsigned char cmd_index; diff --git a/yaesu/ft100.h b/yaesu/ft100.h index 666f8adad..b83546c11 100644 --- a/yaesu/ft100.h +++ b/yaesu/ft100.h @@ -1,5 +1,5 @@ /* - * hamlib - (C) Frank Singleton 2000 (vk3fcs@ix.netcom.com) + * hamlib - (C) Frank Singleton 2000-2003 (vk3fcs@ix.netcom.com) * * ft100.h - (C) Chris Karpinsky 2001 (aa1vl@arrl.net) * This shared library provides an API for communicating @@ -7,7 +7,7 @@ * The starting point for this code was Frank's ft847 implementation. * * - * $Id: ft100.h,v 1.4 2002-12-01 03:08:05 n0nb Exp $ + * $Id: ft100.h,v 1.5 2003-04-06 18:40:35 fillods Exp $ * * * This library is free software; you can redistribute it and/or @@ -163,8 +163,8 @@ int ft100_get_func(RIG *rig, vfo_t vfo, setting_t func, int *status); int ft100_set_parm(RIG *rig, setting_t parm, value_t val); int ft100_get_parm(RIG *rig, setting_t parm, value_t *val); -int ft100_set_split(RIG *rig, vfo_t vfo, split_t split); -int ft100_get_split(RIG *rig, vfo_t vfo, split_t *split); +int ft100_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo); +int ft100_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo); int ft100_set_rptr_shift(RIG *rig, vfo_t vfo, rptr_shift_t shift); int ft100_get_rptr_shift(RIG *rig, vfo_t vfo, rptr_shift_t *shift); diff --git a/yaesu/ft817.c b/yaesu/ft817.c index 5d3d7eafd..94fc7b99a 100644 --- a/yaesu/ft817.c +++ b/yaesu/ft817.c @@ -7,7 +7,7 @@ * The starting point for this code was Frank's ft847 implementation. * * - * $Id: ft817.c,v 1.6 2003-03-10 08:26:20 fillods Exp $ + * $Id: ft817.c,v 1.7 2003-04-06 18:40:35 fillods Exp $ * * * This library is free software; you can redistribute it and/or @@ -218,8 +218,8 @@ const struct rig_caps ft817_caps = { .get_split_freq = NULL, .set_split_mode = NULL, .get_split_mode = NULL, - .set_split = NULL, - .get_split = NULL, + .set_split_vfo = NULL, + .get_split_vfo = NULL, .set_rit = NULL, .get_rit = NULL, .set_xit = NULL, diff --git a/yaesu/ft890.c b/yaesu/ft890.c index a51e0841f..17f1992af 100644 --- a/yaesu/ft890.c +++ b/yaesu/ft890.c @@ -9,7 +9,7 @@ * via serial interface to an FT-890 using the "CAT" interface * * - * $Id: ft890.c,v 1.3 2003-04-05 04:13:53 n0nb Exp $ + * $Id: ft890.c,v 1.4 2003-04-06 18:40:36 fillods Exp $ * * * This library is free software; you can redistribute it and/or @@ -254,8 +254,8 @@ const struct rig_caps ft890_caps = { .get_vfo = ft890_get_vfo, .set_ptt = ft890_set_ptt, .get_ptt = ft890_get_ptt, - .set_split = ft890_set_split, - .get_split = ft890_get_split, + .set_split_vfo = ft890_set_split_vfo, + .get_split_vfo = ft890_get_split_vfo, // .set_split_freq = ft890_set_split_freq, // .get_split_freq = ft890_get_split_freq, // .set_split_mode = ft890_set_split_mode, @@ -979,7 +979,7 @@ static int ft890_get_ptt(RIG *rig, vfo_t vfo, ptt_t *ptt) { * */ -static int ft890_set_split(RIG *rig, vfo_t vfo, split_t split) { +static int ft890_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo) { unsigned char cmd_index; int err; @@ -1019,7 +1019,7 @@ static int ft890_set_split(RIG *rig, vfo_t vfo, split_t split) { * */ -static int ft890_get_split(RIG *rig, vfo_t vfo, split_t *split) { +static int ft890_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo) { struct ft890_priv_data *priv; unsigned char status_0; int err; diff --git a/yaesu/ft890.h b/yaesu/ft890.h index f8c21f6d6..0689df4f0 100644 --- a/yaesu/ft890.h +++ b/yaesu/ft890.h @@ -9,7 +9,7 @@ * via serial interface to an FT-890 using the "CAT" interface * * - * $Id: ft890.h,v 1.3 2003-04-05 04:13:53 n0nb Exp $ + * $Id: ft890.h,v 1.4 2003-04-06 18:40:36 fillods Exp $ * * * This library is free software; you can redistribute it and/or @@ -341,8 +341,8 @@ static int ft890_get_vfo(RIG *rig, vfo_t *vfo); static int ft890_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt); static int ft890_get_ptt(RIG *rig, vfo_t vfo, ptt_t *ptt); -static int ft890_set_split(RIG *rig, vfo_t vfo, split_t split); -static int ft890_get_split(RIG *rig, vfo_t vfo, split_t *split); +static int ft890_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo); +static int ft890_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo); /* static int ft890_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq); static int ft890_get_split_freq(RIG *rig, vfo_t vfo, freq_t *tx_freq); */ diff --git a/yaesu/ft920.c b/yaesu/ft920.c index f23791607..2b1f7160b 100644 --- a/yaesu/ft920.c +++ b/yaesu/ft920.c @@ -12,7 +12,7 @@ * pages 86 to 90 * * - * $Id: ft920.c,v 1.14 2003-01-19 04:48:00 n0nb Exp $ + * $Id: ft920.c,v 1.15 2003-04-06 18:40:36 fillods Exp $ * * * This library is free software; you can redistribute it and/or @@ -268,8 +268,8 @@ const struct rig_caps ft920_caps = { .get_mode = ft920_get_mode, /* get mode */ .set_vfo = ft920_set_vfo, /* set vfo */ .get_vfo = ft920_get_vfo, /* get vfo */ - .set_split = ft920_set_split, - .get_split = ft920_get_split, + .set_split_vfo = ft920_set_split_vfo, + .get_split_vfo = ft920_get_split_vfo, .set_split_freq = ft920_set_split_freq, .get_split_freq = ft920_get_split_freq, .set_split_mode = ft920_set_split_mode, @@ -941,7 +941,7 @@ static int ft920_get_vfo(RIG *rig, vfo_t *vfo) { * */ -static int ft920_set_split(RIG *rig, vfo_t vfo, split_t split) { +static int ft920_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo) { unsigned char cmd_index; int err; @@ -979,7 +979,7 @@ static int ft920_set_split(RIG *rig, vfo_t vfo, split_t split) { * */ -static int ft920_get_split(RIG *rig, vfo_t vfo, split_t *split) { +static int ft920_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo) { struct ft920_priv_data *priv; unsigned char status_0; int err; diff --git a/yaesu/ft920.h b/yaesu/ft920.h index 4ffd52075..11ccf07a2 100644 --- a/yaesu/ft920.h +++ b/yaesu/ft920.h @@ -9,7 +9,7 @@ * via serial interface to an FT-920 using the "CAT" interface * * - * $Id: ft920.h,v 1.11 2003-01-19 04:48:00 n0nb Exp $ + * $Id: ft920.h,v 1.12 2003-04-06 18:40:36 fillods Exp $ * * * This library is free software; you can redistribute it and/or @@ -321,8 +321,8 @@ static int ft920_get_mode(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width); static int ft920_set_vfo(RIG *rig, vfo_t vfo); static int ft920_get_vfo(RIG *rig, vfo_t *vfo); -static int ft920_set_split(RIG *rig, vfo_t vfo, split_t split); -static int ft920_get_split(RIG *rig, vfo_t vfo, split_t *split); +static int ft920_set_split_vfo(RIG *rig, vfo_t vfo, split_t split, vfo_t tx_vfo); +static int ft920_get_split_vfo(RIG *rig, vfo_t vfo, split_t *split, vfo_t *tx_vfo); static int ft920_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq); static int ft920_get_split_freq(RIG *rig, vfo_t vfo, freq_t *tx_freq);