kopia lustrzana https://github.com/Hamlib/Hamlib
rodzic
e57774cfde
commit
24a9fdcc94
|
@ -909,7 +909,7 @@ int newcat_set_freq(RIG *rig, vfo_t vfo, freq_t freq)
|
|||
// remove the split check here -- hopefully works OK
|
||||
//&& !rig->state.cache.split
|
||||
// seems some rigs are problematic
|
||||
&& !(is_ftdx3000)
|
||||
// && !(is_ftdx3000)
|
||||
// some rigs can't do BS command on 60M
|
||||
// && !(is_ftdx3000 && newcat_band_index(freq) == 2)
|
||||
&& !(is_ft2000 && newcat_band_index(freq) == 2)
|
||||
|
@ -920,13 +920,21 @@ int newcat_set_freq(RIG *rig, vfo_t vfo, freq_t freq)
|
|||
{
|
||||
if (rig->state.current_vfo != vfo)
|
||||
{
|
||||
// then we need to change vfos, BS, and change back
|
||||
snprintf(priv->cmd_str, sizeof(priv->cmd_str), "VS1;BS%02d;VS0;",
|
||||
newcat_band_index(freq));
|
||||
|
||||
if (vfo == RIG_VFO_A || vfo == RIG_VFO_MAIN)
|
||||
snprintf(priv->cmd_str, sizeof(priv->cmd_str), "VS0;BS%02d;VS1;",
|
||||
newcat_band_index(freq));
|
||||
int vfo1 = 1, vfo2 = 0;
|
||||
if (vfo == RIG_VFO_A || vfo == RIG_VFO_MAIN) {
|
||||
vfo1 = 0;
|
||||
vfo2 = 1;
|
||||
}
|
||||
// we need to change vfos, BS, and change back
|
||||
snprintf(priv->cmd_str, sizeof(priv->cmd_str), "VS%d;BS%02d",
|
||||
vfo1, newcat_band_index(freq));
|
||||
if (RIG_OK != (err = newcat_set_cmd(rig)))
|
||||
{
|
||||
rig_debug(RIG_DEBUG_ERR, "%s: Unexpected error with BS command#1=%s\n",
|
||||
__func__, rigerror(err));
|
||||
}
|
||||
hl_usleep(50*1000); // wait for BS to do it's thing and swap back
|
||||
snprintf(priv->cmd_str, sizeof(priv->cmd_str), "VS%d;", vfo2);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -936,9 +944,8 @@ int newcat_set_freq(RIG *rig, vfo_t vfo, freq_t freq)
|
|||
|
||||
if (RIG_OK != (err = newcat_set_cmd(rig)))
|
||||
{
|
||||
rig_debug(RIG_DEBUG_ERR, "%s: Unexpected error with BS command#1=%s\n",
|
||||
__func__,
|
||||
rigerror(err));
|
||||
rig_debug(RIG_DEBUG_ERR, "%s: Unexpected error with BS command#2=%s\n",
|
||||
__func__, rigerror(err));
|
||||
}
|
||||
|
||||
#if 0 // disable for testing
|
||||
|
@ -979,7 +986,7 @@ int newcat_set_freq(RIG *rig, vfo_t vfo, freq_t freq)
|
|||
|
||||
if (RIG_OK != (err = newcat_set_cmd(rig)))
|
||||
{
|
||||
rig_debug(RIG_DEBUG_ERR, "%s: Unexpected error with BS command#2=%s\n",
|
||||
rig_debug(RIG_DEBUG_ERR, "%s: Unexpected error with BS command#3=%s\n",
|
||||
__func__,
|
||||
rigerror(err));
|
||||
}
|
||||
|
|
|
@ -50,7 +50,7 @@
|
|||
typedef char ncboolean;
|
||||
|
||||
/* shared function version */
|
||||
#define NEWCAT_VER "20210802"
|
||||
#define NEWCAT_VER "20210805"
|
||||
|
||||
/* Hopefully large enough for future use, 128 chars plus '\0' */
|
||||
#define NEWCAT_DATA_LEN 129
|
||||
|
|
Ładowanie…
Reference in New Issue