MATLAB Examples

802.11p and 802.11a Packet Error Rate Simulations

This example shows how to measure packet error rates of IEEE® 802.11p™ and 802.11a™ links using an end-to-end simulation with a fading channel model and additive white Gaussian noise. For similar link parameters, the two links are simulated alongside to offer a comparative perspective using the packet error rate as the figure of merit. The comparison highlights the robustness of the 802.11p link when compared with the 802.11a link.



IEEE 802.11p [ 2 ] is an approved amendment to the IEEE 802.11™ standard to enable support for wireless access in vehicular environments (WAVE). Using the half-clocked mode with a 10 MHz channel bandwidth, it operates at the 5.85-5.925 GHz bands to support applications for Intelligent Transportation Systems (ITS) [ 3 ].

In this example an end-to-end simulation is used to determine the packet error rates for 802.11p [ 2 ] and 802.11a [ 1 ] links with a fading channel at a selection of SNR points. For each SNR point multiple packets are transmitted through a fading channel, demodulated and the PSDUs recovered. The PSDUs are compared to those transmitted to determine the number of packet errors. Front-end components including packet detection, timing synchronization, carrier frequency offset correction and phase tracking are optionally enabled for the receiver. A schematic for the per-link processing is shown below.

Waveform Configuration

In this example non-HT format transmissions are simulated. For 802.11p, a 10 MHz channel bandwidth is used while for 802.11a a 20 MHz channel bandwidth is used. The two individual format parameters are specified using non-HT format configuration objects by the wlanNonHTConfig function. In this example both links are configured for 16QAM rate 1/2 (MCS 4) operation.

% Link parameters
mcs = 4;                % QPSK rate 1/2
psduLen = 1000;         % PSDU length in bytes

% Create a format configuration object for a 802.11p transmission
cfgNHT10 = wlanNonHTConfig;
cfgNHT10.ChannelBandwidth = 'CBW10';    % 10 MHz channel bandwidth
cfgNHT10.PSDULength = psduLen;
cfgNHT10.MCS = mcs;

% Create a format configuration object for a 802.11a transmission
cfgNHT20 = wlanNonHTConfig;
cfgNHT20.ChannelBandwidth = 'CBW20';    % 20 MHz channel bandwidth
cfgNHT20.PSDULength = psduLen;
cfgNHT20.MCS = mcs;

Channel Configuration

Both 802.11a and 802.11p are single antenna transmit systems. The difference in the channel bandwidth between the two links leads to a doubling of the signaling duration as seen by the following table which highlights the parametric differences for the two.

The example uses a HIPERLAN/2 SISO fading channel model with delay profile Model-E representing NLOS conditions with an average RMS delay spread of 250 ns [ 4 ]. Model-E corresponds to a large open space environment with NLOS propagation. The large delay spread makes it applicable for outdoor vehicular operation. HIPERLAN/2 channel models with different delay profiles can be modeled using the comm.RayleighChannel function.

% Create and configure the channel
fd = 50;                            % Maximum Doppler shift, Hz
c = 3e8*3.6;                        % Speed of light, Km/hr
fc = 5.9e9;                         % Carrier frequency, Hz
disp(['Speed of unit = ' num2str(c*fd/5.9e9) ' Km/hr at ' num2str(fc/1e9) ' GHz']);

fs20 = wlanSampleRate(cfgNHT20);    % Baseband sampling rate for 20 MHz

% Path delays (s) and average path gains (dB) for HiperLAN/2 Model-E
PathDelays = [0 10 20 40 70 100 140 190 240 320 430 560 710 880 1070 ...
    1280 1510 1760] * 1e-9;
AveragePathGains = [-4.9 -5.1 -5.2 -0.8 -1.3 -1.9 -0.3 -1.2 -2.1 0.0 ...
    -1.9 -2.8 -5.4 -7.3 -10.6 -13.4 -17.4 -20.9];

chan20 = comm.RayleighChannel(...
            'PathDelays',           PathDelays, ...
            'AveragePathGains',     AveragePathGains, ...
            'SampleRate',           fs20,...
            'MaximumDopplerShift',  fd);

fs10 = wlanSampleRate(cfgNHT10);    % Baseband sampling rate for 10 MHz
chan10 = comm.RayleighChannel(...
            'PathDelays',           PathDelays, ...
            'AveragePathGains',     AveragePathGains, ...
            'SampleRate',           fs10, ...
            'MaximumDopplerShift',  fd);
Speed of unit = 9.1525 Km/hr at 5.9 GHz

Simulation Parameters

The operating SNR value per MCS value is simulated over a range of SNR points. For each SNR point simulated, a number of packets are generated, passed through the channel and demodulated to determine the packet error rate.

fadingMargin = 12; % dB
snrOperatingVec = [-1 1.75 2 4.75 7.5 10.75 15 16.5] + fadingMargin;
simRange = -2:1:1;
snr = snrOperatingVec(mcs+1) + simRange;

enableFE = false;    % Disable front-end receiver components

Simulation Setup

