A complete reception scheme with Matlab
From Tools4SDR
Tutorial: Digital communication with linearly modulated sequence of symbols
|
| 1. General introduction |
| 2. Frequency offset estimation |
| 3. Channel impulse response estimation |
| 4. Synchronisation |
| 5. A simple receiver |
| 6. The complete scheme |
This page concludes the tutorial on the reception of a linearly modulated of sequence with Matlab.
It combines the algorithms developed in the different part of the tutorial to lead to a global receiver. The source code of this receiver is available for downloading here.
Note that this receiver is not robust. It rather aims to show the different issues met when performing a digital communication. If it does not work the first time, you will have to study it further to check which step has failed.
Getting the signal
The first step to decode the signal is to do an acquisition. The signal has been transmitted at 1MHz with the transmitter software, so the following code as been used with Matlab:
[sock] = SDR4All_Connect(0,'SlotA','RX'); [freq_min,freq_max] = SDR4All_GetFreq(sock); [gain_min,gain_max,gain_step] = SDR4All_GetGain(sock); SDR4All_SetGain(sock,(gain_max+gain_min)/2); SDR4All_SetDecimRate(sock,64); % set signal sampling period (and bandwidth) SDR4All_SetFreq(sock,2422e6); [Data] = SDR4All_GetData(sock,5*1000*1000); % 5s of signal
Decoding the image
The signal structure is described the transmitter software page. If you just want to decode the received signal, use the following script of the code:
[Appr_Seq] = ReadApprSeq('SeqQPSK.dat');
ReceiverScript
It should print the following information
Data normalisation... Frequency offset correction... Adaptative filter... Synchronisation to frame... Frame number estimation... Frame found: 656 The image is between indexes 671960 and 2523890 Synchronisation to image beginning frame... Decoding and uninterleaving Image estimation
And finally make appear the image:
The receiver in details
Let's detail the steps of the receiver:
- Data normalisation: to have an unit power signal
- Frequence offset correction: if not performed, you won't be able to do many things
- Adaptative filter: increase the SNR
- Frame number estimation: the receiver synchronises with the training sequence of the first frame received, and checks its number. Thanks to this information, the receiver is able to roughly locate the beginning of an image, and if the signal contains a full image.
- The receiver then performs once more a synchronisation step, but with frame #0.
- The simple receiver is applied on each frame to get the transmitted data. The interleaver is also removed.
- The image is built.

