pull/281/head
Michael Black W9MDB 2020-05-16 15:22:48 -05:00
commit ba703787d9
4 zmienionych plików z 11 dodań i 7 usunięć

Wyświetl plik

@ -7105,6 +7105,7 @@ static int set_vfo_curr(RIG *rig, vfo_t vfo, vfo_t curr_vfo)
// only need to set vfo if it's changed
else if (priv->curr_vfo != vfo)
{
if (!(VFO_HAS_MAIN_SUB_A_B_ONLY && !priv->split_on && !priv->satmode && vfo == RIG_VFO_SUB && priv->curr_vfo == RIG_VFO_B)) {
rig_debug(RIG_DEBUG_TRACE, "%s: setting new vfo=%s\n", __func__,
rig_strvfo(vfo));
retval = rig_set_vfo(rig, vfo);
@ -7115,6 +7116,7 @@ static int set_vfo_curr(RIG *rig, vfo_t vfo, vfo_t curr_vfo)
}
priv->curr_vfo = vfo;
}
}
rig_debug(RIG_DEBUG_TRACE, "%s: curr_vfo now=%s\n", __func__,

Wyświetl plik

@ -1254,7 +1254,7 @@ void HAMLIB_API rig_no_restore_ai()
}
//! @cond Doxygen_Suppress
int HAMLIB_API elapsed_ms(struct timespec *start, int option)
double HAMLIB_API elapsed_ms(struct timespec *start, int option)
{
// If option then we are starting the timing, else we get elapsed
struct timespec stop;
@ -1289,8 +1289,8 @@ int HAMLIB_API elapsed_ms(struct timespec *start, int option)
break;
case ELAPSED_INVALIDATE:
start->tv_sec -= 3600 * 24 *
365; // let's back off 1 year -- should expire most elapsed measurements
clock_gettime(CLOCK_REALTIME, start);
start->tv_sec -= 3600;
break;
}

Wyświetl plik

@ -102,7 +102,7 @@ extern HAMLIB_EXPORT(setting_t) rig_idx2setting(int i);
extern HAMLIB_EXPORT(int) hl_usleep(useconds_t usec);
extern HAMLIB_EXPORT(int) elapsed_ms(struct timespec *start, int start_flag);
extern HAMLIB_EXPORT(double) elapsed_ms(struct timespec *start, int start_flag);
#ifdef PRId64
/** \brief printf(3) format to be used for long long (64bits) type */

Wyświetl plik

@ -1150,7 +1150,7 @@ int HAMLIB_API rig_get_twiddle(RIG *rig, int *seconds)
// detect if somebody is twiddling the VFO
// indicator is last set freq doesn't match current freq
// so we have to query freq every time we set freq or vfo to handle this
static int twiddling(RIG *rig)
int twiddling(RIG *rig)
{
const struct rig_caps *caps;
@ -1832,9 +1832,11 @@ int HAMLIB_API rig_set_vfo(RIG *rig, vfo_t vfo)
// we only get the freq if we set the vfo OK
if (retcode == RIG_OK && caps->get_freq)
{
retcode = rig_get_freq(rig, vfo, &curr_freq);
rig_debug(RIG_DEBUG_TRACE, "%s: retcode from rig_get_freq = %s\n", __func__,
if (caps->get_freq) {
retcode = caps->get_freq(rig, vfo, &curr_freq);
rig_debug(RIG_DEBUG_TRACE, "%s: retcode from rig_get_freq = %s\n", __func__,
rigerror(retcode));
}
}