Example of BPSK Modulation and Demodulation
Please run the MATLAB program digmod_ex.m under matlab5.
This program simulates the transmission of 100 bits/sec using BPSK. Additive noise is included at a level that can be changed via the SNR variable in the program. The carrier frequency is 1000 Hz. The demodulator consists of a coherent detector with perfect phase synchronization. "Scatter diagrams" of the received signal constellation are included to illustrate the benefits of matched filtering to reduce noise.
The pulse shape is square in this example, and there is no intersymbol interference (ISI). When ISI is present, it is handled with adaptive equalization, just like at baseband. The main difference is that with passband modulation, the equalizer must work on both the in-phase (I) and quadrature (Q) components of the coherently demodulated signal to remove ISI and noise.
Exercise with QPSK and a Training Sequence
Next consider the following QPSK constellation that is used to encode 2 bits per pulse:
00: -1 - j 1A simple way to think about this definition of QPSK is that the first bit is encoded in the I component and the second bit is encoded in the Q component.
01: -1 + j 1
10: +1 - j 1
11: +1 + j 1
The data file proj3.dat contains samples of the QPSK signal that encodes a sequence of 10 bits. Thus the signal contains 5 symbols or pulses. The QPSK signal is corrupted by additive noise, but not ISI. The carrier frequency is 1000 Hz and the sampling rate is 10,000 samples per second. However, the phase of the carrier for the coherent demodulator is not known.
In order to establish phase synchronization, it is known that the first 4 bits in the sequence are 0 0 1 1. These 4 bits are a "training sequence". Your job is to determine the proper phase for the coherent demodulator, and to recover the remaining 6 bits in the sequence.
The MATLAB program proj3.m does almost everything that you need. It reads the data file, performs coherent demodulation, and also performs matched filtering. You need to change the variable phi, which is the phase shift on the local oscillator in the coherent demodulator. The samples of the matched filter output for the I and Q components are available in the variables xITmf and xQTmf, respectively.
Please answer this question during class on Friday, May 1, and report your answer to me in class.