Download as pdf or txt
Download as pdf or txt
You are on page 1of 9

VEERMATA JIJABAI TECHNOLOGICAL INSTITUTE

MUMBAI

DEPARTMENT OF ELECTRICAL ENGINEERING


THIRD YEAR B. TECH ELECTRONICS
DIGITAL COMMUNICATION LAB

EXPERIMENT NO.4

Submitted by:
Nikhil Nichite (171060041) (Batch A)
EXPERIMENT NO.4
AIM: To study about QPSK modulation technique used in Digital
Communication.
SOFTWARE: Scilab 6.0.2
THEORY:
1. Modulation is nothing but the superimposing of message signal m(t) on the
high frequency carrier signal c(t). There are two different types of
modulation techniques used i.e analog modulation and digital modulation.

2. For a better quality and efficient communication, digital modulation


technique is employed. The main advantages of the digital modulation over
analog modulation include available bandwidth, high noise immunity and
permissible power. In digital modulation, a message signal is converted
from analog to digital message, and then modulated by using a carrier
wave.
The carrier wave is switched on and off to create pulses such that the signal is
modulated. Similar to the analog modulation, in this system, the type of the digital
modulation is decided by the variation of the carrier wave parameters like
amplitude, phase and frequency.
3. QPSK (Quadrature Phase Shift Keying):
In BPSK we used two 2 symbols (namely 0 and 1). When we talk about QPSK
we have to use 4 symbols i.e. 00, 01, 10, 11. Quadrature Phase Shift Keying
(QPSK) is a form of Phase Shift Keying in which two bits are modulated at once,
selecting one of four possible carrier phase shifts (0, 90, 180, or 270 degrees)
symbolising every symbol. QPSK allows the signal to carry twice as much
information as ordinary PSK using the same bandwidth.

The QPSK Modulator uses a bit-splitter, two multipliers with local oscillator, a
2-bit serial to parallel converter, and a summer circuit. At the modulator’s input,
the message signal’s even bits (i.e., 2nd bit, 4th bit, 6th bit, etc.) and odd bits (i.e.,
1st bit, 3rd bit, 5th bit, etc.) are separated by the bits splitter and are multiplied
with the same carrier to generate odd BPSK (called as PSKI) and even BPSK
(called as PSKQ). The PSKQ signal is anyhow phase shifted by 90° before being
modulated. The QPSK waveform for two-bits input is as follows, which shows
the modulated result for different instances of binary inputs .
4. Offset and Non-offset QPSK:
Offset quadrature phase-shift keying (OQPSK) is a variant of phase-shift
keying modulation using four different values of the phase to transmit. It is
sometimes called staggered quadrature phase-shift keying (SQPSK).
Difference of the phase between QPSK and OQPSK:

Taking four values of the phase (two bits) at a time to construct a QPSK
symbol can allow the phase of the signal to jump by as much as 180° at a time.
When the signal is low-pass filtered (as is typical in a transmitter), these phase-
shifts result in large amplitude fluctuations, an undesirable quality in
communication systems. By offsetting the timing of the odd and even bits by
one bit-period, or half a symbol-period, the in-phase and quadrature
components will never change at the same time. In the constellation diagram
shown on the right, it can be seen that this will limit the phase-shift to no more
than 90° at a time. This yields much lower amplitude fluctuations than non-
offset QPSK and is sometimes preferred in practice.
The picture shows the difference in the behavior of the phase between ordinary
QPSK and OQPSK.
SCILAB CODE:
clc
clear
close
funcprot(0);
// QPSK Modulation
function []=qpsk(g, f)
//g is a binay vector; f is the carrier frequency.
// Number of arguments in function call
[%nargout,%nargin] = argn(0)

if %nargin>2 then
error("Too many input arguments");
elseif %nargin==1 then
f = 1;
end;

if f<1 then
error("Frequency must be bigger than 1");
end;

l = max(size(g));
r = l/2;
re = ceil(r);
val = re-r;

if val~=0 then
error("Please insert a vector divisible for 2");
end;

