Changes between Version 4 and Version 5 of WARPLab/Examples/OFDM
- Timestamp:
- Feb 21, 2014, 11:28:19 AM (10 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
WARPLab/Examples/OFDM
v4 v5 3 3 File: [source:/ResearchApps/PHY/WARPLAB/WARPLab7/M_Code_Examples/wl_example_siso_ofdm_txrx.m wl_example_siso_ofdm_txrx.m] 4 4 5 This WARPLab example implements a SISO OFDM transmitter and receiver. 5 This WARPLab example implements a SISO OFDM transmitter and receiver. 6 7 '''Important:''' this script is not intended as a tutorial of OFDM. If you're not already familiar with the basics of OFDM please start with one of the many good [https://www.google.com/search?q=ofdm+tutorial OFDM tutorials] available online. You will need to know the basics of OFDM before understanding the Tx and Rx processing in this example. 6 8 7 9 == Transmitter == … … 38 40 To use the example in simulation mode set the top-level param {{{USE_WARPLAB_TXRX = 0;}}}, then run the m-script. When the script finishes 6 plots will show: 39 41 40 || [[Image(wl_ofdm_plots_sim_txIQ.png,nolink)]][[BR]]Transmitted waveform || [[Image(wl_ofdm_plots_sim_rxIQ.png,nolink)]] [[BR]]Received waveform || [[Image(wl_ofdm_plots_sim_ltsCorr.png,nolink)]] [[BR]]Preamble correlation results 41 || [[Image(wl_ofdm_plots_sim_chanEst.png,nolink)]] [[BR]]Channel estimate per subcarrier 42 || [[Image(wl_ofdm_plots_sim_txIQ.png,nolink)]][[BR]]Transmitted waveform || [[Image(wl_ofdm_plots_sim_rxIQ.png,nolink)]] [[BR]]Received waveform || [[Image(wl_ofdm_plots_sim_ltsCorr.png,nolink)]] [[BR]]Preamble correlation results[[BR]](peaks indicate locations of preamble LTS) || 43 || [[Image(wl_ofdm_plots_sim_chanEst.png,nolink)]] [[BR]]Channel estimate per subcarrier[[BR]](I/Q components and complex magnitude) || [[Image(wl_ofdm_plots_sim_phaseError.png,nolink)]] [[BR]]Phase error per OFDM symbol based on pilot tones || [[Image(wl_ofdm_plots_sim_constellations.png,nolink)]] [[BR]]Tx and Rx constellations || 42 44 43 45 By default the simulation script applies AWGN with an arbitrary fixed SNR. You can change the simulated propagation characteristics in the m-code. Search for {{{AWGN}}} and apply whatever Tx->Rx degradations you like. 44 46 45 For example to simulate a perfect (noiseless) link, set the noise power to zero: {{{rx_vec_air = tx_vec_air + 0*complex(randn(1,length(tx_vec_air)), randn(1,length(tx_vec_air))); }}}. 47 For example to simulate a perfect (noiseless) link, set the noise power to zero: 48 {{{ 49 rx_vec_air = tx_vec_air + 0*complex(randn(1,length(tx_vec_air)), randn(1,length(tx_vec_air))); 50 }}} 46 51 47 52 The script also prints statistics about the experiment to the MATLAB command prompt: … … 57 62 58 63 === Hardware in the Loop === 59 To use the example with WARP hardware you will need two WARP nodes each running WARPLab 7.3 (or later) and a WARPLab environment setup on your PC. Refer to the [wiki:../ QuickStart WARPLab Quick Start] if you have not yet setup WARPLab.64 To use the example with WARP hardware you will need two WARP nodes each running WARPLab 7.3 (or later) and a WARPLab environment setup on your PC. Refer to the [wiki:../../QuickStart WARPLab Quick Start] if you have not yet setup WARPLab. 60 65 61 66 To target WARP hardware set the top-level param {{{USE_WARPLAB_TXRX = 1;}}}, then run the m-script. When the script finishes 6 plots will show: