DATA COMMUNICATION TRAINER
Transcript of DATA COMMUNICATION TRAINER
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
DATA COMMUNICATION TRAINER
MODEL -X31
OBJECTIVE:
To study the following experiments through AT89C51 using the Data formats such as
NRZ, RZ, and Manchester.
Data Formatting
Amplitude Shift Keying (ASK)
Frequency Shift Keying (FSK):
Phase Shift Keying (PSK)
Quadrature Phase Shift Keying (QPSK)
MATERIALS REQUIRED:
DATA COMMUNICATION TRAINER, Model X-31
Patch cords
Oscilloscope
INTRODUCTION:
The LAB ELECTRONICS DATA COMMUNICATION TRAINER, Model
X-31 is designed to help the students to understand the concepts of DATA
Communication. Students can conduct experiments on modulation & demodulation
through 8-Bit Microcontroller. The AT89C51 is a low-power, high-performance CMOS
8-bit microcomputer with 4K bytes of Flash Programmable and Erasable Read Only
Memory (PEROM). The device is manufactured using Atmel’s high-density nonvolatile
memory technology and is compatible with the industry standard MCS-51™
instruction set and pin out. The on-chip Flash allows the program memory to be
reprogrammed in-system or by a conventional nonvolatile memory programmer.
LAB ELECTRONICS
X31
PAGE: 2
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
By combining a versatile 8-bit CPU with Flash on a monolithic chip, the Atmel
AT89C51 is a powerful microcomputer which provides a highly flexible and cost
effective solution to many embedded control applications.
FEATURES OF THIS TRAINER:
1. MODULATOR & DEMODULATOR CONTROLLERS 89C51
Compatible with MCS-51™ Products
4K Bytes of In-System Reprogrammable Flash Memory
Endurance: 1,000 Write/Erase Cycles
Fully Static Operation: 0 Hz to 24 MHz
Three-Level Program Memory Lock
128 x 8-Bit Internal RAM
32 Programmable I/O Lines
Two 16-Bit Timer/Counters
Six Interrupt Sources
Programmable Serial Channel
Low Power Idle and Power Down Modes
Reset Switch To Reset Both Controllers.
2. CARRIER SOURCE:
Output Waveforms : Sine Cosine
Frequency Range : 1 KHz to 20 KHz. 1 KHz to 20 KHz
Amplitude Range : 0 -9V (P-P) 0 -9V (P-P).
3. Built-in power supply : +12V/1A: 5V /1A
4. Data Selector Switch : 8 bit data output Data LO
Data HI
X31
PAGE: 3
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
MSB LSB
5. Mode selector switch: MSB LSB FUNCTION
X 0 0 0 ASK
X 0 0 1 FSK
0 0 1 0 PSK
1 0 1 1 QPSK
X 1 0 0 NRZ
X 1 0 1 RZ
X 1 1 0 MANCHESTER
NOTE: 7 LEDS are provided to observe the corresponding enabled mode.
6. Functional Block Diagram: ASK, FSK, PSK and QPSK Modulation/Demodulation.
LSB
X31
PAGE: 4
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
LIST OF EXPERIMENTS:
1. Data formatting
NRZ (Non-Return to Zero)
RZ (Return to Zero)
MANCHESTER
2. MODULATION & DEMODULATION (MODEM)
Amplitude Shift Keying (ASK)
Frequency Shift Keying (FSK)
Phase Shift Keying (PSK)
Quadrature Phase Shift Keying (QPSK)
PRECAUTIONS TO BE TAKEN:
ALWAYS SWITCH OFF THE TRAINER WHILE PATCHING THE CIRCUIT. DO
NOT SHORT CIRCUIT BY PATCHING SUPPLY POINT TO THE GROUND
TERMINAL PROVIDED IN THE TRAINER.
X31
PAGE: 5
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
DATA FORMATTING
EXPERIMENT-1
OBJECTIVE:
To study the Data Formatting.
MATERIALS REQUIRED:
1. LAB DATA COMMUNICATION Trainer.-2, Model X-31
2. oscilloscope
3. Set of Patching Chords.
THEORY OF DATA FORMATTING:
The symbols ‘0’ and ‘1’ in digital systems can be represented in various formats
with different levels & waveforms. The selection of particular format for communication
depends on the system bandwidth, system's ability to pass DC level information, error
checking facility, case of clock regeneration & synchronization at receiver, system
complexity & cost etc.
The most widely used formats of data representation are given below. Every data
format has specific advantages & disadvantages associated with them.
X31
PAGE: 6
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
NON - RETURN TO ZERO (LEVEL) NRZ (L):
It is the simplest form of data representation. The NRZ (L) waveform simply
goes low for one bit time to represent a data '0' & high for one bit time to represent a
data ‘1’. Thus the signal alternates only when there is a data change.
In telecommunication, a non-return-to-zero (NRZ) line code is a binary code, in
which "1s" are represented by one significant condition and "0s" are represented by
the other significant condition, with no other neutral or rest condition. The pulses have
more energy than a RZ code. Unlike RZ, NRZ does not have a rest state. NRZ is not
inherently a self-synchronizing code, so some additional synchronization technique
(perhaps a run length limited constraint or a parallel synchronization signal) must be
used to avoid bit slip. For a given data signaling rate, i.e., bit rate, the NRZ code
requires only half the bandwidth required by the Manchester code. When used to
represent data in an asynchronous communication scheme, the absence of a neutral
state requires other mechanisms for data recovery, to replace methods used for error
detection when using synchronization information, a separate clock signal is available.
NRZ-Level itself is not a synchronous system but rather an encoding; this can be used
in either a synchronous or asynchronous transmission environment, that is, with or
without an explicit clock signal involved.
Because of this, it is not strictly necessary to discuss how the NRZ Level
encoding acts "on a clock edge" or "during a clock cycle", since all transitions happen
in the given amount of time representing the actual or implied integral clock cycle.
X31
PAGE: 7
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
The real question is that of sampling the high or low state which will be received
correctly provided the transmission line has stabilized for that bit when the physical
line level is sampled at the receiving end. However it is handy to see NRZ transitions
as happening on the trailing (falling) clock edge in order to compare NRZ-Level to
other encoding methods, such as the mentioned Manchester code, which requires
clock edge information (is the XOR of the clock and NRZ) and to see the difference
between NRZ-Mark and NRZ-Inverted.
STEP BY STEP PROCEDURE:
STUDY OF NRZ OUTPUT :
1. Switch on the trainer
Mode selection
2. To study Data formatting set the Mode selection switches as in the following
position: Mode selection switch is used to select the modulation as well as Data
formatting types.
S1 S2 S3 S4 Mode
X 1 0 0 NON RETURN TO ZERO
Note: Depress -reset switch after changing each mode.
Example:
Change the mode selector as ‘X100’ and then press RESET switch for
selecting Return to Zero data formatting.
X’-defined as don’t care, i.e., which doesn’t affect the process.
2. Now set the data selection switch to HI /LO position to get serial data stream from
microcontroller.
X31
PAGE: 8
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
DATA SELECTION:
8-Bit Data selector is used to give the data parallel to the controller.
S1 S2 S3 S4 S5 S6 S7 S8
D7 D6 D5 D4 D3 D2 D1 D0
MSB LSB
Data selector switch is used to select the data. If the switch position is upward
‘ ‘ then logic ‘1’ is given.
If dip switch is in downward position ‘ ‘then logic ‘0’ is given.
Observe the NRZ output at data formatting terminal.
Data is formatted according to data selector.
RZ: Return-to-zero (RZ) describes a line code used in telecommunications signals
in which the signal drops (returns) to zero between each pulse. This takes place even
if a number of consecutive zeros or ones occur in the signal. The signal is self-
clocking. This means that a separate clock does not need to be sent alongside the
signal, but suffers from using twice the bandwidth to achieve the same data-rate as
compared to non-return-to-zero format.
The "zero" between each bit is a neutral or rest condition, such as a zero
amplitude in pulse amplitude modulation (PAM), zero phase shift in phase-shift
keying(PSK), or mid-frequency in frequency-shift keying (FSK). That "zero" condition
is typically halfway between the significant condition representing a 1 bit and the other
significant condition representing a 0 bit.
X31
PAGE: 9
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
Although return-to-zero (RZ) contains a provision for synchronization, it still has a DC
component resulting in “baseline wander” during long strings of 0 or 1 bits, just like the
line code Non-return-to-zero.
STUDY OF RZ OUTPUT
MODE SELECTION
1. To study Data formatting set the Mode selection switches as in the following
position: Mode selection switch is used to select the modulation as well as Data
formatting types.
S1 S2 S3 S4 Mode
X 1 0 1 RETURN TO ZERO
Note: Depress reset switch after changing each mode.
Example:
Change the mode selector as ‘X101’ and then press RESET switch for
selecting Return to Zero data formatting.
‘X’ is defined as don’t care, i.e., which doesn’t affect the process.
2. Now set the data selection switch to HI /LO position to get serial data stream from
microcontroller.
DATA SELECTION:
8-Bit Data selector is used to give the data parallel to the controller.
S1 S2 S3 S4 S5 S6 S7 S8
D7 D6 D5 D4 D3 D2 D1 D0
MSB LSB
X31
PAGE: 10
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
Data selector switch are used to select the data. If the switch position is upward
‘ ‘then logic ‘1’ is given.
If dip switch is in downward position ‘ ‘then logic ‘0’ is given.
3. If the controller is working in the RZ Data formatting mode. You will observe RZ
Data in the Data Formatting Output terminal.
4. Micro Controller port P0.0 & 0.1 gives the corresponding data formatted output
according to the input data stream.
5. The O/P is connected from microcontroller to data formatting terminal.
RZ OUTPUT
MANCHESTER CODE:
Manchester code (also known as Phase Encoding or PE) is a line code in which
the encoding of each data bit has at least one transition. It is therefore self-
clocking, which means that a clock can be recovered from the encoded data. Each
bit occupies the same time. Manchester code is widely used (e.g. in Ethernet).
There are more complex codes e.g. 8B/10B encoding which use less bandwidth to
achieve the same data rate (but which may be less tolerant of frequency errors
and jitter in the transmitter and receiver reference clocks).
Manchester code provides simple encoding with no long period without a level
transition. This helps clock recovery. The DC component of the encoded signal is
equal to zero and therefore carries no information, so that the signal can be
conveyed conveniently by media (e.g. radio) which usually do not convey a DC
component.
X31
PAGE: 11
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
SUMMARY:
Each bit is transmitted in a fixed time (the "period").
A 0 is expressed by a low-to-high transition, a 1 by high-to-low transition. The
transitions which signify 0 or 1 occur at the midpoint of a period.
Transitions at the start of a period are overhead and don't signify data.
Manchester code always has a transition at the middle of each bit period and
may (depending on the information to be transmitted) have a transition at the start of
the period also. The direction of the mid-bit transition indicates the data. Transitions at
the period boundaries do not carry information.
They exist only to place the signal in the correct state to allow the mid-bit
transition. Although this allows the signal to be self-clocking, it doubles the bandwidth
requirement compared to NRZ coding schemes (or see also NRZI).
In the Thomas convention, the result is that the first
half of a bit period matches the information bit and the second half is its complement.
MANCHESTER ENCODING AS PHASE-SHIFT KEYING
Manchester encoding is a special case of binary phase-shift keying (BPSK),
where the data controls the phase of a square wave carrier whose frequency is the
data rate. Such a signal is easy to generate.
To control the bandwidth used, a filter can reduce the bandwidth to as low as
1Hz per bit/second without loss of information in transmission. However, for practical
reasons (and to limit bandwidth consumption further, especially on crowded radio
bands), most BPSK modulators choose a carrier frequency much higher than the data
rate, resulting in tighter, more easily filtered bandwidths, but the property of 1Hz per
bit/second is preserved.
CONVENTIONAL REPRESENTATION OF DATA:
X31
PAGE: 12
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
Encoding of 11011000100 in Manchester code
There are two opposing conventions for the representation of data.
It specifies that for a 0 bit the signal levels will be Low-High (assuming an
amplitude physical encoding of the data) - with a low level in the first half of the bit
period, and a high level in the second half. For a 1 bit, the signal levels will be High-
Low.
It states that logic 0 is represented by a High-Low signal sequence and logic 1 is
represented by a Low-High signal sequence. If a Manchester encoded signal is
inverted in communication, it is transformed from one convention to the other.
This ambiguity can be overcome by using differential Manchester encoding.
Manchester code needs twice the bandwidth of asynchronous communication and the
signal spectrum is much wider. Most high-speed communication now uses encoding
schemes with better coding performance.
One consideration is synchronization of the receiver to the transmitter. It might appear
that a half bit period error would give an inverted output at the receiver, but for typical
data this leads to code violations. The receiver can detect these violations and use
this information to synchronize accurately.
STUDY OF MANCHESTER CODING
1. To get Manchester coding, mode selection should be ‘X 1 1 0’.
2. Observe the Manchester coding output at the data formatting terminal.
3. Data is formatted according to data selector.
X31
PAGE: 13
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
EXPERIMENT-2
ASK MODULATION AND DEMODULATION
OBJECTIVE:
To study the ASK Modulation and Demodulation.
MATERIALS REQUIRED:
1. LAB DATA COMMUNICATION Trainer , Model X-31.
2. Oscilloscope
3. Set of Patching Cords.
INTRODUCTION:
CARRIER MODULATION
To transmit the digital data from one place to another, we have to choose the
transmission media. The simplest possible method to connect the transmitter to the
receiver with a piece of wire. This works satisfactorily for short distances in some
cases. But for long distance communication & in situations like communication with
the aircraft, ship, and vehicle this is not feasible. Here we have to adopt for the radio
transmission.
It is not possible to send the digital data directly over the antenna because the
antennae of practical size work on very high frequencies, much higher than our data
transmission rate. To be able to transmit the data over antenna, we have to 'modulate'
the signal's phase; frequency or amplitude etc is varied in accordance with the digital
data. At receiver we separate the signal from digital information by the process of
demodulation. After this process we are left with high frequency signal (called as
carrier Signal) which we discard & the digital information, which we utilize.
Modulation also allows different data streams to be transmitted over the same
channel (transmission medium). This process is called as 'Multiplexing' & result in a
considerable saving in no. of channels to be used. Also it increases the channel
efficiency. The variation of particular parameter variation of the carrier wave gives rise
X31
PAGE: 14
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
to various modulation techniques. Some of the basic modulation techniques are
described as under.
(A) Amplitude Shift Keying (ASK)
In these techniques modulation involves the variation of the amplitude of the
carrier- wave in accordance with the data stream.
B) Frequency Shift Keying (FSK):
In these techniques modulation involves the variation of carrier frequency with the
data information.
(C) Phase Shift Keying (PSK):
In this technique, the phase of the carrier frequency is varied in accordance
with the data stream. The selection of particular modulation method used is
determined by the application intended as well as by the channel characteristic such
as available bandwidth, susceptibility of channel fading, antenna characteristics, ability
to transmit D.C or low frequencies etc. The last criterion is necessary when data
transmission using a telephone channel is intended, because of transformer or series
capacitors getting included in the transmission path. EX-FSK is very useful in a fading
channel because it is relatively insensitive to amplitude function. A fading channel is
one in which the received signal amplitude varies with the time because of variability’s
in the transmission medium
AMPLITUDE SHIFT KEYING
The simplest method of modulating a carrier with a data stream is to change
the amplitude of the carrier wave every time the data changes. This modulation
technique is known as Amplitude Shift Keying.
The simplest way of achieving amplitude shift keying is by switching 'ON' the
carrier whenever the data bit is '1' & switching 'OFF' whenever the data bit is '0 i.e. the
transmitter outputs the carrier for a ' 1 ' & totally suppresses the carrier for a '0'. This
technique is known as ON-OFF keying. Fig 11 illustrates the amplitude shift keying for
the given data stream. Thus
DATA = 1 CARRIER TRANSMITTED
DATA = 0 CARRIER SUPPRESSED
X31
PAGE: 15
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
The ASK waveform is generated by a balanced modulator circuit, also known
as a linear multiplier. As the name suggests, the device multiplies the instantaneous
signal at its two inputs.
The output voltage is being the product of the two input voltages at any
instance of time. One of the inputs is A.C Coupled 'carrier' wave of high frequency.
Generally, the carrier wave is a sine wave since any other waveform would increase
the Bandwidth, without providing any advantages. The other input which the
information signals to be transmitted is D.C coupled. It is known as modulating signal
carrier input & the digital data stream at modulation input.
STEP BY STEP PROCEDURE (ASK):
1. Patch the circuit as shown in the wiring diagram and switch on the trainer
2. To study modulation/demodulation set the Mode selection switches in the
corresponding positions.
MODE SELECTION:
Mode selection is used to select the modulation type. This is selected as follows.
Select Mode selector switches is as
S1 S2 S3 S4
X 0 0 0
X
Note:
After each operation depress reset switch.
Example:
If you need to change ASK modulation to FSK modulation, then change the mode
selector as ‘X 0 0 1’ and then press RESET switch.
3. Now select the data stream as mentioned above.
Dip switches are used to select the data and modes. If the switch position is
upward ‘ ‘then logic ‘1’ is given.
If dip switch is in downward position ‘ ‘then logic ‘0’ is given.
Don’t give any external voltage to microcontroller. It may affect the micro
controller ports.
X31
PAGE: 16
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
4. Now controller is working in the ASK modulation/demodulation mode.
5. Micro Controller port P2.5 - ASK modulation.
6. The o/p is connected from microcontroller to ASKMOD terminal
ASK DEMODULATION:
7. ASK modulation is given to ASK demodulation I/P.
8. This is given to demodulator controller input. Now controller gives the ASK
demodulated O/P through ASK demodulation test point.
Micro Controller PIN output configuration:
ASK demodulation-IN – P1.5 & OUT –P 2.5
CONCLUSION:
Whenever the data bit is ’1’, the carrier is switched on & whenever the data bit is ‘0’
the carrier is switched off i.e. the transmitter outputs the carrier for a ‘1’ & totally
suppresses the carrier for a ‘0’.
ASK SIMULATED OUTPUT
X31
PAGE: 17
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
WIRING DIAGRAM
ASK MODEM
.
INDICATES PATCHING CONNECTION
LAB ElectronicsMODEL-X31 MADE IN INDIA
POWER CARRIER GENERATOR MICROCONTROLLER SECTION
FSK MODEMASK MODEM PSK MODEM QPSK MODEM
DATA SELECTOR
DATA FORMATTING
MODE SELECTOR
DIGITAL COMMUNICATION TRAINER - 2
FREQ.CTRL+5V +12V
-12V-5V
AMP.CTRL
FSK
O/P
ASK
O/P
DEMOD
O/P
PSK
O/P
ODD BITS
MULTIPLIERMULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
SUMMER
EVEN BITS
PSK
I/P
QPSK
O/P
QPSK
I/P
DEMOD
O/P
DEMOD
O/P
MUX
DE
MOD
O/P
ASK
FSK
PSK
QPSK
NRZ
RZ
MANCHESTER
NRZ RZ MANCHESTER
GNDCOSSINE
12MHzCRYSTAL
12MHzCRYSTAL
+
+
+
+
NOT
X
X
XX
X
X
X
X
X
X
X
1
S
1
S
1 if z>0
0 if z<0
ODD BITS
EVEN BITS
440 878
2.637K
1K1K
1K
1K
2.6
37
K
1nf
1nf
+
+
+
+
+
-
-
-
-
-
SELLEN KEY FILTER
SELLEN KEY FILTER
SELLEN KEY FILTER
DEMOD
CIRCUIT
DATA
O/P
MODULATOR
DEMODULATOR
RESET
072TL
072TL072TL
X31
PAGE: 18
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
EXPERIMENT - 3
FSK MODULATION AND DEMODULATION
OBJECTIVE:
To study the Frequency Shift Keying (FSK) Modulation and Demodulation.
MATERIALS REQUIRED:
1. LAB DATA COMMUNICATION Trainer.
2. Set of Patching Cords.
3. Oscilloscope.
FSK MODULATION:
In FSK signal the low frequency represents data 0 and the high frequency
represents data 1. The Frequency Shift Keying (FSK) scheme is used in new
commercial DIGITAL COMMUNICATION. Because of its close behavior to the FM
modulation technique, FSK is replacing FM in the new digital based radio receivers
because of the benefits digital modulation has over analog ones, as we mentioned
previously. As in FM, the amplitude of the FSK modulated signal is constant, but it’s
the changes in the frequency that carries the signal information. .In our design we are
using Binary FSK, that uses two levels off frequencies, one is for transmitting a binary
1, the other is for transmitting binary 0.
In FSK the carrier frequency has been varied according the given input data,
i.e. If data is 1 then the carrier gets high frequency. If data is 0 then the carrier gets
low frequency. In this FSK modem carrier is generated internally and modulated
output is observed as pulses.
If the given data is 1, then the frequency of the generated pulses has high
frequency that is more number of pulses in a particular period of time. If the given data
X31
PAGE: 19
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
is 0 then the frequency of the generated pulses has low frequency that is less number
of pulses in a particular period of time
STEP BY STEP PROCEDURE (FSK):
1. Patch the circuit as shown in the wiring diagram for Frequency shift keying on the
front panel of the trainer.
2. Set the Mode selection switches in the proper position depending up on the
Modulation experiment which you are going to study.
MODE SELECTION:
Mode selection is used to select the modulation type. This is selected as follows.
When mode selected switch is in on condition, the corresponding LED glows.
S1 S2 S3 S4
X
X 0 0 1
Note: Every time-reset switch should be pressed, after changing the mode.
Example:
Change the mode selector as ‘X001’ and then press RESET switch.
3. Now set the data selection in the proper position according to the input data
stream.
DATA SELECTION:
8-Bit Data selector is used to give the data to the controller.
S1 S2 S3 S4 S5 S6 S7 S8
D7 D6 D5 D4 D3 D2 D1 D0
MSB LSB
Dip - switches are used to select the data and modes. If the switch position is
upward ‘ ‘then logic ‘1’ is given.
If dip switch is in downward position ‘ ‘then logic ‘0’ is given.
Now controller is working in the FSK modulation mode.
X31
PAGE: 20
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
Note:
‘X’-defined as don’t care, .i.e., which doesn’t affect the process.
Micro Controller port P2.4 gives the FSK modulation.
The o/p is connected from microcontroller to FSK terminal.
FSK DEMODULATION:
Connect the FSK modulated output to the FSK demodulated I/P.
This is given to demodulator controller input.
Now controller gives the FSK demodulated O/P through FSK demodulation test
point.
Micro controller PIN output configuration:
FSK modulation- P2.4 (modulator controller)
FSK demodulation (Demodulator controller) - IN - P1.4 & OUT P2.4
CONCLUSION: In FSK signal the low frequency represents data 0 and the high frequency represents
data 1.
DISCUSSION:
In FSK the carrier frequency has been varied according the given input data, i.e.
If data is 1 then the carrier gets high frequency
If data is 0 then the carrier gets low frequency
In this FSK modem, the carrier is generated internally and modulated output is
observed as pulses.
If the given data is 1, then the frequency of the generated pulses has high
frequency that is more number of pulses in a particular period of time.
If the given data is 0 then the frequency of the generated pulses has low frequency
that is less number of pulses in a particular period of time
X31
PAGE: 21
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
FSK SIMULATED OUTPUT
X31
PAGE: 22
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
WIRING DIAGRAM
FSK MODEM
.
INDICATES PATCHING CONNECTION
LAB ElectronicsMODEL-X31 MADE IN INDIA
POWER CARRIER GENERATOR MICROCONTROLLER SECTION
FSK MODEMASK MODEM PSK MODEM QPSK MODEM
DATA SELECTOR
DATA FORMATTING
MODE SELECTOR
DIGITAL COMMUNICATION TRAINER - 2
FREQ.CTRL+5V +12V
-12V-5V
AMP.CTRL
FSK
O/P
ASK
O/P
DEMOD
O/P
PSK
O/P
ODD BITS
MULTIPLIERMULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
SUMMER
EVEN BITS
PSK
I/P
QPSK
O/P
QPSK
I/P
DEMOD
O/P
DEMOD
O/P
MUX
DE
MOD
O/P
ASK
FSK
PSK
QPSK
NRZ
RZ
MANCHESTER
NRZ RZ MANCHESTER
GNDCOSSINE
12MHzCRYSTAL
12MHzCRYSTAL
+
+
+
+
NOT
X
X
XX
X
X
X
X
X
X
X
1
S
1
S
1 if z>0
0 if z<0
ODD BITS
EVEN BITS
440 878
2.637K
1K1K
1K
1K
2.6
37
K
1nf
1nf
+
+
+
+
+
-
-
-
-
-
SELLEN KEY FILTER
SELLEN KEY FILTER
SELLEN KEY FILTER
DEMOD
CIRCUIT
DATA
O/P
MODULATOR
DEMODULATOR
RESET
072TL
072TL072TL
X31
PAGE: 23
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
EXPERIMENT - 4
PSK MODULATION AND DEMODULATION
OBJECTIVE:
To study the Phase Shift Keying Modulation and Demodulation.
MATERIALS REQUIRED:
1. LAB DATA COMMUNICATION Trainer, Model x-31.
2. Set of Patching Cords.
3. Oscilloscope.
PHASE SHIFT KEYING (PSK):
In this technique, the phase of the carrier frequency is varied in accordance
with the data stream.
The selection of particular modulation method used is determined by the
application intended as well as by the channel characteristic such as available
bandwidth, susceptibility of channel fading, antenna characteristics, ability to transmit
D.C or low frequencies etc. The last criterion is necessary when data transmission
using a telephone channel is intended, because of transformer or series capacitors
getting included in the transmission path.
EX-FSK is very useful in a fading channel because it is relatively insensitive to
amplitude function. A fading channel is one in which the received signal amplitude
varies with the time because of variability’s in the transmission medium,
PSK SIGNAL CONSTELLATION
X31
PAGE: 24
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
PSK MODULATION The Phase Shift Keying (PSK) Digital Modulation scheme is also widely used in
modern communications, especially in satellite communications, where M-ary PSK
modulation techniques are used for their bandwidth efficiency. PSK is considered one
of the linear modulation techniques that has constant envelope. In the BPSK
modulation (Binary PSK, which is the one used here), the phase of the constant
amplitude signal is switched between two values according to two possible signals m1
and m2 corresponding to binary 1 and 0 respectively. Usually the phases are 1800
apart.
The equations of the two modulated signals are:
A block diagram of a BPSK system is shown in Figure below
Here the NRZ Encoder transforms the level of the binary input data into a +ve level for
the binary 1, and a -ve level for the binary 0 in order to change the carrier phases. The
average Probability of symbol error, or equivalently, the bit error rate for coherent
binary PSK is
PSK BLOCK DIAGRAM
X31
PAGE: 25
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
Here the Eb/No is double the one in its FSK counterpart, which means that we have to
double the Eb/No for the FSK signal in order to have the same average error rate as
the BPSK one. This is obvious when looking at the signal constellation of the BPSK
and the BFSK. The distance between the two binary points in the FSK constellation is
almost half the distance in the BPSK constellation, which means that the probability of
false decision in the FSK is double its PSK counter part. That’s why we need to
double the Eb/No for the FSK to compensate for and have the same average error
probability of its PSK counterpart. BPSK is considered bandwidth efficient and its
bandwidth efficiency in-creases with the increase of the number of bits per symbol,
this will affect its power efficiency. The channel band width required to pass M-ary
PSK signals is given by:
Where T is the symbol duration, Also using Rb = 1
The PSK bandwidth efficiency formula:
THE BANDWIDTH EFFICIENCY AND THE POWER EFFICIENCY OF THE M-LEVELS FOR
PSK MODULATION
We notice that the BPSK is more bandwidth efficient than its FSK counterpart, but
there is a trade off in its Power efficiency.
X31
PAGE: 26
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
PSK DEMODULATOR BLOCK DIAGRAM
As for the Demodulation process, for coherent detection, the basic demodulation
scheme is shown in Figure above
Here we have the incoming signal multiplied with a synchronized oscillator that has
the same frequency of the modulation frequency. These two are multi-plied together,
and the output is applied to a LPF (Low Pass Filter) to remove noise and to perform
integration on the incoming signal. The decision device follows giving the Binary
output.
PSK WAVEFORM:
X31
PAGE: 27
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
STEP BY STEP PROCEDURE (PSK):
1. Patch the circuit as shown in the wiring diagram for phase shift keying on the front
panel of the trainer.
2. OBSERVE the SINE INPUT to the phase shift keying circuit in the front panel of
the trainer.
Switch "ON" the trainer.
MODE SELECTION:
Mode selection is used to select the modulation type. This is selected as follows.
S1 S2 S3 S4
0 0 1 0
Note: Every time-reset switch should be pressed, after changing the mode.
Example:
Change the mode selector as ‘0010’ and then press RESET switch. Now controller
is working in the PSK modulation mode.
4. Now set the data selection in the proper position according to the input data
stream.
DATA SELECTION:
8-Bit Data selector is used to give the data to the controller.
S1 S2 S3 S4 S5 S6 S7 S8
D7 D6 D5 D4 D3 D2 D1 D0
MSB LSB
Dip - switches are used to select the data and modes. If the switch position is in
upward ‘ ‘then logic ‘1’ is given.
If dip switch is in downward position ‘ ‘then logic ‘0’ is given.
Now controller is working in the PSK modulation mode.
5. Micro Controller port P2.0&P2.1 gives data to the comparator for getting PSK
modulation.
X31
PAGE: 28
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
6. The o/p is connected to PSK MOD test point, Observe the PSK modulated output
in this test point
PSK DEMODULATION:
7. Connect PSK modulated output to PSK demodulation I/P.
The O/P of demodulation is given to demodulator controller input.
PSK demodulation- INPUT PORT - P1.0 & OUT- P2.3
8. Now controller gives the PSK demodulated O/P through PSK demodulation test
point.
CONCLUSION:
When logic level goes either from high to low or low to high the phase transitions will
be 1800.
SIMULATED OUTPUT
PSK MODULATED WAVEFORM
X31
PAGE: 29
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
PSK DEMODULATED WAVEFORM
X31
PAGE: 30
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
WIRING DIAGRAM
PSK MODEM
INDICATES PATCHING CONNECTIONS
POWER CARRIER GENERATOR MICROCONTROLLER SECTION
FSK MODEMASK MODEM PSK MODEM QPSK MODEM
DATA SELECTOR
DATA FORMATTING
MODE SELECTOR
FREQ.CTRL+5V +12V
-12V-5V
AMP.CTRL
FSK
O/P
ASK
O/P
DEMOD
O/P
PSK
O/P
ODD BITS
MULTIPLIERMULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
SUMMER
EVEN BITS
PSK
I/P
QPSK
O/P
QPSK
I/P
DEMOD
O/P
DEMOD
O/P
MUX
DE
MOD
O/P
ASK
FSK
PSK
QPSK
NRZ
RZ
MANCHESTER
NRZ RZ MANCHESTER
GNDCOSSINE
12MHzCRYSTAL
12MHzCRYSTAL
+
+
+
+
NOT
X
X
XX
X
X
X
X
X
X
X
1
S
1
S
1 if z>0
0 if z<0
ODD BITS
EVEN BITS
440 878
2.637K
1K1K
1K
1K
2.6
37
K
1nf
1nf
+
+
+
+
+
-
-
-
-
-
SELLEN KEY FILTER
SELLEN KEY FILTER
SELLEN KEY FILTER
DEMOD
CIRCUIT
DATA
O/P
MODULATOR
DEMODULATOR
RESET
072TL
072TL072TL
X31
PAGE: 31
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
EXPERIMENT - 5
QPSK MODULATION AND DEMODULATION
OBJECTIVE:
To study the Quadrature Phase Shift Keying Modulation and Demodulation.
MATERIALS REQUIRED:
1. LAB DATA COMMUNICATION Trainer, Model X-31.
2. Set of Patching Cords.
3. Oscilloscope.
QPSK MODULATION
The Quadrature Phase Shift Keying (QPSK) is a 4-ary PSK signal. The QPSK is a
modulation scheme widely used in Satellite Communications. As we mentioned
earlier, PSK signals are considered one of the linear modulation techniques, which are
well known of their bandwidth efficiency.
The phase of the carrier in the QPSK takes 1 of 4 equally spaced shifts, such as 0,
/2, , 3/2, where each value of phase corresponds to a unique pair of message bits.
The QPSK transmitted signal is defined by:
Another way of having a QPSK modulation is by using the phase
shifts./4.3/4.5/4.7/4.The QPSK modulator consists of two streams of PSK
modulators, one is fed with the Odd data sequence and the other with the even
sequence. Also one stream is modulated with a cos wave and the other with a sine
wave to have a /2 phase difference. As for the bandwidth and power efficiency
measures. The bandwidth efficiency of QPSK is twice that of PSK since we are
transmit-ting two bits per signal. The Average probability of bit error of the QPSK
signaling is
X31
PAGE: 32
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
THE TWO POSSIBLE QPSK SIGNAL CONSTELLATIONS
QPSK SIGNAL CONSTELLATION WITH ITS DECISION REGIONS
The Binary Dibit and its corresponding phase.
X31
PAGE: 33
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
QPSK MODULATOR BLOCK DIAGRAM
Surprisingly, the average probability of bit error of the QPSK is the same as that of the
PSK in AWGN channel4, while as much data can be sent in the same bandwidth.
Thus compared to PSK, QPSK provides twice the spectral efficiency with exactly the
same energy efficiency.
.
QPSK Demodulator Block diagram
X31
PAGE: 34
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
The input QPSK stream is applied to two sinusoidal modulators that are 90
apart. The outputs from the multipliers are then applied to two integrators that perform
both filtering and integration. After that the input is applied to a decision device that
determines the level received. The outputs from the decision devices are applied to a
multiplexer that performs parallel to serial data conversion, thus reconstructing the
final output data stream. In the circuit design section, this block diagram was satisfied
by substituting each of the blocks with a suitable circuit designed to perform its
function. The circuit gave impressive results. Figure below Illustrates an overall
graphical comparison for the Noise performance of the three schemes, the FSK, PSK,
and QPSK in AWGN:
X31
PAGE: 35
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
SINE AND COSINE WAVEFORM
QPSK WAVEFORM:
X31
PAGE: 36
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
SIMULATED OUTPUT
DATA ODD/EVEN
.
DATA
ODD
EVEN
X31
PAGE: 37
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
STEP BY STEP PROCEDURE (QPSK):
1. Patch the circuit as shown in the wiring diagram for quadrature phase shift keying
in the front panel of the trainer.
Switch "ON" the trainer and set the Mode selection switches in the proper position.
MODE SELECTION:
Mode selection is used to select the modulation type. This is selected as follows.
S1 S2 S3 S4
1 0 1 1
Note: Every time-reset switch should be pressed, after changing the mode.
Example:
Change the mode selector as ‘1011’ and then press RESET switch.
Now set the data selection in the proper position according to the input data
stream.
DATA SELECTION:
8-Bit Data selector is used to give the data to the controller.
S1 S2 S3 S4 S5 S6 S7 S8
D7 D6 D5 D4 D3 D2 D1 D0
MSB LSB
D6 D4 D2 D0 ----------- ODD DATA
D7 D5 D3 D1 ---------- EVEN DATA
Dip - switches are used to select the data and modes. If the switch position is
upward ‘ ‘ then logic ‘1’ is given.
If dip switch is in downward position ‘ ‘ then logic ‘0’ is given.
Now the controller is working in the QPSK modulation mode.
Port P2.3 & P2.2 are given to EVEN bit generating comparator and port P2.1 &
P2.0 are given to ODD bit generating comparator.
The o/p is connected from QPSK MOD test point.
X31
PAGE: 38
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
Connect SINE OUTPUT and COSINE OUTPUT from carrier generator section
to the QPSK modulation section.
Data odd and even are internally connected.
Finally observe the QPSK output at the corresponding test point.
QPSK DEMODULATION:
QPSK modulation is given to QPSK demodulation I/P.
This is given to demodulator controller input.
Now controller gives the QPSK demodulated O/P through QPSK demodulation
test point.
QPSK demodulation-IN- P1.0, P1.1& OUT- P2.2 Due to lower carrier frequency
you cannot observe the actual output for QPSK.
Vary the data switches and observe the corresponding demodulated output.
CONCLUSION:
In QPSK the carrier phase can change only once every 2T secs. If from one T interval
to the next one, neither bit stream changes sign, the carrier phase remains
unchanged. If one component aI(t) or aQ(t) changes sign, a phase change of /2
occurs. However if both components change sign then phase shift of occurs
QPSK MODULATED WAVEFORM
X31
PAGE: 39
LAB ELECTRONICS
NEW#5, II FLOOR, 10TH AVENUE, ASHOK NAGAR, CHENNAI-83
LAB ELECTRONICS
WIRING DIAGRAM
QPSK MODEM
POWER CARRIER GENERATOR MICROCONTROLLER SECTION
FSK MODEMASK MODEM PSK MODEM QPSK MODEM
DATA SELECTOR
DATA FORMATTING
MODE SELECTOR
FREQ.CTRL+5V +12V
-12V-5V
AMP.CTRL
FSK
O/P
ASK
O/P
DEMOD
O/P
PSK
O/P
ODD BITS
MULTIPLIERMULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIP LIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
MULTIPLIER
SUMMER
EVEN BITS
PSK
I/P
QPSK
O/P
QPSK
I/P
DEMOD
O/P
DEMOD
O/P
MUX
DE
MOD
O/P
ASK
FSK
PSK
QPSK
NRZ
RZ
MANCHESTER
NRZ RZ MANCHESTER
GNDCOSSINE
12MHz
CRYSTAL
12MHz
CRYSTAL
+
+
+
+
NOT
X
X
XX
X
X
X
X
X
X
X
1
S
1
S
1 if z>0
0 if z<0
ODD BITS
EVEN BITS
440 878
2.637K
1K1K
1K
1K
2.6
37K
1nf
1nf
+
+
+
+
+
-
-
-
-
-
SEL LEN KEY
FILTER
SEL LEN KEY
F ILTER
SEL LEN KEY
F ILTER
DEMODCIRCUIT
DATA O/P
MODULATOR
DEMODULATOR
RESET
072TL
072TL072TL
INDICATES PATCHING CONNECTIONS