kopia lustrzana https://github.com/Hamlib/Hamlib
Disable retries when looking for the tone unit
Disable retries when looking for tone unit in ts450_open() since it may confuse rigs lacking it.Hamlib-1.2.15
rodzic
3402e594ff
commit
3e22b7dc7c
|
@ -1,8 +1,6 @@
|
||||||
/*
|
/*
|
||||||
* Hamlib Kenwood backend - TS450S description
|
* Hamlib Kenwood backend - TS450S description
|
||||||
* Copyright (c) 2000-2004 by Stephane Fillod
|
* Copyright (c) 2000-2011 by Stephane Fillod
|
||||||
*
|
|
||||||
* $Id: ts450s.c,v 1.30 2009-02-06 14:15:12 azummo Exp $
|
|
||||||
*
|
*
|
||||||
* This library is free software; you can redistribute it and/or modify
|
* This library is free software; you can redistribute it and/or modify
|
||||||
* it under the terms of the GNU Library General Public License as
|
* it under the terms of the GNU Library General Public License as
|
||||||
|
@ -71,18 +69,25 @@ static const struct confparams ts450_ext_parms[] = {
|
||||||
static int ts450_open(RIG *rig)
|
static int ts450_open(RIG *rig)
|
||||||
{
|
{
|
||||||
int err;
|
int err;
|
||||||
|
int maxtries;
|
||||||
|
|
||||||
err = kenwood_open(rig);
|
err = kenwood_open(rig);
|
||||||
if (err != RIG_OK)
|
if (err != RIG_OK)
|
||||||
return err;
|
return err;
|
||||||
|
|
||||||
|
maxtries = rig->state.rigport.retry;
|
||||||
|
/* no retry for this command that may be missing */
|
||||||
|
rig->state.rigport.retry = 0;
|
||||||
|
|
||||||
err = kenwood_simple_transaction(rig, "TO", 3);
|
err = kenwood_simple_transaction(rig, "TO", 3);
|
||||||
if (err != RIG_OK) {
|
if (err != RIG_OK) {
|
||||||
rig_debug(RIG_DEBUG_TRACE, "%s: tone unit not detected\n", __func__);
|
rig_debug(RIG_DEBUG_VERBOSE, "%s: tone unit not detected\n", __func__);
|
||||||
rig->state.has_set_func &= ~RIG_FUNC_TONE;
|
rig->state.has_set_func &= ~RIG_FUNC_TONE;
|
||||||
rig->state.has_get_func &= ~RIG_FUNC_TONE;
|
rig->state.has_get_func &= ~RIG_FUNC_TONE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
rig->state.rigport.retry = maxtries;
|
||||||
|
|
||||||
return RIG_OK;
|
return RIG_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -105,7 +110,7 @@ const struct rig_caps ts450s_caps = {
|
||||||
.rig_model = RIG_MODEL_TS450S,
|
.rig_model = RIG_MODEL_TS450S,
|
||||||
.model_name = "TS-450S",
|
.model_name = "TS-450S",
|
||||||
.mfg_name = "Kenwood",
|
.mfg_name = "Kenwood",
|
||||||
.version = BACKEND_VER,
|
.version = BACKEND_VER ".1",
|
||||||
.copyright = "LGPL",
|
.copyright = "LGPL",
|
||||||
.status = RIG_STATUS_BETA,
|
.status = RIG_STATUS_BETA,
|
||||||
.rig_type = RIG_TYPE_TRANSCEIVER,
|
.rig_type = RIG_TYPE_TRANSCEIVER,
|
||||||
|
|
Ładowanie…
Reference in New Issue