RF Impairments & Corrections
Est. read time: 1 minute | Last updated: July 06, 2025 by John Gentile
Contents
from IPython.display import YouTubeVideo
import numpy as np
import matplotlib.pyplot as plt
YouTubeVideo('PNMOwhEHE6w')
YouTubeVideo('LBLvmNyAdSI')
Noise
DC Offset Removal
I/Q Offset Correction
Wireless Channels
N = 5000000
EbNodB_range = range(11)
itr = len(EbNodB_range)
ber = [None]*itr
for n in range (itr):
EbNodB = EbNodB_range[n]
EbNo=10.0**(EbNodB/10.0)
x = 2 * (np.random.rand(N) >= 0.5) - 1
noise_std = 1/np.sqrt(2*EbNo)
y = x + noise_std * np.random.randn(N)
y_d = 2 * (y >= 0) - 1
errors = (x != y_d).sum()
ber[n] = 1.0 * errors / N
plt.figure()
plt.plot(EbNodB_range, ber, 'bo', EbNodB_range, ber, 'k')
plt.axis([0, 10, 1e-6, 0.1])
plt.xscale('linear')
plt.yscale('log')
plt.xlabel('EbNo(dB)')
plt.ylabel('BER')
plt.grid(True)
plt.title('BPSK Modulation')
plt.show()
References
- Direct Conversion (Zero-IF) Receiver - Wireless Pi
- Digitally Removing a DC Offset: DSP Without Mathematics
- What does correcting I/Q do? - DSP Stack Exchange