kopia lustrzana https://github.com/Hamlib/Hamlib
astyle all files
rodzic
209ce2c8a1
commit
0267c1b7c9
|
@ -444,9 +444,10 @@ int aor_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width)
|
|||
int mdbuf2_len, retval;
|
||||
|
||||
if (priv->format_mode(rig, mdbuf, mode, width) <= 0)
|
||||
{
|
||||
rig_debug(RIG_DEBUG_ERR, "%s: format_mode=%s failed?\n", __func__, rig_strrmode(mode));
|
||||
return -RIG_EINVAL;
|
||||
{
|
||||
rig_debug(RIG_DEBUG_ERR, "%s: format_mode=%s failed?\n", __func__,
|
||||
rig_strrmode(mode));
|
||||
return -RIG_EINVAL;
|
||||
}
|
||||
|
||||
strcat(mdbuf, EOM);
|
||||
|
|
|
@ -729,10 +729,13 @@ int ic10_set_channel(RIG *rig, const channel_t *chan)
|
|||
|
||||
freq = (int64_t) chan->freq;
|
||||
|
||||
if (chan->channel_num < 90 && chan->tx_freq != 0) {
|
||||
rig_debug(RIG_DEBUG_ERR,"%s: Transmit/split can only be on channels 90-99\n", __func__);
|
||||
if (chan->channel_num < 90 && chan->tx_freq != 0)
|
||||
{
|
||||
rig_debug(RIG_DEBUG_ERR, "%s: Transmit/split can only be on channels 90-99\n",
|
||||
__func__);
|
||||
return -RIG_EINVAL;
|
||||
}
|
||||
|
||||
switch (chan->mode)
|
||||
{
|
||||
case RIG_MODE_CW : md = MD_CW; break;
|
||||
|
|
|
@ -586,7 +586,8 @@ int kenwood_init(RIG *rig)
|
|||
struct kenwood_priv_data *priv;
|
||||
struct kenwood_priv_caps *caps = kenwood_caps(rig);
|
||||
|
||||
rig_debug(RIG_DEBUG_VERBOSE, "%s called, version %s/%s\n", __func__, BACKEND_VER, rig->caps->version);
|
||||
rig_debug(RIG_DEBUG_VERBOSE, "%s called, version %s/%s\n", __func__,
|
||||
BACKEND_VER, rig->caps->version);
|
||||
|
||||
rig->state.priv = malloc(sizeof(struct kenwood_priv_data));
|
||||
|
||||
|
@ -1314,7 +1315,8 @@ int kenwood_set_freq(RIG *rig, vfo_t vfo, freq_t freq)
|
|||
int err;
|
||||
struct kenwood_priv_data *priv = rig->state.priv;
|
||||
|
||||
rig_debug(RIG_DEBUG_VERBOSE, "%s called vfo=%s freq=%.0f\n", __func__, rig_strvfo(vfo), freq);
|
||||
rig_debug(RIG_DEBUG_VERBOSE, "%s called vfo=%s freq=%.0f\n", __func__,
|
||||
rig_strvfo(vfo), freq);
|
||||
|
||||
tvfo = (vfo == RIG_VFO_CURR
|
||||
|| vfo == RIG_VFO_VFO) ? rig->state.current_vfo : vfo;
|
||||
|
@ -1792,7 +1794,8 @@ int kenwood_set_mode(RIG *rig, vfo_t vfo, rmode_t mode, pbwidth_t width)
|
|||
|
||||
if (RIG_PASSBAND_NOCHANGE == width) { return RIG_OK; }
|
||||
|
||||
if (RIG_IS_TS450S || RIG_IS_TS690S || RIG_IS_TS850 || RIG_IS_TS950S || RIG_IS_TS950SDX)
|
||||
if (RIG_IS_TS450S || RIG_IS_TS690S || RIG_IS_TS850 || RIG_IS_TS950S
|
||||
|| RIG_IS_TS950SDX)
|
||||
{
|
||||
|
||||
if (RIG_PASSBAND_NORMAL == width)
|
||||
|
@ -2011,7 +2014,8 @@ int kenwood_get_mode_if(RIG *rig, vfo_t vfo, rmode_t *mode, pbwidth_t *width)
|
|||
|
||||
*width = rig_passband_normal(rig, *mode);
|
||||
|
||||
if (RIG_IS_TS450S || RIG_IS_TS690S || RIG_IS_TS850 || RIG_IS_TS950S || RIG_IS_TS950SDX)
|
||||
if (RIG_IS_TS450S || RIG_IS_TS690S || RIG_IS_TS850 || RIG_IS_TS950S
|
||||
|| RIG_IS_TS950SDX)
|
||||
{
|
||||
|
||||
kenwood_get_filter(rig, width);
|
||||
|
|
|
@ -1433,7 +1433,7 @@ int tt588_set_ptt(RIG *rig, vfo_t vfo, ptt_t ptt)
|
|||
const char *tt588_get_info(RIG *rig)
|
||||
{
|
||||
static char cmdbuf[16], firmware[64];
|
||||
int cmd_len, firmware_len=sizeof(firmware), retval;
|
||||
int cmd_len, firmware_len = sizeof(firmware), retval;
|
||||
|
||||
cmd_len = sprintf(cmdbuf, "?V" EOM);
|
||||
memset(firmware, 0, sizeof(firmware));
|
||||
|
|
|
@ -296,7 +296,7 @@ int HAMLIB_API amp_open(AMP *amp)
|
|||
const struct amp_caps *caps;
|
||||
struct amp_state *rs;
|
||||
int status;
|
||||
int net1,net2,net3,net4,port;
|
||||
int net1, net2, net3, net4, port;
|
||||
|
||||
amp_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
|
||||
|
||||
|
@ -316,9 +316,11 @@ int HAMLIB_API amp_open(AMP *amp)
|
|||
rs->ampport.fd = -1;
|
||||
|
||||
// determine if we have a network address
|
||||
if (sscanf(rs->ampport.pathname,"%d.%d.%d.%d:%d", &net1, &net2, &net3, &net4, &port)==5)
|
||||
if (sscanf(rs->ampport.pathname, "%d.%d.%d.%d:%d", &net1, &net2, &net3, &net4,
|
||||
&port) == 5)
|
||||
{
|
||||
rig_debug(RIG_DEBUG_TRACE,"%s: using network address %s\n", __func__, rs->ampport.pathname);
|
||||
rig_debug(RIG_DEBUG_TRACE, "%s: using network address %s\n", __func__,
|
||||
rs->ampport.pathname);
|
||||
rs->ampport.type.rig = RIG_PORT_NETWORK;
|
||||
}
|
||||
|
||||
|
|
|
@ -554,7 +554,7 @@ int HAMLIB_API rig_open(RIG *rig)
|
|||
struct rig_state *rs;
|
||||
int status = RIG_OK;
|
||||
value_t parm_value;
|
||||
int net1,net2,net3,net4,port;
|
||||
int net1, net2, net3, net4, port;
|
||||
|
||||
rig_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
|
||||
|
||||
|
@ -574,9 +574,11 @@ int HAMLIB_API rig_open(RIG *rig)
|
|||
rs->rigport.fd = -1;
|
||||
|
||||
// determine if we have a network address
|
||||
if (sscanf(rs->rigport.pathname,"%d.%d.%d.%d:%d", &net1, &net2, &net3, &net4, &port)==5)
|
||||
if (sscanf(rs->rigport.pathname, "%d.%d.%d.%d:%d", &net1, &net2, &net3, &net4,
|
||||
&port) == 5)
|
||||
{
|
||||
rig_debug(RIG_DEBUG_TRACE,"%s: using network address %s\n", __func__, rs->rigport.pathname);
|
||||
rig_debug(RIG_DEBUG_TRACE, "%s: using network address %s\n", __func__,
|
||||
rs->rigport.pathname);
|
||||
rs->rigport.type.rig = RIG_PORT_NETWORK;
|
||||
}
|
||||
|
||||
|
|
|
@ -320,7 +320,7 @@ int HAMLIB_API rot_open(ROT *rot)
|
|||
const struct rot_caps *caps;
|
||||
struct rot_state *rs;
|
||||
int status;
|
||||
int net1,net2,net3,net4,port;
|
||||
int net1, net2, net3, net4, port;
|
||||
|
||||
rot_debug(RIG_DEBUG_VERBOSE, "%s called\n", __func__);
|
||||
|
||||
|
@ -340,9 +340,11 @@ int HAMLIB_API rot_open(ROT *rot)
|
|||
rs->rotport.fd = -1;
|
||||
|
||||
// determine if we have a network address
|
||||
if (sscanf(rs->rotport.pathname,"%d.%d.%d.%d:%d", &net1, &net2, &net3, &net4, &port)==5)
|
||||
if (sscanf(rs->rotport.pathname, "%d.%d.%d.%d:%d", &net1, &net2, &net3, &net4,
|
||||
&port) == 5)
|
||||
{
|
||||
rig_debug(RIG_DEBUG_TRACE,"%s: using network address %s\n", __func__, rs->rotport.pathname);
|
||||
rig_debug(RIG_DEBUG_TRACE, "%s: using network address %s\n", __func__,
|
||||
rs->rotport.pathname);
|
||||
rs->rotport.type.rig = RIG_PORT_NETWORK;
|
||||
}
|
||||
|
||||
|
|
Ładowanie…
Reference in New Issue