diff --git a/radio.c b/radio.c index a86ba49..f02ab73 100644 --- a/radio.c +++ b/radio.c @@ -552,17 +552,17 @@ void RADIO_ApplyOffset(VFO_Info_t *pInfo) static void RADIO_SelectCurrentVfo(void) { - // if crossband is active the gCurrentVfo is gTxVfo (gTxVfo/TX_VFO is only ever changed by the user) - // otherwise it is set to gRxVfo + // if crossband is active and DW not the gCurrentVfo is gTxVfo (gTxVfo/TX_VFO is only ever changed by the user) + // otherwise it is set to gRxVfo which is set to gTxVfo in RADIO_SelectVfos // so in the end gCurrentVfo is equal to gTxVfo unless dual watch changes it on incomming transmition (again, this can only happen when XB off) - // note: it is called only in certain situations so could not by up-to-date - gCurrentVfo = (gEeprom.CROSS_BAND_RX_TX == CROSS_BAND_OFF) ? gRxVfo : gTxVfo; + // note: it is called only in certain situations so could be not up-to-date + gCurrentVfo = (gEeprom.CROSS_BAND_RX_TX == CROSS_BAND_OFF || gEeprom.DUAL_WATCH != DUAL_WATCH_OFF) ? gRxVfo : gTxVfo; } void RADIO_SelectVfos(void) { - // if crossband is used then RX_VFO is the opposite to the TX_VFO - gEeprom.RX_VFO = (gEeprom.CROSS_BAND_RX_TX == CROSS_BAND_OFF) ? gEeprom.TX_VFO : !gEeprom.TX_VFO; + // if crossband without DW is used then RX_VFO is the opposite to the TX_VFO + gEeprom.RX_VFO = (gEeprom.CROSS_BAND_RX_TX == CROSS_BAND_OFF || gEeprom.DUAL_WATCH != DUAL_WATCH_OFF) ? gEeprom.TX_VFO : !gEeprom.TX_VFO; gTxVfo = &gEeprom.VfoInfo[gEeprom.TX_VFO]; gRxVfo = &gEeprom.VfoInfo[gEeprom.RX_VFO];