Correctly show channel frequencies in spectrum view when swapping SDR links
This commit is contained in:
@@ -267,6 +267,15 @@ void *sdr_open(const char __attribute__((__unused__)) *device, double *tx_freque
|
||||
goto error;
|
||||
}
|
||||
|
||||
/* swap links, if required */
|
||||
if (sdr_config->swap_links) {
|
||||
double *temp;
|
||||
PDEBUG(DSDR, DEBUG_NOTICE, "Sapping RX and TX frequencies!\n");
|
||||
temp = rx_frequency;
|
||||
rx_frequency = tx_frequency;
|
||||
tx_frequency = temp;
|
||||
}
|
||||
|
||||
if (tx_frequency) {
|
||||
/* calculate required bandwidth (IQ rate) */
|
||||
|
||||
@@ -458,14 +467,6 @@ void *sdr_open(const char __attribute__((__unused__)) *device, double *tx_freque
|
||||
}
|
||||
}
|
||||
|
||||
if (sdr_config->swap_links) {
|
||||
double temp;
|
||||
PDEBUG(DSDR, DEBUG_NOTICE, "Sapping RX and TX frequencies!\n");
|
||||
temp = rx_center_frequency;
|
||||
rx_center_frequency = tx_center_frequency;
|
||||
tx_center_frequency = temp;
|
||||
}
|
||||
|
||||
display_iq_init(samplerate);
|
||||
display_spectrum_init(samplerate, rx_center_frequency);
|
||||
|
||||
|
Reference in New Issue
Block a user