Calculate HackRF center frequency correctly

This commit is contained in:
Thomas Kolb 2024-04-20 01:07:21 +02:00
parent 32632914df
commit 7d1a927425

View file

@ -253,7 +253,7 @@ result_t sdr_start_tx(sdr_ctx_t *ctx, size_t burst_size)
int result; int result;
result = hackrf_set_freq(ctx->hackrf, SDR_TX_FREQ); result = hackrf_set_freq(ctx->hackrf, SDR_TX_FREQ - SDR_TX_IF_SHIFT);
CHECK_HACKRF_RESULT(result, "hackrf_set_freq"); CHECK_HACKRF_RESULT(result, "hackrf_set_freq");
result = hackrf_set_sample_rate(ctx->hackrf, SDR_TX_SAMPLING_RATE); result = hackrf_set_sample_rate(ctx->hackrf, SDR_TX_SAMPLING_RATE);