190 likes | 420 Views
Case Study (ZigBee): Phase IV Transmitter & Receiver Simulation. Khurram Masood Abdul-Aziz .M Al-Yami. Physical Layer (PHY). The standard specifies the following four PHYs: An 868/915 MHz direct sequence spread spectrum (DSSS) PHY employing binary phase-shift keying (BPSK) modulation
E N D
Case Study (ZigBee): Phase IV Transmitter & Receiver Simulation KhurramMasoodAbdul-Aziz .M Al-Yami
Physical Layer (PHY) • The standard specifies the following four PHYs: • An 868/915 MHz direct sequence spread spectrum (DSSS) PHY employing binary phase-shift keying (BPSK) modulation • An 868/915 MHz DSSS PHY employing offset quadrature phase-shift keying (O-QPSK) modulation • An 868/915 MHz parallel sequence spread spectrum (PSSS) PHY employing BPSK and amplitude shift keying (ASK) modulation • A 2450 MHz DSSS PHY employing O-QPSK modulation
PHY – 868/915 MHz Mode The functional block diagram below is provided as a reference for specifying the 868/915 MHz band BPSK PHY modulation and spreading functions. Each bit in the PPDU shall be processed through the differential encoding, bit-to-chip mapping and modulation functions in octet-wise order, beginning with the Preamble field and ending with the last octet of the PSDU.
Differential Encoding • Differential encoding is the modulo-2 addition (exclusive or) of a raw data bit with the previous encoded bit. This is performed by the transmitter and can be described bythe following Equation: En = Rn ⊕En–1 • where Rn is the raw data bit being encoded En is the corresponding differentially encoded bit En–1 is the previous differentially encoded bit • For each packet transmitted, R1 is the first raw data bit to be encoded and E0 is assumed to be zero. • Conversely, the decoding process, as performed at the receiver, can be described by: Rn = En ⊕ En–1
Bit-to-chip mapping (DSSS) • Each input bit shall be mapped into a 15-chip PN sequence as specified in the below Table:
BPSK Modulation • The chip sequences are modulated onto the carrier using BPSK with raised cosine pulse shaping (roll-off factor = 1) where a chip value of one corresponds to a positive pulse and a chip value of zero corresponds to a negative pulse. The chip rate is 300 kchip/s for the 868 MHz band and 600 kchip/s in the 915 MHz band.
Pulse Shape • The raised cosine pulse shape (roll-off factor = 1) used to represent each baseband chip is described by:
Channel Model • Discrete Multipath fading channel • The channel parameters are: • 1- Sampling time is 1/(20KHz * 15 bits/code * 16 samples/bit) = 2.1e-7 • 2- Maximum Doppler frequency: • Indoor: λ= 3000000/868000000 = 0.3452 m let the speed indoor be 2 m/sec so fd = 2/ λ = 6 Hz • Outdoor: let the speed outdoor be 100 km/hr = 28 m/sec so fd = 28/ λ = 80 Hz • 3- Path delays: We can make multiple paths • 4- Power for each path is given as pdp. • Delay between paths = 8 samples = 0.5 *Ts • Signal Bandwidth (Lowpass equivalent) Bs = 10 kHz • Symbol time, Ts= 1/Bs = 0.1 msec • Data Rate = 20k sym/sec • Sampling rate = 4.8M samples/sec • Samples/symbol = 16
Simulation Steps • First, random data is generated. • The data is differentially encoded. • DSSS (bit to code) mapping is done according to the table in the standard. • Then BPSK modulation is done. • Data is upsampled by 16 (16 samples per symbol). • Modulated data is filtered using pulse shaping filter of raised cosine with rolloff factor = 1 The delay of because of the pulse shaping filter is 128 samples. • The pulse shaped data is passed through fading channel. • AWGN noise is added. • Data is downsampled. The delay for the faded channel and the pulse shaping filter is compensated. • Data is demodulated using BPSKDemodulation. • Data is decoded for the differential encoding done at the transmitter. • BER is computed
Comparison three-path FC One-path FC five-path FC
References • IEEE standard for 802.15.4 2006