diff --git a/src/main.c b/src/main.c index 3b39512..824a5c7 100644 --- a/src/main.c +++ b/src/main.c @@ -543,6 +543,7 @@ static void rf_rx(void) int64_t Q = sQ; I *= gain; + I -= max_amplitude / 2 + 1; I /= max_amplitude; if (I > 127) @@ -553,6 +554,7 @@ static void rf_rx(void) *blockptr++ = (uint8_t)I + 128; Q *= gain; + Q -= max_amplitude / 2 + 1; Q /= max_amplitude; if (Q > 127)