kopia lustrzana https://github.com/Hamlib/Hamlib
Fix Icom rig 0x25 command for set mode with data and no width change
Fix Icom rigs not working with rigtctld and 0x25 command https://github.com/Hamlib/Hamlib/issues/733pull/739/head
rodzic
716fbb7643
commit
dd0187ede6
|
@ -1759,20 +1759,17 @@ int icom_set_mode_with_data(RIG *rig, vfo_t vfo, rmode_t mode,
|
||||||
|
|
||||||
rig2icom_mode(rig, vfo, mode, width, &mode_icom, &width_icom);
|
rig2icom_mode(rig, vfo, mode, width, &mode_icom, &width_icom);
|
||||||
|
|
||||||
if (filter_byte && width_icom != -1) // then we need the width byte too
|
if (filter_byte) // then we need the filter width byte too
|
||||||
{
|
{
|
||||||
// since width_icom is 0-2 for rigs that need this here we have to make it 1-3
|
if (width_icom == -1) datamode[1] = 1; // default to filter 1
|
||||||
datamode[1] = datamode[0] ? width_icom : 0;
|
else datamode[1] = width_icom;
|
||||||
retval =
|
retval =
|
||||||
icom_transaction(rig, C_CTL_MEM, dm_sub_cmd, datamode, 2,
|
icom_transaction(rig, C_CTL_MEM, dm_sub_cmd, datamode, 2, ackbuf, &ack_len);
|
||||||
ackbuf,
|
|
||||||
&ack_len);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
retval =
|
retval =
|
||||||
icom_transaction(rig, C_CTL_MEM, dm_sub_cmd, datamode, 1, ackbuf,
|
icom_transaction(rig, C_CTL_MEM, dm_sub_cmd, datamode, 1, ackbuf, &ack_len);
|
||||||
&ack_len);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (retval != RIG_OK)
|
if (retval != RIG_OK)
|
||||||
|
@ -4815,6 +4812,11 @@ int icom_set_split_freq(RIG *rig, vfo_t vfo, freq_t tx_freq)
|
||||||
|
|
||||||
cmd = C_SEND_SEL_FREQ;
|
cmd = C_SEND_SEL_FREQ;
|
||||||
subcmd = 0x01; // set the unselected vfo
|
subcmd = 0x01; // set the unselected vfo
|
||||||
|
// if we're already on the tx_vfo don't need the "other" vfo
|
||||||
|
if (rig->state.current_vfo == rig->state.tx_vfo)
|
||||||
|
{
|
||||||
|
subcmd = 0x00;
|
||||||
|
}
|
||||||
retval = icom_transaction(rig, cmd, subcmd, freqbuf, freq_len, ackbuf,
|
retval = icom_transaction(rig, cmd, subcmd, freqbuf, freq_len, ackbuf,
|
||||||
&ack_len);
|
&ack_len);
|
||||||
|
|
||||||
|
|
|
@ -30,7 +30,7 @@
|
||||||
#include <sys/time.h>
|
#include <sys/time.h>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#define BACKEND_VER "20210614"
|
#define BACKEND_VER "20210703"
|
||||||
|
|
||||||
#define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B))
|
#define ICOM_IS_SECONDARY_VFO(vfo) ((vfo) & (RIG_VFO_B | RIG_VFO_SUB | RIG_VFO_SUB_B | RIG_VFO_MAIN_B))
|
||||||
#define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00)
|
#define ICOM_GET_VFO_NUMBER(vfo) (ICOM_IS_SECONDARY_VFO(vfo) ? 0x01 : 0x00)
|
||||||
|
|
Ładowanie…
Reference in New Issue