Set up the simulation length per SNR point using a maximum number of packets and a maximum number of errors to be simulated, whichever occurs first.

maxNumErrors = 20;   % The maximum number of packet errors at an SNR point
maxNumPackets = 200; % Maximum number of packets at an SNR point

% Set random stream for repeatability of results
s = rng(98765);

Processing SNR Points

For each SNR point a number of packets are tested and the packet error rate calculated for both links. For each packet the following processing steps occur:

  1. A PSDU is created and encoded to create a single packet waveform.
  2. The waveform is passed through a different realization of the channel model.
  3. AWGN is added to the received waveform to create the desired average SNR per subcarrier after OFDM demodulation.
  4. Using the optional switch enableFE, front-end receiver components may be enabled. When enabled, the per-packet processing includes packet detection, coarse carrier frequency offset estimation and correction, symbol timing and fine carrier frequency offset estimation and correction. When disabled, the received waveform is synchronized using the known channel delay.
  5. The L-LTF is extracted from the synchronized received waveform. The L-LTF is OFDM demodulated and channel estimation using the L-LTF is performed.
  6. The non-HT Data field is extracted from the synchronized received waveform. The PSDU is recovered using the extracted data field and the L-LTF based channel estimate and noise power estimate.

Refer to accompanying nonHTPERSimulator.m function for the processing details.

% Set up a figure for visualizing PER results
h = figure;
grid on;
hold on;
ax = gca;
ax.YScale = 'log';
xlim([snr(1), snr(end)]);
ylim([1e-3 1]);
xlabel('SNR (dB)');
h.NumberTitle = 'off';
h.Name = '802.11p vs. 802.11a PER';
title(['MCS ' num2str(mcs) ', HIPERLAN/2 Model E' ...
       ', Doppler ' num2str(fd) ' Hz']);

% Simulation loop for both links
S = numel(snr);
per20 = zeros(S,1);
per10 = per20;
for i = 1:S
    % 802.11p link
    per10(i) = nonHTPERSimulator(cfgNHT10, chan10, snr(i), ...
        maxNumErrors, maxNumPackets, enableFE);

    % 802.11a link
    per20(i) = nonHTPERSimulator(cfgNHT20, chan20, snr(i), ...
        maxNumErrors, maxNumPackets, enableFE);

    % Compare
    semilogy(snr, per10, 'bx-');
    semilogy(snr, per20, 'ro-');
    legend('802.11p, 10 MHz', '802.11a, 20 MHz');
axis([5 35 5e-3 1])
hold off;

% Restore default stream
CBW10, SNR 17.5 completed after 130 packets, PER: 0.16154
CBW20, SNR 17.5 completed after 99 packets, PER: 0.21212
CBW10, SNR 18.5 completed after 201 packets, PER: 0.079602
CBW20, SNR 18.5 completed after 128 packets, PER: 0.16406
CBW10, SNR 19.5 completed after 201 packets, PER: 0.074627
CBW20, SNR 19.5 completed after 117 packets, PER: 0.17949
CBW10, SNR 20.5 completed after 201 packets, PER: 0.039801
CBW20, SNR 20.5 completed after 160 packets, PER: 0.13125


Observe the improved performance of the 10 MHz link for the high delay spread channel, when compared with the similarly configured 20 MHz link. The longer cyclic prefix duration for 10 MHz operation mitigates the large delay spread of the channel and offers increased robustness for outdoor operation.

The number of packets tested at each SNR point is controlled by two parameters; maxNumErrors and maxNumPackets. For meaningful results, it is recommended that these values should be larger than those presented in this example. Increasing the number of packets simulated allows the PER under different scenarios to be compared. As an example, the figure below was created by running the example for a simRange: -8:1:6, maxNumErrors: 1000 and maxNumPackets: 10000.

Further Exploration

This example highlights PER performance for only one of eight allowed MCS values. Explore link performance for other MCS values, varied Doppler shifts, different channel delay profiles and different receiver configurations.

Alternate channel estimation and phase tracking algorithms that allow for higher speeds as needed by vehicular applications should also be considered.


This example uses the following helper functions:

Selected Bibliography

  1. IEEE Std 802.11-2012: IEEE Standard for Information technology - Telecommunications and information exchange between systems - Local and metropolitan area networks - Specific requirements, Part 11: Wireless LAN Medium Access Control (MAC) and Physical Layer (PHY) Specifications, IEEE, New York, NY, USA, 1999-2013.
  2. IEEE Std 802.11p-2010: IEEE Standard for Information technology - Telecommunications and information exchange between systems - Local and metropolitan area networks - Specific requirements, Part 11: Wireless LAN Medium Access Control (MAC) and Physical Layer (PHY) Specifications, Amendment 6: Wireless Access in Vehicular Environments, IEEE, New York, NY, USA, 2010.
  3. ETSI,
  4. Medbo, J., P. Schramm, "Channel Models for HIPERLAN/2 in Different Indoor Scenarios", ETSI/BRAN document no. 3ERI085B, 1998.