t = 0:(2*%pi)/99:2*%pi;
cp = [];sp = [];
mod = [];mod1 = [];bit = [];
for n = 1:2:max(size(g))
if g(n)==0 & g(n+1)==1;
die = (sqrt(2)/2)*ones(1,100);
die1 = -(sqrt(2)/2)*ones(1,100);
se = [zeros(1,50),ones(1,50)];
elseif g(n)==0 & g(n+1)==0;
die = -(sqrt(2)/2)*ones(1,100);
die1 = -(sqrt(2)/2)*ones(1,100);
se = [zeros(1,50),zeros(1,50)];
elseif g(n)==1 & g(n+1)==0;
die = -(sqrt(2)/2)*ones(1,100);
die1 = (sqrt(2)/2)*ones(1,100);
se = [ones(1,50),zeros(1,50)];
elseif g(n)==1 & g(n+1)==1;
die = (sqrt(2)/2)*ones(1,100);
die1 = (sqrt(2)/2)*ones(1,100);
se = [ones(1,50),ones(1,50)];
end;
c = cos(f*t);
s = sin(f*t);
cp = [cp,die]; //Amplitude cosino
sp = [sp,die1]; //Amplitude sino
mod = [mod,c]; //cosino carrier (Q)
mod1 = [mod1,s]; //sino carrier (I)
bit = [bit,se];
end;
bpsk = cp .*mod+sp .*mod1;
bpsk1=cp .*mod;
bpsk2=sp .*mod1;
/*subplot(4,1,1);
plot(bit,'r',"LineWidth",2.0);set(gca(),"grid",[1,1]);
xlabel("Time-->")
ylabel("Amplitude-->")
title("Message Binary Signal")
set(gca(),"data_bounds",matrix([0,50*max(size(g)),-1.5,1.5],2,-1));

subplot(4,1,2);
plot(cp,'r',"LineWidth",2.0);set(gca(),"grid",[1,1]);
xlabel("Time-->")
ylabel("Amplitude-->")
title("Even Message Binary Signal")
set(gca(),"data_bounds",matrix([0,50*max(size(g)),-1.5,1.5],2,-1));

subplot(4,1,3);
plot(sp,'r',"LineWidth",2.0);set(gca(),"grid",[1,1]);
xlabel("Time-->")
ylabel("Amplitude-->")
title(" Odd Message Binary Signal")
set(gca(),"data_bounds",matrix([0,50*max(size(g)),-1.5,1.5],2,-1));

subplot(4,1,4);
plot(mod,'y',"LineWidth",3.0);set(gca(),"grid",[1,1]);
xlabel("Time-->")
ylabel("Amplitude-->")
title("Cosine Carrier Signal")
set(gca(),"data_bounds",matrix([0,50*max(size(g)),-1.5,1.5],2,-1));*/

// NOTE: SINCE 8 PLOT WAS NOT PROPERLY REPRESENTED IN AN SINGLE GRAPH.


WE SPLITTED THE PLOTTING PART IN TWO WAYS BY COMMENTING 1 GROUP AT A TIME
TO GET PROPER VISUALISATION.

subplot(4,1,1);
plot(mod1,'y',"LineWidth",3.0);set(gca(),"grid",[1,1]);
xlabel("Time-->")
ylabel("Amplitude-->")
title("Sine Carrier Signal ")
set(gca(),"data_bounds",matrix([0,50*max(size(g)),-1.5,1.5],2,-1));

subplot(4,1,2);
plot(bpsk1,'g',"LineWidth",3.0);set(gca(),"grid",[1,1]);
xlabel("Time-->")
ylabel("Amplitude-->")
title("Even Modulated Signal")
set(gca(),"data_bounds",matrix([0,50*max(size(g)),-1.5,1.5],2,-1));

subplot(4,1,3);
plot(bpsk2,'g',"LineWidth",3.0);set(gca(),"grid",[1,1]);
xlabel("Time-->")
ylabel("Amplitude-->")
title("Odd Modulated Signal")
set(gca(),"data_bounds",matrix([0,50*max(size(g)),-1.5,1.5],2,-1));

subplot(4,1,4);
plot(bpsk,'b',"LineWidth",2.0);set(gca(),"grid",[1,1]);
xlabel("Time-->")
ylabel("Amplitude-->")
title("QPSK modulated signal")
set(gca(),"data_bounds",matrix([0,50*max(size(g)),-1.5,1.5],2,-1))

endfunction

OUTPUT:
Plot 1: Original Message Signal with each symbol Tb duration.
Plot 2: Even Message signal with each symbol of 2Tb duration.
Plot 3: Odd Message signal with each symbol of 2Tb duration.
Plot 4: Cosine Carrier Signal.
Plot 5: Sine Carrier Signal.
Plot 6: Even modulated signal.
Plot 7: Odd modulated signal.
Plot 8: Addition of even and odd modulated signal resulting into QPSK.
CONCLUSION:
1. In this experiment we studied QPSK modulation technique.
2. The Quadrature Phase Shift Keying QPSK is a variation of BPSK, and it is
also a Double Side Band Suppressed Carrier DSBSC modulation scheme,
which sends two bits of digital information at a time, called as bigits.
3. Instead of the conversion of digital bits into a series of digital stream, it
converts them into bit pairs. This decreases the data bit rate to half, which
allows space for the other users.
4. In BPSK we used two 2 symbols (namely 0 and 1). But here in QPSK we
have used 4 symbols i.e. 00, 01, 10, 11.
5. In QPSK maximum phase shift is limited to about 90 degree and first
input bit stream is split into two bit streams referred as odd and even.
These streams are applied simultaneously to the mixers while in OQPSK
maximum phase shift is about +/- 90 degree. In this after splitting the bit
stream into odd and even, one bit stream is made offset by 1 bit period
with respect to the other. After this, the direct and shifted bit streams are
fed to the mixers.
6. At the modulator’s input, the message signal’s even bits (i.e., 2 nd bit, 4th
bit, 6th bit, etc.) and odd bits (i.e., 1st bit, 3rd bit, 5th bit, etc.) are separated
by the bits splitter and are multiplied with the same carrier to generate
odd BPSK (called as PSKI) and even BPSK (called as PSKQ). The PSKQ
signal is anyhow phase shifted by 90° before being modulated.

You might also like