Experiment No. 01 Experiment Name-ASK Modulation
Experiment No. 01 Experiment Name-ASK Modulation
01
EQUIPMENTS REQUIRED
Scientech 2156 and Scientech 2157, 2 mm Banana cable, Oscilloscope Scientech 803/831,
30 MHz or equivalent
THEORY: In the wireless digital communication, it is not easy to transmit the digital data
directly. This is because it needs to pass through the modulator and modulate the carrier
signal in order to send the signal effectively. One of the easiest ways is to use the different
data stream to change the amplitude of carrier, this kind of modulation is called amplitude
modulation, and we call it as amplitude shift keying (ASK) modulation in digital
communication.
Figure is the basic circuit diagram of ASK modulator. Let the input data be 5V, when the
signal pass through the buffer, he switch S1 will switch to point A, at this time the ASK
output waveform is f1. When the input data is 0V, when the signal pass through the buffer,
the switch S1 will switch to point B, at this time the ASK output waveform is DC 0V. the
abovementioned is the basic theory of ASK modulation.
In equation (1), the values of amplitude Ai have M types of possible change, the Wc and Øo
denote the cutoff frequency and phase, respectively. If we choose M=2, the XASK(t) signal
will transmit the binary signal, therefore, the values of A are A1=0 and A2=A, A is the
arbitraryconstant so we can obtain the binary ASK modulated signal waveform as shown
.when input logic is 1, then the signal is transmitted out. When the input logic is 0, then no
signal is transmitted, so this also called on-off keying (OOK), this type of method is used in
the past time.
1
Connection diagram:
PROCEDURE :
2
Amplitude Shift KeyingModulation :
1. Connect the power supplies of Scientech 2156 and Scientech 2157 but do not
turn on the power supplies until connections are made for this experiment.
4. On Scientech 2156, connect oscilloscope CH1 to ‘Clock In’ and CH2 to ‘Data
In’ and observe the waveforms.
6. Vary the gain potentiometer of modulator circuit (l) on Scientech 2156 to adjust
the amplitude of ASK Waveform.
WAVEFORMS :
3
Conclusion :
Viva Questions
1) What is ASK ?
Experiment No. 02
4
Experiment Name- FSK Modulation
EQUIPMENTS REQUIRED :
Scientech 2156 and Scientech 2157, 2 mm Banana cable, Oscilloscope Scientech 803/831,
30 MHz or equivalent
Theory:
Frequency Shift Keying (FSK) Technique :
In frequency shift keying, the carrier frequency is shifted in steps (i.e. from one frequency to
another) corresponding to the digital modulation signal. If the higher frequency is used to represent
data '1' & lower frequency for data '0', the resulting Frequency shift keying waveform appears as
shown in figure.
Thus Data = 1 high frequency
Data = 0 low frequency
5
Generation of FSK Waveform from the sum of two ASK Waveforms
The functional blocks required in order to generate the FSK signal is as shown in figure 17.
There are two ASK modulator, each has different carrier frequencies but the digital data is
inverted in one of the modulator. These two different ASK modulated signal are applied to
the summing amplifier to get FSK modulated signal as shown in
6
Frequency Shif Keying Modulator
The demodulation of FSK waveform can be carried out by a phase locked loop. As known,
the phase locked loop tries to 'lock' to the input frequency. It achieves this by generating
corresponding output voltage to be fed to the voltage controlled oscillator, if any frequency
deviation at its input is encountered. Thus the PLL detector follows the frequency changes &
generates proportional output voltage. The output voltage from PLL contains the carrier
components. Therefore the signal is passed through the low pass filter to remove them. The
resulting wave is rounded to be used for digital data processing. Also, the amplitude level
may be very low due to channel attenuation. The signal is 'Shaped Up' by feeding it to the
voltage comparator. The functional block diagram of FSK demodulator is shown in figure.
7
Observation Diagram:
Connection diagram
8
Procedure :
9
Frequency Shift Keying Modulation:
1. Connect the power supplies of Scientech 2156 and Scientech 2157 but do not
turn on the power supplies until connections are made for this experiment.
4. On Scientech 2156, connect oscilloscope CH1 to ‘Clock In’ and CH2 to ‘Data
In’ and observe the waveforms.
6. Adjust the potentiometers of both the Modulator Circuit (l) &(ll) onScientech
2156 to adjust the amplitude of FSK waveform at Summing Amplifier’s output
on Scientech 2156.
Observations :
The output at Summer Amplifier is the FSK waveform, Observe that for data
bit '0' the FSK signal is at lower frequency (960KHz) & for data bit '1’ the FSK
signal is at higher frequency (1.6 MHz)The output at comparator on Scientech
2157 is the same as ‘Data In’ on Scientech 2156.
Conclusion :
1. The amplitude change in FSK waveform does not matter, therefore FSK
modulation technique is very reliable even in noisy & fading channels.
Viva Questions
1) What is FSK ?
Experiment No. 03
10
AIM : Study of Phase Shift Keying Modulation & Demodulation Technique
EQUIPMENTS REQUIRED:
Scientech 2156 and Scientech 2157, 2 mm Banana cable, Oscilloscope Scientech 803/831, 30
MHz or equivalent
THEORY
Phase shift keying involves the phase change of the carrier wave between 0° and 180 in
accordance with the data levels to be transmitted. Phase shift keying is also known as phase
reversal keying (PRK). The PSK waveform for a given data is as shown in
figure.
For Binary PSK
S0(t) =Acos(wt) represents binary ‘0’
S1(t) =Acos(wt+π) represents binary ‘1’
Functionally, the PSK modulator is very similar to the ASK modulator. Both uses balanced
modulator to multiply the carrier with the modulating signal. But in contrast to ASK
technique, the digital signal applied to the modulation input for PSK generation is bipolar i.e.
have equal positive and negative voltage levels. When the modulating input is positive the
output of modulator is a sine wave in phase with the carrier input. Where as for the negative
voltage levels, the output of modulator is a sine wave which is shifted out of phase by
180from the carrier input. The functional block representation of the PSK modulator is
shown in the figure.
For PSK signal demodulation the square loop detector circuit is used. The PSK
demodulator is as shown in figure.
11
The incoming PSK signal with 0& 180phase changes is first fed to the signal squarer,
which multiplies the input signal by itself. The output of this block is a signal of having twice
the frequency to that of the input carrier frequency. As the frequency of the output doubled,
the 0& 180phase changes are reflect as 0& 360phase changes. Since phase change of
360is same as 0phase change, it can be said that the signal squarer simply removes the
phase transitions from the original PSK waveform.
The PLL block locks to the frequency of the signal square output & produces a clean square
wave output of same frequency. To derive the square wave of same frequency as the
incoming PSK signal, the PLL output is divided by two.
The following phase adjust circuit allows the phase of the digital signal to be adjusted with
respect to the input PSK signal. Also its output controls the closing of an analog switch.
When the output is high the switch closes & the original PSK signal is switched through the
detector. When the output of phases adjust block is low, the switch opens & the output of
detector output falls to 0 Volts. The demodulator output contains positive half cycles when
the PSK input has one phase & only negative half cycles when the PSK input has another
phase. The phase adjust potentiometer is adjusted properly. The average level information of
the demodulator output which contains the digital data information is extracted by the
following low pass filter. The low pass filter output is too rounded to be used for digital
processing. Therefore it is 'Squared Up' by a voltage comparator.
12
PSK Demodulation Waveforms
13
Perform this experiment with different Data pattern using different clock and carrier.
14
‘
Procedure
15
1. Connect the power supplies of Scientech 2156 and Scientech 2157 but do not turn on the
power supplies until connections are made for this experiment.
4. On Scientech 2156, connect oscilloscope CH1 to ‘Clock In’ and CH2 to ‘Data In’ and
observe the waveforms.
5. On Scientech 2156, connect oscilloscope CH1 to ‘NRZ (L)’ and CH2 to ‘Output’ of
Modulator Circuit (l) on Scientech 2156 and observe the waveforms.
6. Adjust the ‘Gain’ potentiometer of the Modulator Circuit (l) on Scientech 2156 to adjust
the amplitude of PSK waveform at output of Modulator Circuit (l) on
Scientech 2156.
7. Now on Scientech 2157 select Carrier frequency selection switch to 1.6MHz and connect
oscilloscope CH1 to ‘Input’ of PSK demodulator and connect CH2 one by one to output of
double squaring circuit, output of PLL, output of Divide by four (÷ 2) observe the wave
forms.
8. On Scientech 2157 connect oscilloscope CH1 to output of Phase adjust and CH2 to
‘output’ of PSK demodulator and observe the waveforms. Set all toggle switch to 0 and
compare the waveform now vary the phase adjust potentiometer and observe its effects on the
demodulated signal waveform. (Note: If there is problem in setting the waveform with
potentiometer then toggle the switch given in PSK demodulator block two to three times to
get the required waveform).
9. Now connect oscilloscope CH1 to ‘PSK’ output of PSK demodulator on Scientech 2157
and connect CH2 ‘Output’ of Low Pass Filter on Scientech 2157 and observe the waveforms.
10. Connect oscilloscope CH1 to ‘Output’ of Low Pass Filter on Scientech 2157 then connect
CH2 to ‘Output’ of Comparator on Scientech 2157 and observe the waveforms, now vary the
reference voltage potentiometer of first comparator to generate desired data pattern.
11. On Scientech 2156, connect oscilloscope CH1 to ‘NRZ (L)’ and CH2 to ‘Output’ of
comparator on Scientech 2157 and observe the waveforms.
12. Connect oscilloscope CH1 to ‘Data In’ then connect CH2 output to Bit decoder and
observe the waveforms. If both data does not matches then try to match it by varying the
phase adjust potentiometer on QPSK Demodulator.
13. Now try to match the LED sequence by once pressing the reset switch on Scientech 2156.
Observations :
1. The output at ‘Data In’ is repeating sequence of bits generated by Data Source.
16
2. The ‘Output’ of Modulator Circuit (l) is Phase Shift Keying modulated signal.
3. The output of Double squaring circuit is sinusoidal signal (carrier signal) but frequency is
our times higher than that of carrier used for modulation.
4. The output of Phase Lock Loop (PLL) is clock signal of same frequency as that of the
output of double squaring circuit and output of Divide by two (÷ 2) is clock signal of
frequency two times less than the output of PLL signal.
5. The output of PSK demodulator is a signal having group of positive half cycles and group
of negative half cycles of the carrier signal.
6. A low pass filter removes high frequency component from demodulated PSK signal and it
makes the signal smooth.
7. The variation in reference voltage potentiometer affect the Data, to recover Data correctly
potentiometer adjustment is necessary.
8. The Phase Adjust potentiometer on Scientech 2157 matches the phase of regenerated clock
and carrier with input clock and carrier signal.
Conclusion ::
Now we can observe that the final data stream can be either the original data stream or its
inverse, this is because the sine wave is symmetrical, the receiver has no way of detecting
whether the incoming phase of the signal is 0or 180This phase ambiguity create two
different possibilities for the receiver output i.e. the final data stream can be either the
original data stream or its inverse.
Viva Questions
1) What is PSK ?
Experiment No. 04
Aim :To Study of Quadrature Phase Shift Keying Modulation & Demodulation
17
Equipments Needed :
Scientech 2156 and Scientech 2157, 2 mm Banana cable, Oscilloscope Scientech 803/831, 30
MHz or equivalent
Theory
Quadrature Phase Shift Keying (QPSK) Technique :
If we define four signals, each with a phase shift differing by 90 degree then we have
quadrature phase shift keying (QPSK).
The input binary bit stream dk, dk = 0,1,2,..... arrives at the modulator input at a rate 1/T
bits/sec and is separated into two data streams dI (t) and dQ (t) containing odd and even bits
respectively.
dI (t) = d0, d2, d4.....
dQ (t) = d1, d3, d5.....
18
Quadrature Phase Shift Keying Waveforms
In quardrature Phase Shift keying each pair of consecutive data bit is treated as a two bit (or
Dibit) code which is used to switch the phase of the carrier sine wave between one of four
phases 90° apart. The four possible combination of Dibit code are 00, 01, 10 and 11. Each
code represents either a phase of 45°, 135°, 225°, and 315° lagging, relative to the phase of
the original un-modulated carrier. The choice of these phases is arbitrary as it is convenient to
produce them. Quadrature phase shift keying offers an advantage over PSK, in a manner that
now each phase represents a two bit code rather than a single bit. This means now either we
can change phase per second or the same amount of data can be transmitted with half as
many phase changes per second. The second choice results in a lowering of bandwidth
requirement.
The four phases are produced by adding two carrier waves of same frequency but 90° out of
phases. The 0° phase carrier is called In-phase carrier and is labeled 1, the other is 90°
(lagging) phase carrier termed as the quadrature carrier and is labeled Q. The I-carrier is
controlled by the MSB (most significant bit) of the Dibit code. When the MSB is a level ‘0'
the phase is 0 degrees when the MSB goes to level 1 the phase everses to 180°
The Q-carrier starts with 90° out of phase (with respect to reference I carrier). This carrier is
controlled by the LSB (least significant bit) of the digit code when the LSB is a level 0, the
phase is 90° degrees with reference to I-carrier. When the LSB goes to a level 1, the phase
reverses to 270°.
19
QPSK Demodulator
20
Connection diagram : QPSK modulation
Procedure :
21
Quadrature Phase Shift Keying Modulation :
1. Connect the power supplies of Scientech 2156 and Scientech 2157 but do not turn on the
power supplies until connections are made for this experiment.
4. On Scientech 2156, connect oscilloscope CH1 to ‘Clock In’ and CH2 to ‘Data In’ and
observe the waveforms.
5. On Scientech 2156, connect oscilloscope CH1 to ‘Clock Output’ and CH2 one by one to
‘Sine’ and ‘Cosine’ output of 960 KHz and observe the waveforms.
6. On Scientech 2156, connect oscilloscope CH1 to ‘Data In’ and connect CH2 one by one
to ‘I Data’ and ‘Q Data’ outputs and observe the waveforms.
7. Now connect oscilloscope CH1 to ‘I Data’ output on Scientech 2156 and connect CH2
one by one to ‘Signal In’, ‘Carrier In’ and ‘Output’ of modulator circuit (l) on Scientech
2156 and observe the waveforms.
8. Now connect oscilloscope CH1 to ‘Q Data’ output on Scientech 2156 and connect CH2
one by one to ‘Signal In’, ‘Carrier In’ and ‘Output’ of modulator circuit (ll) on Scientech
2156 and observe the waveforms.
9. Now connect oscilloscope CH1 to ‘Data Out’ on Scientech 2156 and CH2 to ‘Output’ of
Summing Amplifier on Scientech 2156 and observe the waveforms.
10. Set ‘Carrier frequency’ selection switch to ‘960 KHz’ on Scientech 2157.
11. ow on Scientech 2157 connect oscilloscope CH1 to ‘Input’ of QPSK demodulator and
connect CH2 one by one to output of double squaring circuit, output of PLL, output of
Divide by four (÷ 4) observe the wave forms.
12. On Scientech 2157, connect oscilloscope CH1 to ‘I’ output of QPSK demodulator and
CH2 to ‘Q’ output of QPSK demodulator and observe the waveforms. Set all toggle
switch to 0, now vary the phase adjust potentiometer and observe its effects on the
demodulated signal waveforms.
13. Connect oscilloscope CH1 to ‘I’ output of QPSK demodulator on Scientech 2157 then
connect CH2 one by one to output of low pass filter, output of Comparator on Scientech
2157 and observe the waveforms.
22
14. Connect oscilloscope CH1 to ‘Q’ output of QPSK demodulator on Scientech 2157 then
connect CH2 one by one to output of low pass filter, output of Comparator on Scientech
2157 and observe the waveforms.
15. Compare the output of comparators on Scientech 2157 with the output ‘I Data’ and ‘Q
Data’ on Scientech 2156 respectively.
16. Connect oscilloscope CH1 to ‘Data In’ then connect CH2 output to Bit decoder and
observe the waveforms. If both data does not matches then try to match it by varying the
phase adjust potentiometer on QPSK Demodulator.
17. Now try to match the LED sequence by once pressing the reset switch on Scientech
2156.
Observations :
1. The output at ‘Data In’ is repeating sequence of bits generated by Data Source.
2. The ‘I Data’ and ‘Q Data’ output are even and odd bit sequence of input data sequence and bit
duration is double of input data sequence as shown in the figure 11.2.
3. The ‘Output’ of Modulator Circuit (l) and Modulator Circuit (ll) are Phase Shift Keying
modulated signals, and summation of these two signals are Quadrature Phase Shifted signal as
shown in the figure 6.2.
4. The output of Double squaring circuit is sinusoidal signal (carrier signal) but frequency is four
times higher than that of carrier used.
5. The output of Phase Lock Loop (PLL) is clock signal of same frequency as that of the output of
double squaring circuit and output of Divide by four (÷ 4) is clock signal of frequency four times
less than the output of PLL signal.
6. The output of QPSK demodulator is a signal having group of positive half cycles and group of
negative half cycles of the carrier signal as shown in the figure 6.3.
7. A low pass filter removes high frequency component from demodulated QPSK signal and it
makes the signal smooth as shown in the figure 6.3.
8. The variation in reference voltage potentiometer affect the Data, to recover Data correctly
potentiometer adjustment is necessary and recovered Data. QPSK modulation waveforms Figure
6.2
23
.
24
Conclusion :
The Quadrature Phase Shift Keying modulation is correct for different Data pattern and also
correct for clock and carrier frequencies.
Viva Questions
1) What is QPSK ?
Experiment No. 05
25
Procedure:
1) Connect the power supply of Scientech 2156 but do not turn on the power supplies until
connections are made for this experiment.
4) Connect oscilloscope CH1 to ‘Data In’ and CH2 to ‘Clock In’ and observe the waveforms.
5) Connect oscilloscope CH1 to ‘Data In’ and CH2 to ‘NRZ (L)’ and observe the waveforms.
26
6) Connect oscilloscope CH1 to ‘Data In’ and CH2 to ‘NRZ (M)’ and observe the waveforms.
7) Connect oscilloscope CH1 to ‘Data In’ and CH2 to ‘RZ’ and observe the waveforms.
8) Connect oscilloscope CH1 to ‘Data In’ and CH2 to ‘Biphase (manchester)’ and observe the
waveforms.
9) Connect oscilloscope CH1 to ‘Data In’ and CH2 to ‘Biphase (Mark)’ and observe the waveforms. 3
10) Connect oscilloscope CH1 to ‘Data In’ and CH2 to ‘RB’ and observe the waveforms.
11) Connect oscilloscope CH1 to ‘Data In’ and CH2 to ‘AMI’ and observe the waveforms.
Observations:
1) The output at ‘Data In’ is repeating sequence of bits generated by Parallel to serial Converter.
2) The ‘NRZ (L)’ data is same as ‘Data In’ but it is one bit shifted.
3) Verify all the formatting techniques according to example patterns given on the Scientech 2156
board.
Conclusions:
1) The NRZ(L) waveform simply goes low for one bit time to represent a data ‘0’ and high for one
bit time to represent a data ‘1’.
2) In the NRZ (M) line codes the present level is related to the previous level that is when logic ‘1’
is to be transmitted change in level occurs and for logic ‘0’ the level remains unchanged.
3) In the RZ line codes, the maximum signal frequency of ‘RZ’ signal occurs when a string of ‘1’ is
transmitted. It is equivalent to sending two logic levels in each clock period. Thus bandwidth
requires is twice as that required for the NRZ waveforms.
4) The Biphase Manchester codes always contain at least one transition per bit time, irrespective of
the data being transmitted. Hence the maximum frequency of the biphase code is equal to the data
clock rate when a stream of consecutive data ‘1’ & ‘0’ is transmitted. Therefore the required
bandwidth is same as that of RZ code & double as that of NRZ (L) code.
5) In the ‘Biphase Mark’ if a data ‘0’ is to be transmitted, the sequence of the transmitted levels will
remain same as for the previous bit interval and if a ‘1’ is to be transmitted , the sequence of the
transmitted levels will reverse i.e. phase reversal will occur.
6) The Biphase Mark code being very similar to the Biphase (Manchester) coding requires same
amount of bandwidth which is double as that of NRZ (L).
7) The maximum signal frequency in RB code is equal to the data clock frequency; the bandwidth
requirements is same as that for RZ, Biphase codes and double that for NRZ codes.
27
8) The maximum transition rate for AMI can only occur during a stream of all ‘1s’ thus the
bandwidth required is twice that required for the NRZ codes.
Experiment No. 06
28
5. BNC probs
Theory:
Modulation:
The 16 – QAM Modulation Signal is the combination of I channel and Q channel. It has 16
symbol, each symbol consist of 4 bits (i.e. I – 2 bits and Q- 2 bits) is explained in the
constellation Diagram. In the 16-QAM, the number of amplitude shift is fewer than the phase
shifts. This is because, the amplitude changes are susceptible to noise and require greater shift
difference than do phase changes, the number of phases shifts used by a QAM system is
larger than the amplitude shifts. This meant that even with noise problem associated with
amplitude shifting is reduced. So QAM is lower susceptibility to noise. QAM is used to
obtain higher spectral efficiency, which potentially results in higher throughput of packetized
data.
Demodulation:
The QAM Receiver (Demodulator) takes the modulated output from transmitter signal as
input, and it is multiplied with NCO Generated sine and cosine carriers to get I Demodulation
and Q Demodulation Signals. It is apparent that the demodulator performs the complement
functions to those in the modulator to get the transmitted data in the receiver.
29
Block Diagram for 16-QAM Demodulator:
Procedure:
For modulation:
1.Hardware Mode Steps:
· Observe the output of 16-QAM Modulation at test point TP18.
· For clock frequency, pattern length settings refer Experiment 1.
· For 4-Bit Encoding refer Experiment 2.
· For Binary to Gray Encoder refer Experiment 3.
· For Symbol Mapper outputs of I Channel and Q Channel refer Experiment 4.
30
· For Sine wave Generator, Cosine wave Generator, I Channel Modulation and Q Channel
Modulation refer Experiment 5.
31
Outputs of Sine and Cosine Demodulator:
For demodulation:
32
· For Symbol Mapper outputs of I Channel and Q Channel refer Experiment 4.
· For Sine wave Generator, Cosine wave Generator, I Channel Modulation and Q Channel
Modulation refer Experiment 5.
· For 16-QAM Modulation refer Experiment 6.
Observation:
Modulation:
33
Software Result for Reference:
34
Outputs of Sine and Cosine Demodulator software Result for Reference:
35
RESULT:
Variable Data
QAM Modulation
Variable Data
QAM Modulation
Variable Data
QAM Modulation
Variable Data
QAM Modulation
Modulation:
Demodulation:
I Demodulation
Q Demodulation
I Demodulation
Q Demodulation
I Demodulation
Q Demodulation
I Demodulation
Q Demodulation
I Demodulation
Q Demodulation
Conclusion : .
……………………………………………………………………………………
…………..
……………………………………………………………………………………
……………………………………………………………………………..
36
……………………………………………………………………………………
…………………………………………………………………………
Viva Questions
1) What is QAM ?
Experiment No. 07
37
1. Eye Pattern and BER Measurement Module. (Optional)
2. ST2501/ ST2502 Optical Fiber Communication trainer.
3. Patch Cords
4. Optical Fiber Cable
5. + 5V DC, 500 mA Adapter
Theory:
The eye-pattern technique is a simple but powerful measurement method for assessing the
data-handling ability of a digital transmission system. This method has been used extensively
for evaluating the performance of wire systems and can also be applied to optical fiber data
links. The eye-pattern measurements are made in the time domain and allow the effects of
waveform distortion to be shown immediately on an oscilloscope.
Connection Diagram:
Procedure:
This Eye Pattern and BER Measurement Module is to be used with Optical Fiber
Communication Trainer ST2501/ ST2502.
1. Connect power supply to Optical Fiber communication Trainer ST2501/
38
ST2502.
2. Ensure that all switched faults are off.
3. Connect the fiber optic cable between emitter output and detector input.
4. Connect +5V DC, 500 mA adapter to the board.
5. Make the connections as shown in figure.
a. Connect clock frequency of 64 KHz from CLK Generator to CLK In of
Data generator using patch cord.
b. Connect Data out of Data Generator to of Data In of optical Link.
c. Now connect a patch cord from Data In of Optical Link of Module to Input
of emitter section of Optical Fiber Communication Trainer ST2501/
ST2502.
d. Now connect a patch cord from detector section of Optical Fiber
Communication Trainer ST2501/ ST2502 to Data out of Optical Link of
Module.
e. Connect Data Out of Optical Link Section to Signal In of Noise Generator.
f. Make the ground common of Trainer and Module using patch cord.
6. Keep toggle switch towards Eye Pattern Socket.
7. Connect channel 1 (CH Y) of oscilloscope to Eye Pattern Socket.
8. Connect EXT. TRIG. Of oscilloscope to CLK In of Data Generator and press
the EXT. TRIG. Switch.
9. Adjust the time base as well as Cal pot of oscilloscope to get Eye Pattern as
shown in figure.
10. Observe the Eye pattern for different clock frequencies and different Noise
Level
Observation:
39
Conclusion : As clock frequency increases the EYE opening becomes smaller.
3. Why single mode fibres are used for long distance transmission?
Experiment No. 8
40
Aim: To generate and demodulate amplitude shift keyed (ASK) signal using MATLAB
Theory
Generation of ASK
Amplitude shift keying - ASK - is a modulation process, which imparts to a sinusoid two or more
discrete amplitude levels. These are related to the number of levels adopted by the digital
message. For a binary message sequence there are two levels, one of which is typically zero. The
data rate is a sub-multiple of the carrier frequency. Thus the modulated waveform consists of
bursts of a sinusoid. One of the disadvantages of ASK, compared with FSK and PSK, for
example, is that it has not got a constant envelope. This makes its processing (eg, power
amplification) more difficult, since linearity becomes an important factor. However, it does make
for ease of demodulation with an envelope detector.
Demodulation
ASK signal has a well defined envelope. Thus it is amenable to demodulation by an envelope
detector. Some sort of decision-making circuitry is necessary for detecting the message. The
signal is recovered by using a correlator and decision making circuitry is used to recover the
binary sequence.
Algorithm
Initialization commands
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.
41
Program
%ASK Modulation
clc;
clear all;
close all;
%GENERATE CARRIER SIGNAL
Tb=1; fc=10;
t=0:Tb/100:1;
c=sqrt(2/Tb)*sin(2*pi*fc*t);
%generate message signal
N=8;
m=rand(1,N);
t1=0;t2=Tb
for i=1:N
t=[t1:.01:t2]
if m(i)>0.5
m(i)=1;
m_s=ones(1,length(t));
else
m(i)=0;
m_s=zeros(1,length(t));
end
message(i,:)=m_s;
%product of carrier and message
ask_sig(i,:)=c.*m_s;
t1=t1+(Tb+.01);
t2=t2+(Tb+.01);
%plot the message and ASK signal
subplot(5,1,2);axis([0 N -2 2]);plot(t,message(i,:),'r');
title('message signal');xlabel('t--->');ylabel('m(t)');grid on
hold on
subplot(5,1,4);plot(t,ask_sig(i,:));
title('ASK signal');xlabel('t--->');ylabel('s(t)');grid on
hold on
end
hold off
%Plot the carrier signal and input binary data
subplot(5,1,3);plot(t,c);
title('carrier signal');xlabel('t--->');ylabel('c(t)');grid on
subplot(5,1,1);stem(m);
title('binary data bits');xlabel('n--->');ylabel('b(n)');grid on
% ASK Demodulation
t1=0;t2=Tb
for i=1:N
t=[t1:Tb/100:t2]
%correlator
x=sum(c.*ask_sig(i,:));
%decision device
if x>0
demod(i)=1;
else
demod(i)=0;
42
end
t1=t1+(Tb+.01);
t2=t2+(Tb+.01);
end
%plot demodulated binary data bits
subplot(5,1,5);stem(demod);
title('ASK demodulated signal'); xlabel('n--->');ylabel('b(n)');grid on
Model Graphs
Conclusion : The program for ASK modulation and demodulation has been simulated in
MATLAB and necessary graphs are plotted.
Experiment No. 9
43
FREQUENCY SHIFT KEYING
Aim: To generate and demodulate frequency shift keyed (FSK) signal using MATLAB
Theory
Generation of FSK
Frequency-shift keying (FSK) is a frequency modulation scheme in which digital information is
transmitted through discrete frequency changes of a carrier wave. The simplest FSK is binary
FSK (BFSK). BFSK uses a pair of discrete frequencies to transmit binary (0s and 1s)
information. With this scheme, the "1" is called the mark frequency and the "0" is called the
space frequency.
In binary FSK system, symbol 1 & 0 are distinguished from each other by transmitting one of the
two sinusoidal waves that differ in frequency by a fixed amount.
Si (t) = √2E/Tb cos 2πf1t 0≤ t ≤Tb
0 elsewhere
Where i=1, 2 & Eb=Transmitted energy/bit
Transmitted freq= ƒi = (nc+i)/Tb, and n = constant (integer), Tb = bit interval
Symbol 1 is represented by S1 (t)
Symbol 0 is represented by S0 (t)
BFSK Transmitter
The input binary sequence is represented in its ON-OFF form, with symbol 1 represented
by constant amplitude of √Eb with & symbol 0 represented by zero volts. By using inverter
in the lower channel, we in effect make sure that when symbol 1is at the input, The two
frequency f1& f2 are chosen to be equal integer multiples of the bit rate 1/T b.By summing
the upper & lower channel outputs, we get BFSK signal.
BFSK Receiver
The receiver consists of two correlators with common inputs which are supplied with
locally generated coherent reference signals c 1(t) and c2 (t).
The correlator outputs are then subtracted one from the other, and the resulting
difference x is compared with a threshold of zero volts. If x >0, the receiver decides in
favour of symbol 1 and if x <0, the receiver decides in favour of symbol 0.
Algorithm
Initialization commands
FSK modulation
FSK demodulation
1. Start FOR loop
44
2. Perform correlation of FSK modulated signal with carrier 1 and carrier 2 to get two decision
variables x1 and x2.
3. Make decisionon x = x1-x2 to get demodulated binary data. If x>0, choose ‘1’ else choose
‘0’.
4. Plot the demodulated binary data.
45
Program
% FSK Modulation
clc;
clear all;
close all;
%GENERATE CARRIER SIGNAL
Tb=1; fc1=2;fc2=5;
t=0:(Tb/100):Tb;
c1=sqrt(2/Tb)*sin(2*pi*fc1*t);
c2=sqrt(2/Tb)*sin(2*pi*fc2*t);
%generate message signal
N=8;
m=rand(1,N);
t1=0;t2=Tb
for i=1:N
t=[t1:(Tb/100):t2]
if m(i)>0.5
m(i)=1;
m_s=ones(1,length(t));
invm_s=zeros(1,length(t));
else
m(i)=0;
m_s=zeros(1,length(t));
invm_s=ones(1,length(t));
end
message(i,:)=m_s;
%Multiplier
fsk_sig1(i,:)=c1.*m_s;
fsk_sig2(i,:)=c2.*invm_s;
fsk=fsk_sig1+fsk_sig2;
%plotting the message signal and the modulated signal
subplot(3,2,2);axis([0 N -2 2]);plot(t,message(i,:),'r');
title('message signal');xlabel('t---->');ylabel('m(t)');grid on;hold on;
subplot(3,2,5);plot(t,fsk(i,:));
title('FSK signal');xlabel('t---->');ylabel('s(t)');grid on;hold on;
t1=t1+(Tb+.01); t2=t2+(Tb+.01);
end
hold off
%Plotting binary data bits and carrier signal
subplot(3,2,1);stem(m);
title('binary data');xlabel('n---->'); ylabel('b(n)');grid on;
subplot(3,2,3);plot(t,c1);
title('carrier signal-1');xlabel('t---->');ylabel('c1(t)');grid on;
subplot(3,2,4);plot(t,c2);
title('carrier signal-2');xlabel('t---->');ylabel('c2(t)');grid on; 13
46
% FSK Demodulation
t1=0;t2=Tb
for i=1:N
t=[t1:(Tb/100):t2]
%correlator
x1=sum(c1.*fsk_sig1(i,:));
x2=sum(c2.*fsk_sig2(i,:));
x=x1-x2;
%decision device
if x>0
demod(i)=1;
else
demod(i)=0;
end
t1=t1+(Tb+.01);
t2=t2+(Tb+.01);
end
%Plotting the demodulated data bits
subplot(3,2,6);stem(demod);
title(' demodulated data');xlabel('n---->');ylabel('b(n)'); grid on;
Modal Graphs
Conclusion : The program for FSK modulation and demodulation has been simulated in
MATLAB and necessary graphs are plotted.
47