Adc Lab Manual Vr2076
Adc Lab Manual Vr2076
Prepared
By
Visio
n
To produce globally competitive and socially sensitized engineering graduates and to bring out
quality research in the frontier areas of Electronics & Communication Engineering.
Mission
To provide quality and contemporary education in the domain of Electronics & Communication
Engineering through periodically updated curriculum, best of breed laboratory facilities,
collaborative ventures with the industries and effective teaching learning process.
To pursue research and new technologies in Electronics & Communication Engineering and
related disciplines in order to serve the needs of the society, industry, government and scientific
community.
PEO 3. Adapt to emerging technologies for sustenance in their relevant areas of interest.
20EC4353 VR20 Regulations Analog & Digital Communications
PSO1 Demonstrate proficiency in the use of IOT required in real life applications.
Implement functional blocks of hardware / software designs for signal processing and
PSO2
communication applications.
20EC4353 VR20 Regulations Analog & Digital Communications
1. All students must observe the dress Code while in the laboratory.
2. All bags must be left at the indicated place.
3. The lab timetable must be strictly followed.
4. Be PUNCTUAL for your laboratory session.
5. Workspace must be kept clean and tidy at all time.
6. Handle the systems and equipment with care.
7. All students are liable for any damage to the accessories due to their own negligence.
8. Students are strictly PROHIBITED from taking out any items from the laboratory.
9. Report immediately to the Lab Supervisor if any malfunction of the accessories, is there.
10. Return the components/meters, turn off the system properly before leaving the lab
20EC4353 VR20 Regulations Analog & Digital Communications
Course Upon successful completion of the course, the student will be able to:
outcomes
CO1 Experimentally verify the working of AM and FM techniques using hardware
and simulation
CO2 Experimentally verify the working of Digital modulation techniques and pulse
transmission using hardware and simulation
Contribution PO PO PO PO PO PO PO PO PO PO PO PO PSO PSO
of Course 1 2 3 4 5 6 7 8 9 10 11 12 1 2
Outcomes
towards CO1
achievement 1 2 2
of Program
Outcomes (1– CO2
Low,2
1 2 2
-Medium, 3–
High)
Course Experiments using Hardware (using Discrete Components):
Content
1. Generation and detection of Amplitude Modulated signal
2. Generation and detection of Frequency Modulated signal
3. Generation and detection of DSB SC Modulated signal
4. Generation and Detection of PCM signal
5. Generation and Detection of DM signal
6. Generation and Detection of ASK, FSK and PSK signal
Experiment 1
AMPLITUDE MODULATION AND DEMODULATION
AIM:
To perform Amplitude modulation for the baseband signal, analyze and interpret the data.
REQUIREMENTS:
Resistors R1, R2, R3,R4 1KΩ
R5,R9 10 KΩ
R6, R8 47KΩ
R7 Potentiometer 10KΩ
R10 6.8KΩ
R11, R12 3.9KΩ
R13 100KΩ
Capacitors C1,C2, C3,C4 0.1μF
C5 (Variable) 10nF/1nF/2nF
Diode OA79
Regulated Power Supply
Function Generator
Cathode Ray
Oscilloscope
BLOCK DIAGRAM:
Message Input AM
(1V P-P 5K Using IC1496
Hz) AM Output
Carrier
(1V P-P 100K Hz)
CIRCUIT DIAGRAM:
Fig: Demodulation
CALCULATIONS:
V max V min
1. Modulation index m
V max V min
PROCEDURE: (MODULATION)
1. The connections are to be made according to the circuit diagram as shown in the figure.
2. A modulating signal has to be given from the function generator with an amplitude 1V peak
to peak and frequency <5 KHz at the appropriate terminals of the circuit.
20EC4353 VR20 Regulations Analog & Digital Communications
3. The carrier signal has to be applied from another function generator with an amplitude 5V
peak to peak and frequency >100 KHz at the suitable terminals of the circuit.
4. The required adjustments are to be made with the 47 KΩ potentiometer to get the desired output.
5. The under, critical and over modulation case are to be observed by connecting the DSO at
the output terminals of the circuit.
6. The modulation index should be calculated by substituting the values in the formula given.
(DEMODULATION):
MODEL WAVEFORMS:
20EC4353 VR20 Regulations Analog & Digital Communications
RESULTS:
Amplitude : Amplitude :
Frequency : Frequency :
Under Modulation
Critical Modulation
Over Modulation
Demodulated signal
Amplitude : Frequency :
20EC4353 VR20 Regulations Analog & Digital Communications
Experiment 2
FREQUENCY MODULATION AND DEMODULATION
AIM:
To perform Frequency Modulation for the baseband signal, analyze and interpret the data.
REQUIREMENTS:
R1,R9,R10 100KΩ
R2 100Ω
R3,R7 10KΩ
R4,R12 47KΩ
R5,R6 4.7KΩ
R8 1MΩ
R11 1KΩ
C1,C2,C3 10μF
C4,C5,C9,C11,C12 10nF
C6 1nF
C7,C8,C10 2nF
DIODE 0A79
IC XR2206
IC TL084
Regulated Power Supply
Function Generator
Cathode Ray
Oscilloscope
BLOCK DIAGRAM:
(MODULATION)
Message Input
Frequency Modulation
Using XR 2206 FM Output
(Carrier Inbuilt)
(DEMODULATION)
CIRCUIT DIAGRAMS:
CALCULATIONS:
f f max f min
fm f 2
PROCEDURE: (MODULATION)
1. The connections are to be made according to the circuit diagram as shown in the figure.
2. Without applying the message signal from the function generator, the carrier signal should
be observed and corresponding amplitude and frequency are to be noted.
20EC4353 VR20 Regulations Analog & Digital Communications
3. A message signal should be applied from the function generator at the appropriate terminals
in the circuit with amplitude 20V peak to peak and frequency <1KHz.
4. The adjustments of the signals should be made to observe the frequency modulated signal
clearly on the DSO.
5. From the frequency modulated waveform fmax & fmin are to be noted.
6. The modulation index has to be calculated using the formulae
(DEMODULATION)
RESULT:
20EC4353 VR20 Regulations Analog & Digital Communications
Amplitude : Amplitude :
Frequency : Frequency :
Modulation index
fmax
fmin
∆f = (fmax- fmin) / 2
β = ∆f / fm
Demodulated signal
Amplitude : Frequency :
1. What will be the change in the wave under FM when the amplitude or frequency of the
modulating signal is increased?
2. The FM station has less noise while receiving the signal. Justify your answer?
3. What happens when a stronger signal and a weaker signal both overlap at the same frequency in
FM?
4. What is the band width for FM?
5. Define Frequency Deviation?
20EC4353 VR20 Regulations Analog & Digital Communications
Experiment 3
DSBSC MODULATION AND DEMODULATION
AIM:
To Perform DSBSC modulation for the baseband signal, analyze and interpret the data.
REQUIREMENTS:
R1,R2,R3,R4,R13,R16 1KΩ
R5,R9,R15 10KΩ
R6,R8 47KΩ
R7 100KΩ
R10 6.8KΩ
R11,R12 3.9KΩ
R14,R19,R20 2.2KΩ
R15 220Ω
R17 100KΩ
R2 100Ω
C1,C2,C3,C4,C5,C6,C7,C8,C11 0.1μF
C9 1Μf
C10 2μF
C12 1nf
IC MC1496
Regulated Power Supply
Function Generator
Cathode Ray Oscilloscope
BLOCK DIAGRAM:
20EC4353 VR20 Regulations Analog & Digital Communications
CIRCUIT DIAGRAM:
17
20EC4353 VR20 Regulations Analog & Digital Communications
PROCEDURE: (MODULATION)
1. The connections are to be made according to the circuit diagram as shown in the figure.
2. A modulating signal has to be given from the function generator with an amplitude 1V peak
to peak and frequency <5 KHz at the appropriate terminals of the circuit.
3. The carrier signal has to be applied from another function generator with an amplitude 5V
peak to peak and frequency >100 KHz at the suitable terminals of the circuit.
4. The required adjustments are to be made with the 47 KΩ potentiometer to get the desired output.
5. The DSO probe should be connected at the output terminals and the modulated signal has to
be observed.
PROCEDURE: (DEMODULATION):
MODEL WAVEFORMS:
Message
Carrier
DSBSC Wave
18
20EC4353 VR20 Regulations Analog & Digital Communications
RESULT:
Amplitude : Amplitude :
Frequency : Frequency :
DSBSC signal
Amplitude : Frequency :
Demodulated signal
Amplitude : Frequency :
19
20EC4353 VR20 Regulations Analog & Digital Communications
20
20EC4353 VR20 Regulations Analog & Digital Communications
Experiment 4
GENERATION AND DETECTION OF
AIM PCM
:
21
20EC4353 VR20 Regulations Analog & Digital Communications
CIRCUIT DIAGRAM:
SCHEMNTIC DIAGRAM:
PROCEDURE: MODULATION
22
20EC4353 VR20 Regulations Analog & Digital Communications
1. It should be ensured that group 3 clock is selected in the clock generation section pf the kit.
Selection can be done with the help of switch S1. The corresponding LED indication can be
observed.
2. The jumper J3 must be kept in the fast mode position
3. The selected clock frequency 230 KHz should be available at the TXCLK post.
4. The 250 KHz signal having voltage around 4V should be connected from the function generator
to the ADC post of the A/D convertor.
5. The switch S12 is to be made to the NONE parity mode and the corresponding LED should
be observed.
6. The A/D converted bits are to be observed on the LED indicators (B0-B6) in the ADC section
7. The pseudo random bit sequence at the test point marked is to be noted as PRBS OUT.
8. TX DATA post shows the multiplexed data having PRBS & PCM data.
9. To provide the timing and sync information to the receiver section, the TX CLK post has to
be connected to RX CLK and the TX DATA should be connected to the RX DATA.
10. The recovered sync can be observed at the SYNC OUT post.
11. The SYNC OUT post should now be connected to the RX SYNC post.
12. The serial to parallel converted data on the corresponding LED indication can be observed in
the Data Latch section.
13. The D/A converted output data can be observed on the DACOUT post.
14. The DAC OUT post should now be connected to the IN33 post of the second order filter and
OUT#) should be connected to IN#$ of the 4th order LPF.
15. The recovered signal can be observed at OUT31 Post of the 4th order filter
23
20EC4353 VR20 Regulations Analog & Digital Communications
24
20EC4353 VR20 Regulations Analog & Digital Communications
RESULT:
25
20EC4353 VR20 Regulations Analog & Digital Communications
2. The signal to quantization noise ratio in a PCM system depends on what criteria?
5. Define companding and state the need for companding in a PCM system?
26
20EC4353 VR20 Regulations Analog & Digital Communications
Experiment 5
GENERATION AND DETECTION OF
AIM: DM
Comparator
AF Signal
DM Signal
TL084 L
M
339
UP DOWN
COUNTER
D/A Convertor
CLOCK
INPUT 4 KHz
27
20EC4353 VR20 Regulations Analog & Digital Communications
PROCEDURE: DM Modulator:
1. The group5 (GP5) clock has to be selected in the clock generation section.
2. This selection can be done with the help of switch S! and the corresponding LED indication has
to be observed.
3. The transmitter clock frequency 8KHz has to be selected using switch S2 and the selected clock
is indicated on the corresponding LED indication in the Clock generation section.
4. The 250KHZ sine signal having amplitude of 0V is connected to IN13 post and TXCLK post
is connected to the CLK Delta POST of Digital Sampler.
5. The switch s5 is to be moved to Delta Position.
6. The OUT8 post of Digital sampler should be connected to IN 15 post of Integrator1.
7. The OUT9 post of integrator should be given to IN14 post of Digital Sampler.
8. The delta modulated output can be observed at OUT8 post of the Digital Sampler.
9. The integrator output can be observed at OUT9 post of the Integrator1 section. An observation
that a decrease in amplitude of the triangular signal with increase in amplitude can be observed.
10. An increase in amplitude of the 250Hz sine wave can be made using pot P3. Signal
approximating 250Hz sine wave is available at OUT9 post of the Integrator1.
11. Now the amplitude of the 250Hx signal should be increased further high and it can be observed
that the integrator output cannot follow the input signal.
12. The OUT8 post of the digital sampler is to be connected to the IN25 post of the
demodulator section.
13. The OUT21 of the demodulator section should be connected to IN29 of the Integrator 3 section.
14. The switch S9 in the integrator section should be kept towards High position.
15. The OUT25 Post should be connected to the IN33 of the second order LPF.
16. The OUT30 post of the 2nd order LPF should be connected to the IN34 post of the 4th order LPF
17. The reconstructed signal can be observed.
18. The above procedure can be observed for different input signals and clock frequencies.
28
20EC4353 VR20 Regulations Analog & Digital Communications
MODEL WAVEFORMS:
29
20EC4353 VR20 Regulations Analog & Digital Communications
RESULT
30
20EC4353 VR20 Regulations Analog & Digital Communications
2. State the drawbacks of Delta modulation. List the methods to overcome the same
4. What is slope overload error, Granular noise and how it could be rectified?
31
20EC4353 VR20 Regulations Analog & Digital Communications
Experiment 6
GENERATION AND DETECTION OF ASK, FSK AND PSK
AIM:
To study the generation and detection of ASK, FSK and PSK techniques
REQUIREMENTS:
ASK, FSK and PSK generation and reconstruction kit
Digital storage oscilloscope
Patch chords
CIRCUIT DIAGRAM
BLOCK DIAGRAM:
PROCEDURE: Block Diagram for the detection of ASK, FSK and PSK
Procedure ASK
1. The circuit has to be connected according to the diagram as shown in figure
2. An input bit sequence has to be generated from the function generator.
3. Here the input is considered to be a sequence of 010101010 (a square signal from function
generator)
4. The carrier with frequency is to be generated from function generator.
5. Both the signals message and carrier are to be given to the appropriate input terminals of the circuit.
6. The corresponding amplitude shift keyed signal has be observed at the output terminals.
Procedure FSK
1. The circuit has to be connected according to the diagram as shown in figure
2. An input bit sequence has to be generated from the function generator.
3. Here the input is considered to be a sequence of 010101010 (a square signal from function
generator)
4. Two carriers with different frequencies are to be generated from function generators.
5. Both the signals message and carriers are to be given to the appropriate input terminals of
the circuit.
6. Two carriers are to be applied at the collector terminals of the transistors.
7. As the transistors being NPN and PNP, when the message is applied at their base terminals each
move into ON state depending on the message bits and that corresponding signal with a defined
frequency appears at the output terminals
8. The corresponding frequency shift keyed signal has to be observed at the output terminals.
33
20EC4353 VR20 Regulations Analog & Digital Communications
Procedure PSK
1. The circuit has to be connected according to the diagram as shown in figure
2. An input bit sequence has to be generated from the function generator.
3. Here the input is considered to be a sequence of 010101010 (a square signal from function
generator)
4. Two carriers with different phases are to be generated from function generators.
5. Both the signals message and carriers are to be given to the appropriate input terminals of the
circuit.
6. Two carriers are to be applied at the collector terminals of the transistors.
7. As the transistors being NPN and PNP, when the message is applied at their base terminals each
move into ON state depending on the message bits and that corresponding signal with a defined
phase appears at the output terminals
8. The corresponding phase shift keyed signal has to be observed at the output terminals.
34
20EC4353 VR20 Regulations Analog & Digital Communications
35
20EC4353 VR20 Regulations Analog & Digital Communications
RESULT:
36
20EC4353 VR20 Regulations Analog & Digital Communications
37
20EC4353 VR20 Regulations Analog & Digital Communications
MATLAB INTRODUCTION
MATLAB® is a programming language and numerical computing environment. The name
MATLAB® is an acronym for “Matrix Laboratory”. As it name suggests it allows easy manipulation of
matrix and vectors. Plotting functions and data is made easy with MATLAB®. It has a good Graphic
User Interface and conversion of matlab files to C/C++ is possible. It has several toolboxes that possess
specific functions for specific applications. For example Image Processing, Neural Networks, CDMA
toolboxes are name a few. An additional package, Simulink, adds graphical multidomain simulation and
Model-Based Design for dynamic and embedded systems. Simulink contains Blocksets that is analogous
to Toolboxes.It was created by Mathworks Incorporation, USA. MATLAB® has become a defacto
programming language for Engineers. Writing MATLAB programs for modulation applications require
knowledge on very few functions and operators. The operators mostly used are arithmetic operators and
matrix operators. To know more type in the command prompt ‘help ops’. MATLAB will give a list in
that to know on specific operator say addition type in the command prompt ‘help plus’. MATLAB will
give how to use and other relevant information. Commonly used graphical functions are plot, figure,
subplot, title, and mathematical functions are sin and cos only. The mathematical functions sin and cos
are self explanatory. The graphical function figure will create a new window and then subsequent
graphical commands can be applied. The plot function usually takes two vectors and plot data points
according to given vector data. In this case it will time Vs signal. Subplot function is used when two or
more plots are drawn on the same figure. As title function suggests it helps to write title of the graph in
the figure. For further details type ‘help plot’ or ‘help subplot’ in the command prompt and learn the
syntax, few commonly used keywords are explained below:
clc clears all the text from the Command Window, resulting in a clear screen.
Clear All Tasks disables all workflow tasks in the hdlcoder.Work flow Config object.
CloseAll () closes all allocation sets without saving.
x = input(prompt) displays the text in prompt and waits for the user to input a value and press
the Return key. The user can enter expressions, like pi/4 or rand(3), and can use variables in the
workspace. If the user presses the Return key without entering anything, then input returns an
empty matrix. If the user enters an invalid expression at the prompt, then MATLAB ® displays
the relevant error message, and then redisplays the prompt.
Figure creates a new figure window using default property values.
Plot(X,Y) creates a 2-D line plot of the data in Y versus the corresponding values in X.
Subplot (m,n,p) divides the current figure into an m-by-n grid and creates axes in the position
specified by p. MATLAB® numbers subplot positions by row. The first subplot is the first
column of the first row; the second subplot is the second column of the first row, and so on. If
axes exist in the specified position, then this command makes the axes the current axes.
38
20EC4353 VR20 Regulations Analog & Digital Communications
Program 1
AMPLITUDE MODULATION AND DEMODULATION USING MATLAB
AIM
:
To Perform Amplitude modulation for the baseband signals of different Modulation index and
perform demodulation using MATLAB
REQUIREMENTS:
MATLAB 2017b
ALGORITHM:
1.
A Carrier signal whose frequency is fc and signal in the in the
form Ac Sin (2πfct) should be considered.
2.
A Modulating signal with frequency fm and signal in the in the
form Am Sin (2πfmt) is generated.
3.
A program has to be written to verify
a. Under modulation(K<1)
b. Critical modulation(K=1)
c. Over modulation (K>1)
Using the formula S(t)=Ac (1+K sin2πfmt) sin2πfct
4.
During execution the condition fc>fm has to be checked.
5.
The required plots for the amplitude modulated signals in all the three cases can be observed.
6.
To observe demodulated signal required formula and appropriate filters are to be used to get
an approximate message signal.
MATLAB Program:
clc;
clear all;
close
all;
t=[0:0.001:2];
f1=5;
m=sin(2*pi*f1*t);
subplot(6,2,[1,2]);
plot(t,m);
title('mesage');
f2=50;
39
20EC4353 VR20 Regulations Analog & Digital Communications
c=sin(2*pi*f2*t);
subplot(6,2,[3,4]);
plot(t,c);
40
20EC4353 VR20 Regulations Analog & Digital Communications
title('carrier')
; m1=0.5;
s1=(1+(m1*m)).*c;
subplot(6,2,[5,6]);
plot(t,s1);
title('under modulation');
m2=1; s2=(1+
(m2*m)).*c;
subplot(6,2,[7,8]);
plot(t,s2);
title('100%modulation');
m3=1.5;
s3=(1+(m3*m)).*c;
subplot(6,2,[9,10]);
plot(t,s3);
title('over modulation');
s5=s2.*c;
[b,a]=butter(5,0.1);
s4=filter(b,a,s5);
subplot(6,2,[11,12]);
plot(t,s4);
title('demodulation' );
EXPECTED
OUTPUT:
RESULTS:
40
20EC4353 VR20 Regulations Analog & Digital Communications
41
20EC4353 VR20 Regulations Analog & Digital Communications
Program 2
FREQUENCY MODULATION AND DEMODULATION USING MATLAB
AIM
:
To generate frequency modulated signal and determine the modulation index and bandwidth
for various values of amplitude and frequency of modulating signal.
To demodulate a Frequency Modulated signal using FM detector.
REQUIREMENTS:
MATLAB 2017b
ALGORITHM:
1.
A Carrier signal whose frequency is fc and signal in the in the
form Ac Sin (2πfct) should be considered.
2.
A Modulating signal with frequency fm and signal in the in the
form Am Sin (2πfmt) is generated.
3.
Consider m to be the modulation index.
4.
Using the formula y=sin (2*pi*fc*t- (m.*sin(2*pi*fm*t))); the program to generate the
modulated signal can be buit.
5.
The appropriate values in the command window are to be entered to get a frequency
modulated signal.
6.
To observe demodulated signal required formula and appropriate filters can be used to get
an approximate message signal.
MATLAB PROGRAM:
clc;
clear all;
close
all;
t=[0:0.001:4];
f1=1;
m=cos(2*pi*f1*t)
; subplot(4,2,
[1,2]); plot(t,m);
42
20EC4353 VR20 Regulations Analog & Digital Communications
title('message');
f2=30;
43
20EC4353 VR20 Regulations Analog & Digital Communications
c=sin(2*pi*f2*t);
subplot(4,2,[3,4]);
plot(t,c);
title('carrier');
mf=20;
s=sin((2*pi*f2*t)+(mf*sin(2*pi*f1*t)));
subplot(4,2,[5,6]);
plot(t,s);
title('modulated
signal'); syms t1;
x=diff(s);
y=abs(x);
[b,a]=butter(10,0.033);
s1=filter(b,a,y);
subplot(6,2,[11,12]);
plot(s1);
title('demodulation');
EXPECTED WAVEFORMS:
44
20EC4353 VR20 Regulations Analog & Digital Communications
RESULT:
45
20EC4353 VR20 Regulations Analog & Digital Communications
Program 3
DSBSC MODULATION AND DEMODULATION USING MATLAB
AIM:
REQUIREMENTS:
MATLAB 2017b
ALGORITHM:
1.
A Carrier signal whose frequency is fc and signal in the in the form Ac Sin (2πfct) should
be considered.
2.
A Modulating signal with frequency fm and signal in the in the form Am Sin (2πfmt) is generated.
3.
Using the formula S=m.*c; the program has to be constructed.
4.
Appropriate values in the command window should be entered to get a frequency modulated signal.
5.
To observe demodulated signal required formula and appropriate filters can be used to get
the reconstructed message signal.
MATLAB PROGRAM:
clc;
clear all;
close
all;
t=[0:0.001:1];
f1=5;
m=sin(2*pi*f1*t);
subplot(4,2,[1,2]);
plot(t,m);
title('message');
f2=80;
c=sin(2*pi*f2*t);
46
20EC4353 VR20 Regulations Analog & Digital Communications
subplot(4,2,[3,4]);
47
20EC4353 VR20 Regulations Analog & Digital Communications
plot(t,c);
title('carrier');
s=m.*c;
subplot(4,2,
[5,6]); plot(t,s);
title('DSB-SC');
s1=s.*c;
[b,a]=butter(5,0.1);
s2=filter(b,a,s1);
subplot(4,2,[7,8]);
plot(t,s2);
title('demodulation');
EXPECTED WAVEFORMS:
48
20EC4353 VR20 Regulations Analog & Digital Communications
RESULTS:
49
20EC4353 VR20 Regulations Analog & Digital Communications
Program 4
VERIFICATION OF LINECODES FOR RANDOMLY GENERATED SEQUENCE
AIM
:
To generate line code for the randomly generated binary sequence using MATLAB
REQUIREMENTS:
MATLAB2017a
THEORY:
A line code is a specific code used for transmitting a digital signal over a channel. Line coding is
used in digital data transport –the pattern of voltage or current used to represent digital data on a
transmission link is called line encoding.
Unipolar –RZ and NRZ : Unipolar RZ and NRZ both have a DC component.
ADVANTAGES DISADVANTAGES
Simplicity Contains low-frequency components
Doesn’t require a lot of bandwidth Presence of DC level
Long string of zeros causes loss of
synchronization
Polar –RZ and NRZ: Polar RZ takes twice as much bandwidth as polar NRZ
ADVANTAGES DISADVANTAGES
Simplicity Can contain low-frequency components
No DC Component (leads to signal drooping)
No clocking component to synchronize
to at receiver
No error correction capability
50
20EC4353 VR20 Regulations Analog & Digital Communications
ADVANTAGES DISADVANTAGES
No DC component Greater bandwidth required for this
waveform
No signal droop problem
No error correction capability
Easy to synchronize to the waveform
PROGRAM:
% program to generate various line codes
% The default program takes 8 bit random data and generates
% and displays various line codes.
% unipolar RZ, Polar RZ
% unipolar NRZ, Polar NRZ
% Manchester coding
clc
clear all
close
all
% creating random data consisting 1's and
0's disp('Generated Random data is as
follows')
data=randi([0,1],1,8); % This will generate a random data of 1's and 0's of length
8. disp(data); % decides the length of each bit
nbits = 10;
bit_duration=ones(1,nbits); % This decides the duration of each bit
% The below condition is written to check whether nbits are even or odd
% depending on nbits any one of the below code is
executed if (mod(nbits,2) == 0)
bit_duration_rz=[ones(1,nbits/2),zeros(1,nbits/2)];% This decides the duration of each
bit else
bit_duration_rz=[ones(1,floor(nbits/2)),zeros(1,ceil((nbits/2)))];
51
20EC4353 VR20 Regulations Analog & Digital Communications
end
52
20EC4353 VR20 Regulations Analog & Digital Communications
53
20EC4353 VR20 Regulations Analog & Digital Communications
% plot the RZ line codes
54
20EC4353 VR20 Regulations Analog & Digital Communications
%figure;
subplot(5,1,3) % to display both unipolar and polar once can use
subplot plot(uni_rz)
title('Unipolar RZ')
% to change the axis for better visibility
axis([0,length(uni_rz),min(uni_rz)-1,max(uni_rz)
+1]) subplot(5,1,4)
plot(pol_rz)
title('Polar
RZ')
axis([0,length(pol_rz),min(pol_rz)-1,max(pol_rz)+1])
%figure;
% plot the manchester coding
subplot(5,1,5)
plot(mach)
% to change the axis for better visibility
axis([0,length(mach),min(mach)-1,max(mach)+1])
title('Manchester coding')
%set( gca, 'XGrid', 'on' );
MODELWAVEFORMS:
5
20EC4353 VR20 Regulations Analog & Digital Communications
RESULTS:
52
20EC4353 VR20 Regulations Analog & Digital Communications
Program 5
RESPONSE OF MATCHED FILTER FOR UNIPOLAR AND POLAR NRZ
SIGNALING AIM:
Observe the response of the matched filter for Unipolar and polar NRZ signaling schemes
using MATLAB
REQUIREMENTS:
MATLAB2017a
THEORY:
h(t)= k s(Tb-t)
A network whose frequency-response function maximizes the output peak-signal-to-mean-noise (power)
ratio is called a matched filter. This criterion, or its equivalent, is used for the design of almost all radar
receivers. The frequency-response function, denoted H (f), expresses the relative amplitude and phase of
the output of a network with respect to the input when the input is a pure sinusoid. The magnitude ׀H
(f)
׀of the frequency-response function is the receiver amplitude passband characteristic. If the bandwidth
of the receiver passband is wide compared with that occupied by the signal energy, extraneous noise is
introduced by the excess bandwidth which lowers the output signal-to-noise ratio. On the other hand, if
the receiver bandwidth is narrower than the bandwidth occupied by the signal, the noise energy is
reduced along with a considerable part of the signal energy. The net result is again a lowered signal-to-
noise ratio. Thus, there is an optimum bandwidth at which the signal-to-noise ratio is a maximum.
This is well known to the radar receiver designer. The rule of thumb quoted in pulse radar practice is
that the receiver bandwidth B should be approximately equal to the reciprocal of the pulse width τ. This
is a reasonable approximation for pulse radars with conventional superheterodyne receivers. It is not
generally valid for other waveforms, however, and is mentioned to illustrate in a qualitative manner the
effect of the receiver characteristic on signal-to-noise ratio. The exact specification of the optimum
receiver characteristic involves the frequency-response function and the shape of the received
waveform. The receiver frequency-response function, is assumed to apply from the antenna terminals to
the output of the IF amplifier. (The second detector and video portion of the well-designed radar
53
20EC4353 VR20 Regulations Analog & Digital Communications
superheterodyne receiver will have negligible effect on the output signal-to-noise ratio if the receiver is
54
20EC4353 VR20 Regulations Analog & Digital Communications
designed as a matched filter.) Narrow banding is most conveniently accomplished in the IF. The
bandwidths of the RF and mixer stages of the normal superheterodyne receiver are usually large
compared with the IF bandwidth. Therefore, the frequency-response function of the portion of the
receiver included between the antenna terminals to the output of the IF amplifier is taken to be that of
the IF amplifier alone. Thus, one need only to obtain the frequency-response function that
maximizes the signal-to-noise ratio at the output of the IF. The IF amplifier may be considered as a filter
with gain. The response of this filter as a function of frequency is the property of interest. For a received
waveform s(t) with a given ratio of signal energy E to noise energy No (or noise power per hertz of
bandwidth), North showed that the frequency-response function of the linear, time-invariant filter which
maximizes the output peak-signal-to-mean-noise (power) ratio.
H(f) = G S*(f)exp(-j2ᴨft1)
∞
Where S(f) = ∫ s(t) exp(−j2πft) dt is the voltage spectrum of the input signal
−
S*(f) complex conjugate of S(f)
T1: Fixed value of time at which signal is observed to be maximum.
G= Constant equal to maximum filter gain
55
20EC4353 VR20 Regulations Analog & Digital Communications
PROGRAM:
% program to generate Matched filter output for Unipolar NRZ and Polar NRZ coded data
% The default program takes 8-bit random data
clc
clear all
close
all
% creating random data consisting 1's and
0's disp('Generated Random data is as
follows')
data=randi([0,1],1,8); % This will generate a random data of 1's and 0's of length
8. disp(data);
nbits = 10; % decides the length of each bit
bit_duration=ones(1,nbits); % This decides the duration of each bit
% code for adding normal distributed noise
noise = input('Do you want to add noise of normal distributed press y:
','s'); sigma = 0.1;
% code for generating NRZ line codes
% unipolar NRZ
uni_nrz = kron(data,bit_duration); % performs kroneker product and stores in uni_nrz
% adding noise to
data if noise=='y'
uni_nrz = uni_nrz + (sigma .*
randn(1,length(uni_nrz))); end
mf_uni_out=conv(fliplr(bit_duration),uni_nrz);
% polar NRZ
data_p = data*2-1; % first convert the data into 1's and -1's
pol_nrz = kron(data_p,bit_duration);
%adding noise to
data if noise=='y'
pol_nrz = pol_nrz + (sigma .*
randn(1,length(pol_nrz))); end
56
20EC4353 VR20 Regulations Analog & Digital Communications
mf_pol_out=conv(fliplr(bit_duration),pol_nrz);
% ploting the generated matched filter output and input data
57
20EC4353 VR20 Regulations Analog & Digital Communications
58
20EC4353 VR20 Regulations Analog & Digital Communications
MODELWAVEFORMS:
RESULTS:
59
20EC4353 VR20 Regulations Analog & Digital Communications
2. A polar NRZ waveform has to be received into the help of a matched filter. Here binary ‘1’ is
3. represented as a rectangular positive pulse. Also, binary ‘0’ is represented by a rectangular negative
pulse. Determine the impulse response of the matched filter.
5. Derive an expression for the impulse response of a matched filter for a rectangular input.
60
20EC4353 VR20 Regulations Analog & Digital Communications
Program 6.1
GENERATION & DEECTION OF ASK
AIM:
To write a program and verify the ASK signals using MATLab
REQUIREMENTS :
MATLAB 2017a, Computer installed with Windows XP or higher Version.
ALGORITHM:
ASK modulation
1. Generate carrier signal.
2. Start FOR loop
3. Generate binary data, message signal (on-off form)
4. Generate ASK modulated signal.
5. Plot message signal and ASK modulated signal.
6. End FOR loop.
7. Plot the binary data and carrier.
ASK demodulation
1. Start FOR loop
2. Perform correlation of ASK signal with carrier to get decision variable
3. Make decision to get demodulated binary data. If x>0, choose ‘1’ else choose ‘0’
4. Plot the demodulated binary data.
PROGRAM:
%ASK PROGRAM
clc %for clearing the command window
close all %for closing all the window except command
window clear all %for deleting all the variables from the
memory fc=input ('Enter the freq of Sine Wave carrier:');
fp=input ('Enter the freq of Periodic Binary pulse (Message):');
amp=input ('Enter the amplitude (For Carrier & Binary Pulse
Message):'); t=0:0.001:1; % For setting the sampling interval
61
20EC4353 VR20 Regulations Analog & Digital Communications
62
20EC4353 VR20 Regulations Analog & Digital Communications
MODEL WAVEFORMS:
RESULT:
63
20EC4353 VR20 Regulations Analog & Digital Communications
Experiment 6.2
GENERATION & DEECTION OF
AIM: FSK
REQUIREMENTS :
MATLAB 2017a
ALGORITHM
FSK modulation
1. Generate two carrier signals.
2. Start FOR loop
3. Generate binary data, message signal and inverted message signal
4. Multiply carrier 1 with message signal and carrier 2 with inverted message signal
5. Perform addition to get the FSK modulated signal
6. Plot message signal and FSK modulated signal.
7. End FOR loop.
8. Plot the binary data and carriers.
FSK demodulation
1. Start FOR loop
2. Perform correlation of FSK modulated signal with carrier 1 and carrier 2 to get two decision
variables x1 and x2.
3. Make decision on x = x1-x2 to get demodulated binary data. If x>0, choose ‘1’ else choose ‘0’.
4. Plot the demodulated binary data.
PROGRAM:
% FSK PROGRAM
close
all; clear
all; clc;
f1 = input('enter the high carrier freq :
'); f2 = input('enter the low carrier freq :
64
20EC4353 VR20 Regulations Analog & Digital Communications
');
65
20EC4353 VR20 Regulations Analog & Digital Communications
66
20EC4353 VR20 Regulations Analog & Digital Communications
grid on;
subplot(4,1,4);
plot(t,S);
67
20EC4353 VR20 Regulations Analog & Digital Communications
xlabel('time');
ylabel('amplitude');
grid on;
MODEL WAVEFORMS:
RESULT:
4. What is the relation between bit-rate and baud for a FSK system?
5. Write the mathematical expression for binary FSK for logical inputs 1 and 0?
68
20EC4353 VR20 Regulations Analog & Digital Communications
Program 6.3
GENERATION & DEECTION OF
AIM: PSK
PSK modulation
1. Generate carrier signal.
2. Start FOR loop
3. Generate binary data, message signal in polar form
4. Generate PSK modulated signal.
5. Plot message signal and PSK modulated signal.
6. End FOR loop.
7. Plot the binary data and carrier.
PSK demodulation
1. Start FOR loop Perform correlation of PSK signal with carrier to get decision variable
2. Make decision to get demodulated binary data. If x>0, choose ‘1’ else choose ‘0’
3. Plot the demodulated binary data.
PROGRAM:
%PSK PROGRAM
clc;
f1 = input('enter the high carrier freq :
'); f3 = input('enter the message freq: ');
A=5;
t =[0:0.001:1];
c = A.*sin(2*pi*f1*t);
M=
(A.*square(2*pi*f3*t)+A)/2;
plot(t,c);
69
20EC4353 VR20 Regulations Analog & Digital Communications
grid on;
70
20EC4353 VR20 Regulations Analog & Digital Communications
for i=0:1000
if(M(i+1)==5
)
S(i+1)=c(i+1);
else
S(i+1)=-c(i+1);
end
end
subplot(3,1,1);
plot(t,M);
xlabel('time');
ylabel('amplitude');
grid on;
subplot(3,1,2);
plot(t,c);
xlabel('time');
ylabel('amplitude');
grid on;
subplot(3,1,3);
plot(t,S);
xlabel('time');
ylabel('amplitude');
grid on;
71
20EC4353 VR20 Regulations Analog & Digital Communications
MODELWAVEFORMS:
RESULT:
2. For a 8 PSK system operating with an information bit rate of 24 Kbps. Determine
bandwidth efficiency?
72
20EC4353 VR20 Regulations Analog & Digital Communications
INTRODUCTION TO LABVIEW
Laboratory Virtual Instrument Engineering Workbench (LabVIEW) is a system-design
platform and development environment for a visual programming language from National Instruments.
DATAFLOW PROGRAMMING
GRAPHICAL PROGRAMMING
LabVIEW integrates the creation of user interfaces (termed front panels) into the development
cycle. LabVIEW programs-subroutines are termed virtual instruments (VIs). Each VI has three
components: a block diagram, a front panel, and a connector pane. The last is used to represent the VI in
the block diagrams of other, calling VIs. The front panel is built using controls and indicators. Controls
are inputs: they allow a user to supply information to the VI. Indicators are outputs: they indicate, or
display, the results based on the inputs given to the VI. The back panel, which is a block diagram,
contains the graphical source code. All of the objects placed on the front panel will appear on the back
panel as terminals. The back panel also contains structures and functions which perform operations on
controls and supply data to indicators. The structures and functions are found on the Functions palette
and can be placed on the back panel. Collectively controls, indicators, structures, and functions are
referred to as nodes. Nodes are connected to one another using wires, e.g., two controls and an indicator
can be wired to the addition function so that the indicator displays the sum of the two controls. Thus a
virtual instrument can be run as either a program, with the front panel serving as a user interface, or,
when dropped as a node onto the block diagram, the front panel defines the inputs and outputs for
the
73
20EC4353 VR20 Regulations Analog & Digital Communications
node through the connector pane. This implies each VI can be easily tested before being embedded as
a subroutine into a larger program.
The graphical approach also allows nonprogrammers to build programs by dragging and
dropping virtual representations of lab equipment with which they are already familiar. The LabVIEW
programming environment, with the included examples and documentation, makes it simple to create
small applications. This is a benefit on one side, but there is also a certain danger of underestimating the
expertise needed for high-quality G programming. For complex algorithms or large-scale code, it is
important that a programmer possess an extensive knowledge of the special LabVIEW syntax and the
topology of its memory management. The most advanced LabVIEW development systems offer the
ability to build stand-alone applications. Furthermore, it is possible to create distributed applications,
which communicate by a client–server model, and are thus easier to implement due to the inherently
parallel nature of G.
BENEFITS
INTERFACING TO DEVICES
LabVIEW includes extensive support for interfacing to devices such as instruments, cameras,
and other devices. Users interface to hardware by either writing direct bus commands (USB, GPIB, and
Serial) or using high-level, device-specific drivers that provide native LabVIEW function nodes for
controlling the device. LabVIEW includes built-in support for NI hardware platforms such
as CompactDAQ and CompactRIO, with a large number of device-specific blocks for such hardware,
the Measurement and Automation eXplorer (MAX) and Virtual Instrument Software
Architecture (VISA) toolsets.National Instruments makes thousands of device drivers available for
download on the NI Instrument Driver Network (IDNet).
CODE COMPILING
LabVIEW includes a compiler that produces native code for the CPU platform. The graphical
code is converted into Dataflow Intermediate Representation, and then translated into chunks of
executable machine code by a compiler based on LLVM. Run-time engine calls these chunks, allowing
better performance. The LabVIEW syntax is strictly enforced during the editing process and compiled
into the executable machine code when requested to run or upon saving. In the latter case, the
executable
74
20EC4353 VR20 Regulations Analog & Digital Communications
and the source code are merged into a single binary file. The execution is controlled by LabVIEW run-
time engine, which contains some pre-compiled code to perform common tasks that are defined by the
G language. The run-time engine governs execution flow, and provides a consistent interface to various
operating systems, graphic systems and hardware components. The use of run-time environment makes
the source code files portable across supported platforms. LabVIEW programs are slower than
equivalent compiled C code, though like in other languages, program optimization often allows to
mitigate issues with execution speed.
LARGE LIBRARIES
Many libraries with a large number of functions for data acquisition, signal generation,
mathematics, statistics, signal conditioning, analysis, etc., along with numerous for functions such as
integration, filters, and other specialized abilities usually associated with data capture from hardware
sensors is enormous. In addition, LabVIEW includes a text-based programming component named
MathScript with added functions for signal processing, analysis, and mathematics. MathScript can be
integrated with graphical programming using script nodes and uses a syntax that is compatible generally
with MATLAB.
PARALLEL PROGRAMMING
LabVIEW is an inherently concurrent language, so it is very easy to program multiple tasks that
are performed in parallel via multithreading. For example, this is done easily by drawing two or more
parallel while loops and connecting them to two separate nodes. This is a great benefit for test system
automation, where it is common practice to run processes like test sequencing, data recording, and
hardware interfacing in parallel.
ECOSYSTEM
Due to the longevity and popularity of the LabVIEW language, and the ability for users to
extend its functions, a large ecosystem of third party add-ons has developed via contributions from the
community. This ecosystem is available on the LabVIEW Tools Network, which is a marketplace for
both free and paid LabVIEW add-ons.
75
20EC4353 VR20 Regulations Analog & Digital Communications
Schematic Construction 1
AMPLITUDE MODULATION AND DEMODULATION USING LABVIEW
AIM:
To Perform Amplitude modulation for the baseband signal, analyze and interpret the data using
LabVIEW
REQUIREMENTS:
PC with LabVIEW
SCHEMANTIC:
EXPECTED OUTPUT:
71
20EC4353 VR20 Regulations Analog & Digital Communications
RESULT:
72
20EC4353 VR20 Regulations Analog & Digital Communications
Schematic Construction 2
FREQUENCY MODULATION AND DEMODULATION USING LABVIEW
AIM:
To Perform Frequency modulation for the baseband signal, analyze and interpret the data using
LabVIEW
REQUIREMENTS:
PC with LabVIEW
SCHEMANTIC:
73
20EC4353 VR20 Regulations Analog & Digital Communications
EXPECTED OUTPUT:
RESULT:
74
20EC4353 VR20 Regulations Analog & Digital Communications
Schematic Construction 3
DSB-SC MODULATION AND DEMODULATION USING LABVIEW
AIM:
To Perform DSB-SC modulation for the baseband signal, analyze and interpret the data using
LabVIEW
REQUIREMENTS:
PC with LabVIEW
SCHEMANTIC:
EXPECTED
75
20EC4353 VR20 Regulations Analog & Digital Communications
EXPECTED OUTPUT:
RESULT:
76
20EC4353 VR20 Regulations Analog & Digital Communications
AIM:
To Perform ASK, PSK, FSK modulation for the baseband signal, analyze and interpret the data
using LabVIEW
REQUIREMENTS:
PC with LabVIEW
SCHEMANTIC (ASK):
EXPECTED OUTPUT:
EXPECTED OUTPUT:
77
20EC4353 VR20 Regulations Analog & Digital Communications
EXPECTED OUTPUT:
78
20EC4353 VR20 Regulations Analog & Digital Communications
SCHEMANTIC (PSK):
EXPECTED
79
20EC4353 VR20 Regulations Analog & Digital Communications
EXPECTED OUTPUT:
80
20EC4353 VR20 Regulations Analog & Digital Communications
SCHEMANTIC (FSK):
81
20EC4353 VR20 Regulations Analog & Digital Communications
EXPECTED OUTPUT:
82
20EC4353 VR20 Regulations Analog & Digital Communications
RESULT:
83
20EC4353 VR20 Regulations Analog & Digital Communications
Beyond Syllabus
84
20EC4353 VR20 Regulations Analog & Digital Communications
REQUIREMENTS:
MATLAB 2017b
THEORY:
Sampling theorem states that if the sampling rate in any pulse modulation system exceeds twice the
maximum signal frequency the original signal can be reconstructed in the receiver with minimum
distortion. Let m(t) be a signal whose highest frequency component is f m. Let the value of m(t) be
obtained at regular intervals separated by time T far less than (1/2 f m) The sampling is thus periodically
done at each TS seconds. Now the samples m(nTS) where n is an integer which determines the signals
uniquely. The signal can be reconstructed from these samples without distortion. Time Ts is called the
SAMPLING TIME. The minimum sampling rate is called NYQUIST RATE. The validity of sampling
theorem requires rapid sampling rate such that at least two samples are obtained during the course of the
interval corresponding to the highest frequency of the signal under analysis. Let us consider an example
of a pulse modulated signal, containing speech information, as is used in telephony. Over standard
telephone channels the frequency range of A.F. is from 300 Hz to 3400 Hz. For this application the
sampling rate taken is 8000 samples per second. This is an Inter-national standard. We can observe that
the pulse rate is more than twice the highest audio frequency used in this system. Hence the sampling
theorem is satisfied and the resulting signal is free from sampling error.
MATLAB Program:
clc
clear all
close
all
t=-100:01:100;
fm=0.02;
x=cos(2*pi*t*fm);
figure
subplot(2,1,1);
plot(t,x);
85
20EC4353 VR20 Regulations Analog & Digital Communications
xlabel('time in
sec');
86
20EC4353 VR20 Regulations Analog & Digital Communications
ylabel('x(t)');
title('continuous time
signal'); fs1=0.02;
n=-2:2;
x1=cos(2*pi*fm*n/fs1);
subplot(2,1,2);
stem(n,x1);
hold on
%
subplot(3,1,3);
plot(n,x1,':');
title('discrete time signal x(n)');
Expected Waveforms:
RESULT:
88
20EC4353 VR20 Regulations Analog & Digital Communications
AIM:
To generate SSB using phase method and demodulation of SSB signal using Synchronous detector.
REQUIREMENTS:
MATLAB 2017b
THEORY:
The phase shift method makes use of two balanced modulators and two phase shift networks. One
of the modulators receives the carrier signal shifted by 90 0and the modulating signal with 00(sine) phase
shift, whereas the other receives modulating signal shifted by 90 0(co-sine) and the carrier (RF) signal
with 00phase shift voltage. Both modulators produce an output consisting only of sidebands. It will be
shown that both upper sidebands lead the input carrier voltage by 90 0. One of the lower sidebands leads
the reference voltage by 900, and the other lags it by 90 0. The two lower sidebands are thus out of phase,
and when combined in the adder, they cancel each other. The upper sidebands are in phase at the adder
and therefore they add together and give SSB upper side band signal. When they combined in the
subtractor, the upper side bands are cancelled because in phase and lower side bands add together and
gives SSB lower side band signal.
MATLAB PROGRAM
89
20EC4353 VR20 Regulations Analog & Digital Communications
90
20EC4353 VR20 Regulations Analog & Digital Communications
RESULTS:
91
20EC4353 VR20 Regulations Analog & Digital Communications
To study phase lock loop and its capture range, lock range and free running VCO Frequency.
Theory:
PLL is one of the fundamental building blocks in electronic technology. It is used for the
frequency multiplication, FM stereo detector, FM demodulator, frequency shift keying decoders, local
oscillator in TV and FM tuner. The block diagram of PLL is shown below.
The PLL consists of Phase detector, a LPF and a Voltage Controlled Oscillator (VCO) connected
together in the form a feedback system. The VCO is a sinusoidal generator whose frequency is
determined by a voltage applied to it from an external source. In effect, any frequency modulator may
serve as a VCO. The phase detector or comparator compares the input frequency, fin, with feedback
frequency, fout. The output of the phase detector is proportional to the phase difference between fin and
fout. The output voltage of the phase detector is a DC voltage and therefore is often refers to as error
voltage. The output of the phase detector is then applied to the LPF, which removes the high frequency
noise and produces a DC level. The DC level, intern is the input to the VCO. The output frequency of
the VCO is directly proportional to the input DC level. The VCO frequency is compared with the input
frequencies and adjusted until it is equal to the input frequency. In short, PLL keeps its out-frequency
constant at the input frequency.
92
20EC4353 VR20 Regulations Analog & Digital Communications
clear
all; reg1
=0;
reg2 =0;
reg3 = 0;
eta =sqrt(2)/2;
theta
=2*pi*1/100;
Kp =
[(4*eta*theta)/(1+2*eta*theta+theta^2)]; Ki =
[(4*theta^2)/(1+2*eta*theta+theta^2)];
d_phi_1 = 1/20;
n_data = 100;
for nn
=1:n_data
phi1= reg1+d_phi_1;
phi1_reg(nn) = phi1;
s1
=exp(1i*2*pi*reg1);
s2
=exp(1i*2*pi*reg2);
s1_reg(nn) =s1;
s2_reg(nn) =s2;
t =s1*conj(s2);
phi_error
=atan(imag(t)/real(t))/(2*pi);
phi_error_reg(nn) = phi_error;
sum1 =Kp*phi_error +
phi_error*Ki+reg3; reg1_reg(nn) =reg1;
93
20EC4353 VR20 Regulations Analog & Digital Communications
reg2_reg(nn) =
reg2; reg1 =phi1;
reg2=reg2+sum1;
reg3
=reg3+phi_error*Ki;
phi2_reg(nn) =reg2;
end
figure(1
)
94
20EC4353 VR20 Regulations Analog & Digital Communications
plot(phi1_reg);
hold on
plot(phi2_reg,'r')
; hold off;
grid on;
title('phaseplot');
xlabel('Samples');
ylabel('Phase');
figure(2)
plot(phi_error_reg)
;
title('phase Error of phase
detector'); grid on;
xlabel('samples(n)');
ylabel('Phase
error(degrees)'); figure(3)
plot(real(s1_reg));
hold on;
plot(real(s2_reg),'r');
hold off;
grid on;
title('Input signal & Output signal of
VCO'); xlabel('Samples');
ylabel('Amplitude');
axis([0 n_data -1.1
1.1]);
95
20EC4353 VR20 Regulations Analog & Digital Communications
Expected Waveforms:
96
20EC4353 VR20 Regulations Analog & Digital Communications
RESULTS:
1. What is a VCO?
2. What are the applications of PLL?
3. Give the expression for free running frequency f0 of a PLL?
4. What is meant by the free running frequency of a PLL?
5. Give the formulae for the lock range and capture range of the PLL?
97
20EC4353 VR20 Regulations Analog & Digital Communications
FREQUENCY SYNTHESIZER
AIM:
REQUIREMENTS:
Digital Storage
Oscilloscope BNC Probes
Connecting wires
THEORY:
98
20EC4353 VR20 Regulations Analog & Digital Communications
BLOCK DIAGRAM
CIRCUIT DIAGRAM:
PROCEDURE:
Pin 2 is connected to the 0.1 micro farad capacitor and the other end of the capacitor is
connected to the 10k resistor. To the other end of this resistor input 1khz signal is given from
function generator
For the same pin 2 connect one end of the 680ohms resistor and the other end to GND
Connect one end of 680ohms resistor to pin3 and the other end to ground
99
20EC4353 VR20 Regulations Analog & Digital Communications
EXPECTED WAVEFORMS:
TABULAR COLUMN:
100
20EC4353 VR20 Regulations Analog & Digital Communications
MATLAB PROGRAM:
close
all; clear
all; clc
fs = 10000;
t = 0:1/fs:1.5;
f=50;
x1 =
square(2*pi*f*t);
subplot (3,1,1)
plot(t,x1);
axis([0 0.2 -1.2 1.2])
xlabel('Time (sec)');ylabel('Amplitude');
title('Square wave input with
freq=50HZ'); t = 0:1/fs:1.5;
x2 =
square(2*pi*2*f*t);
subplot (3,1,2)
plot(t,x2);
axis([0 0.2 -1.2 1.2])
xlabel('Time (sec)');
ylabel('Amplitude');
title('frequency multiplication by a factor of
2'); x3 = square(2*pi*f/2*t);
subplot (3,1,3)
plot(t,x3);
axis([0 0.2 -1.2 1.2])
xlabel('Time (sec)');
ylabel('Amplitude');
title('frequency division by a factor of 2');
101
20EC4353 VR20 Regulations Analog & Digital Communications
EXPECTED RESULTS:
RESULTS:
102
20EC4353 VR20 Regulations Analog & Digital Communications
BLOCK DIAGRAM:
PROCEDURE:
1. The trainer kit has to be switched ON.
2. The frequency of the clock has to be noted.
3. The outputs (amplitudes and frequencies) of 8 signal generators are to be observed
4. These outputs should be connected to the input terminals of 8X1 multiplexer.
5. The multiplexer output should be observed and noted.
6. The output of multiplexer should now be connected as input to the demultiplexer.
103
20EC4353 VR20 Regulations Analog & Digital Communications
7. The outputs at 8 terminals of demux should also be can be observed and noted by connecting
the output of demultiplexer to the LPF individually the original signals.
104
20EC4353 VR20 Regulations Analog & Digital Communications
RESULT:
105
20EC4353 VR20 Regulations Analog & Digital Communications
Innovative Experiments
106
20EC4353 VR20 Regulations Analog & Digital Communications
NATIONAL INSTRUMENTS
UNIVERSAL SOFTWARE RADIO PERIPHERAL -
2920
The USRP-2920 is a tunable RF transceiver with a high-speed analog-to-digital converter and
digital-to-analog converter for streaming baseband I and Q signals to a host PC over 1 Gigabit Ethernet.
USRP-2920 can be used for the following applications: white space; broadcast FM; public safety; land-
mobile, low-power unlicensed devices on industrial, scientific, and medical (ISM) bands; sensor
networks; cell phone; amateur radio; or GPS.
COMPONENT ADDRESS
Host Ethernet interface static IP address 192.168.10.1
Host Ethernet interface subnet mask 255.255.255.0
Default USRP device IP address 192.168.10.2
SYSTEM SPECIFICATIONS
107
20EC4353 VR20 Regulations Analog & Digital Communications
REQUIREMENTS:
PC with LabVIEW
CONSTRUCTION OF QPSK SIGNAL GENERATOR:
108
20EC4353 VR20 Regulations Analog & Digital Communications
109
20EC4353 VR20 Regulations Analog & Digital Communications
PROCEDURE:
3. Open the NI-USRP Configuration Utility found in the National Instruments directory under
programs files as shown in Fig. 1. Be sure to record the IP addresses since you will need them to
configure your software.
5. Run the transmitter VI. LED “A” will illuminate on the USRP if the radio is transmitting.
6. Run the receiver VI. LED “C” will illuminate on the USRP if the radio is receiving data.
110
20EC4353 VR20 Regulations Analog & Digital Communications
OBSERVATIONS:
MODEL WAVEFORMS:
RESULT:
111
20EC4353 VR20 Regulations Analog & Digital Communications
SCHEMATIC IN LABVIEW:
OBSRVATION
113
20EC4353 VR20 Regulations Analog & Digital Communications
RESULTS:
114
20EC4353 VR20 Regulations Analog & Digital Communications
REQUIREMENTS:
NI – USRP 2920
Desktop with NI LabVIEW
THEORY:
115
20EC4353 VR20 Regulations Analog & Digital Communications
is characterized by a fee per unit of connection time, even when no data is transferred, while packet
switching may be characterized by a fee per unit of information transmitted, such as characters, packets,
or messages.
PROCEDURE:
1. The user interfaces (Front Panels) for these VIs use tab controls to organize input / output
parameters into logical groups. On USRP Packet Transmitter.vi, click on each of the tabs and
confirm correct settings for input parameters:
Tab: Specify Message: Set the Message text to transmit.
Tab: Specify Packet: Set the lengths of the bit fields that comprise the packets to
transmit
Tab: Specify Modulation: Set the type of modulation and parameters for a pulse
shaping filter
Tab: Tx Parameters: Set USRP hardware parameters, including the IP address of the
USRP that will act as your transmitter. Confirm that this IP address is set to a
connected USRP that is powered on. Also confirm that the Tx Parameters are
appropriate for the USRP hardware that you are working with.
2. Run USRP Packet Transmitter.vi to begin transmitting. The VI will repeatedly transmits the
message until you press the Stop button on the front panel. The Symbol Rate [symbols/sec]
indicator on USRP Packet Transmitter.vi will display the symbol rate for the transmitted message.
This rate is determined by the combination of the settings you specify on the TX IQ Sampling Rate
[s/sec] and the Samples / Symbol controls, specifically, the symbol rate is set to (TX IQ Sampling
Rate) / (Samples / Symbol).
3. On USRP Packet Receiver.vi, click on each of the tabs and confirm correct settings for input
parameters:
Tab: Rx Parameters: Set USRP hardware parameters, including the IP address of the
USRP that will act as your receiver. Confirm that this IP address is set to a connected
USRP that is powered on. Also confirm that the Rx Parameters are appropriate for the
USRP hardware that you are working with and that these values correspond to
settings made previously for the transmitter.
Tab: Specify Modulation: Set the type of modulation and parameters for a matching
filter. The modulation parameters need to correspond to those set for the transmitter.
116
20EC4353 VR20 Regulations Analog & Digital Communications
Tab: Specify Packet: Set the lengths of the bit fields that comprise the packets to
receive. These should be identical to the values set on the transmitter.
Tab: Rx Display: See the resulting recovered text message, the live raw / received
signal and a constellation graph of one of the recovered packets
SCHEMATIC IN LABVIEW: TRANSMITTER
117
20EC4353 VR20 Regulations Analog & Digital Communications
OBSERVATIONS:
118
20EC4353 VR20 Regulations Analog & Digital Communications
119
20EC4353 VR20 Regulations Analog & Digital Communications
RESULTS:
120