0% found this document useful (0 votes)
5 views63 pages

DigitalElectronics Unit2 02

Uploaded by

manasgod109
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views63 pages

DigitalElectronics Unit2 02

Uploaded by

manasgod109
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 63

Digital Electronics: Introduction

Pritesh Shah & Shilpa Hudnurkar


[email protected] & [email protected]

Department of Electronics & Telecommunication Engineering,


Symbiosis Institute of Technologly, Pune

(SIT) Pritesh Shah August 2, 2017 1 / 61


Outline

1 lecture

2 Code Converter

3 Comparators

4 Parity Generator

5 Decoder

6 Encoder

7 MUX & DEMUX

8 Next Lecture

(SIT) Pritesh Shah August 2, 2017 2 / 61


lecture

This lecture

Code conversion (Binary to gray , gray to binary, binary to BCD)


comparators (1 bit, 2 - bit, 4- bit )
parity generation
Encoders (Octal to Binary, Decimal to BCD),
Decoders, keyboard and priority encoders
Multiplexer, Demultiplexer

(SIT) Pritesh Shah August 2, 2017 3 / 61


Code Converter

Code Converter

A code converter is a logic circuit whose inputs are bit patterns


representing numbers in one code and whose outputs are the
corresponding representation in a different code.
It makes two systems compatible even though each uses a different
binary code.
Code converters are usually multiple output circuits.
Code conversion circuit this transformation by means of logic gates.

(SIT) Pritesh Shah August 2, 2017 4 / 61


Code Converter

Code Converter

4 bit Binary to Gray Code


4 bit Gray Code to Binary
Binary to BCD

(SIT) Pritesh Shah August 2, 2017 5 / 61


Code Converter

Code Converter
Design of a 4 bit Binary to Gray Code Converter

(SIT) Pritesh Shah August 2, 2017 6 / 61


Code Converter

Code Converter: Binary to Gray

Design of a 4 bit Binary to Gray Code Converter

Figure

(SIT) Pritesh Shah August 2, 2017 7 / 61


Code Converter

Code Converter :Binary to Gray

Figure: Binary to Gary KMAP


(SIT) Pritesh Shah August 2, 2017 8 / 61
Code Converter

Code Converter :Binary to Gray

Figure: Logic Diagram :Binary to Gary

(SIT) Pritesh Shah August 2, 2017 9 / 61


Code Converter

Code Converter :Binary to Gray


Design of a 4 bit Gray to binary Code Converter

Figure
(SIT) Pritesh Shah August 2, 2017 10 / 61
Code Converter

Code Converter :Gray to binary

Figure

(SIT) Pritesh Shah August 2, 2017 11 / 61


Code Converter

Code Converter :Gray to binary

Figure
(SIT) Pritesh Shah August 2, 2017 12 / 61
Code Converter

Code Converter :Gray to binary

Figure: Logic Diagram: Gray to binary

(SIT) Pritesh Shah August 2, 2017 13 / 61


Code Converter

Code Converter : Binary to BCD

Figure: Binary to BCD Code Converter

(SIT) Pritesh Shah August 2, 2017 14 / 61


Code Converter

Code Converter : Binary to BCD

Figure: Binary to BCD Code Converter

(SIT) Pritesh Shah August 2, 2017 15 / 61


Code Converter

Code Converter : Binary to BCD

Figure: Binary to BCD Code Converter


(SIT) Pritesh Shah August 2, 2017 16 / 61
Code Converter

Code Converter : Binary to BCD

Figure: Binary to BCD Code Converter

(SIT) Pritesh Shah August 2, 2017 17 / 61


Comparators

Comparators

A comparator is a logic circuit used to compare the magnitudes of


two binary numbers.
The X-NOR gate is basic comparator.

(SIT) Pritesh Shah August 2, 2017 18 / 61


Comparators

1 Bit Comparators

Figure

(SIT) Pritesh Shah August 2, 2017 19 / 61


Comparators

1 Bit Comparators

Figure

(SIT) Pritesh Shah August 2, 2017 20 / 61


Comparators

2 Bit Comparators

Figure

(SIT) Pritesh Shah August 2, 2017 21 / 61


Comparators

2 Bit Comparators

Figure
(SIT) Pritesh Shah August 2, 2017 22 / 61
Comparators

4 Bit Comparators

Figure

(SIT) Pritesh Shah August 2, 2017 23 / 61


Comparators

4 Bit Comparators

Figure

(SIT) Pritesh Shah August 2, 2017 24 / 61


Comparators

4 Bit Comparators

(SIT) Figure
Pritesh Shah August 2, 2017 25 / 61
Parity Generator

Parity Generator

Binary data, when transmitted and processed, is susceptible to noise


that can alter its 1s to 0s and 0s to 1s.
To detect such error, an additional bit called the parity bit is added
to the data bits and the word containing the data bits and parity bit
is transmitted.
At the receiving end the number 1s in the word received are counted
and the error, if any, is detected.
This parity check, however detects only single bit error.
The circuit that generates the parity bit in the transmitter is called a
parity generator and circuit that checks the parity in the receiver is
called parity checker.

(SIT) Pritesh Shah August 2, 2017 26 / 61


Parity Generator

Parity Generator

In order to check or generate the proper parity bit in a given code


word, the basic principle used is, the modulo sum of an even number
of 1s is always a 0 and the modulo sum of an odd number of 1s is
always a 1.
In order to check for an error, all the bits received word are added.
If the modulo sum is a 0 for an odd parity system or a 1 for an even
parity system, an error is detected.

(SIT) Pritesh Shah August 2, 2017 27 / 61


Parity Generator

Even Parity Generator

To generate an even parity bit, the four data bits are added using 3
X-OR gates.
The sum bit will be the parity bit.

Figure: Even Parity Generator

(SIT) Pritesh Shah August 2, 2017 28 / 61


Parity Generator

Odd Parity Generator

To generate an odd parity bit, the four data bits are added using 3
X-OR gates and the sum bit is inverted.

Figure: Odd Parity Generator

(SIT) Pritesh Shah August 2, 2017 29 / 61


Parity Generator

Even and Odd Parity Checker

Figure: Even and Odd Parity Checker

(SIT) Pritesh Shah August 2, 2017 30 / 61


Decoder

Decoder
A decoder is a logic circuit that converts an N-bit binary input code
into M output lines such that only one output line is activated for
each of the possible combinations of inputs.
A decoder identifies or recognizes or detects a particular code.

(SIT)
Figure
Pritesh Shah August 2, 2017 31 / 61
Decoder

Decoder

For each of these input combinations only one of the M outputs will
be active(HIGH), all the other outputs will remain inactive(LOW).
Some decoders have one or more ENABLE inputs that are used to
control the operation of the decoder.
A BCD to decimal encoder has a 4 bit input code and 10 output lines
that correspond to the 10 BCD code groups 0000 to 1001.
This type of decoder, don’t utilize all of 2N possible input codes.

(SIT) Pritesh Shah August 2, 2017 32 / 61


Decoder

3 to 8 Line Decoder

Figure: 3 to 8 Line Decoder

(SIT) Pritesh Shah August 2, 2017 33 / 61


Decoder

3 to 8 Line Decoder: Binary to Octal

Figure: 3 to 8 Line Decoder

(SIT) Pritesh Shah August 2, 2017 34 / 61


Decoder

Decoder Application

A decoder provides 2n minterms of n input variables.


Any boolean function can be expressed in sum of minterms, one can
use a decoder to generate the minterms and an external OR gate to
form the logic sum.
In this way combinational circuit with n inputs and m outputs can be
implemented with an n-to-2n decoder and m OR gates.

(SIT) Pritesh Shah August 2, 2017 35 / 61


Decoder

Decoder Application

Design of 4 to 16 Decoders from two 3 to 8 decoders.

Figure: Design of 4 to 16 Decoders

(SIT) Pritesh Shah August 2, 2017 36 / 61


Decoder

Decoder Application

BCD to Seven Segment Decoders


This type of decoder accept the BCD code and provides outputs to
energize seven segment display devices in order to produce a decimal
readout.
Each segment is made up of a martial that emit light when current is
passed through it.
The most commonly used martial include LEDs, LCDs, incandescent
filaments.
There are two type of LED display
1 Common Anode type: a low voltage applied to an LED cathode
allows current to flow through the diode, which cause emit light.
2 Common Cathode type: a high voltage applied to an LED cathode
allows current to flow through the diode, which cause emit light.

(SIT) Pritesh Shah August 2, 2017 37 / 61


Decoder

Decoder Application
BCD to Seven Segment Decoders

(SIT) Figure: DesignPritesh


of 4Shah
to 16 Decoders August 2, 2017 38 / 61
Decoder

Decoder Application
BCD to Seven Segment Decoders

Figure: Design of 4 to 16 Decoders

(SIT) Pritesh Shah August 2, 2017 39 / 61


Decoder

Decoder Application

Figure: Logic diagram of a full adder using a decoder

(SIT) Pritesh Shah August 2, 2017 40 / 61


Encoder

Encoder

An encoder is a device whose inputs are decimal digits and/or


alphabetic characters and whose outputs are the coded representation
of those inputs.
An encoder is a device which converts familiar numbers or symbols
into coded format.
An encoder may be said to be a combinational logic circuit that
performs the reverse operation of the decoder.
The opposite of the decoding process is called encoding.
An encoder has a number of input lines, only one of which is
activated at given time, and produces an N-bit code depending on
which input is activated.

(SIT) Pritesh Shah August 2, 2017 41 / 61


Encoder

Encoder

Figure: Block diagram of encoder

(SIT) Pritesh Shah August 2, 2017 42 / 61


Encoder

Octal to Binary Encoder


An octal to binary encoder (8 line to 3 line encoder) accepts 8 input
lines and produces a 3 bit output code corresponding to the activated
input.

Figure: (SIT)
Block diagram of encoder Pritesh Shah August 2, 2017 43 / 61
Encoder

Octal to Binary Encoder

Figure: Logical diagram of encoder

(SIT) Pritesh Shah August 2, 2017 44 / 61


Encoder

Decimal to BCD Encoder

Figure: Decimal to BCD Encoder

(SIT) Pritesh Shah August 2, 2017 45 / 61


Encoder

Decimal to BCD Encoder

Figure: Decimal to BCD Encoder

(SIT) Pritesh Shah August 2, 2017 46 / 61


Encoder

Keyboard Encoder

Figure: Keyboard Encoder

(SIT) Pritesh Shah August 2, 2017 47 / 61


Encoder

Priority Encoder

The decoder discussed so far will operate correctly, provided that one
and only one decimal input is HIGH at any given time.
In some cases, two or more decimal inputs may become HIGH at the
same time.
A priority encoder is a logic circuit that responds to just one input in
accordance with some priority system, among all those that may be
simultaneously HIGH.
The most common priority system is based on the relative magnitude
of the inputs, whichever decimal input is larger, is the one that is
encoded.
A priority encoder would decode 4 if both 3 and 4 are simultaneously
HIGH.

(SIT) Pritesh Shah August 2, 2017 48 / 61


Encoder

4 Input Priority Encoder

Figure: 4 Input Priority Encoder

(SIT) Pritesh Shah August 2, 2017 49 / 61


MUX & DEMUX

Multiplexers

Multiplexing means sharing.


They are two types of multiplexing- time and frequency multiplexing.
A multiplexer (MUX) or data selector is a logic circuit that
accepts several data inputs and allows only one of them at a time to
go through to the output.
The routing of the desired data input to the output is controlled by
SELECT inputs(ADDRESS inputs).
Normally there are 2n input lines and n select lines whose bit
combinations determine which input is selected.
The multiplexer acts like a digitally controlled multi position switch.
The digital code applied to the SELECT inputs determines which
data inputs will be switched to the output.
Also called as 1 out of N input

(SIT) Pritesh Shah August 2, 2017 50 / 61


MUX & DEMUX

Multiplexers

Figure: Multiplexers

(SIT) Pritesh Shah August 2, 2017 51 / 61


MUX & DEMUX

Basic 2 Input Multiplexers

Figure: 2 Input Multiplexers

(SIT) Pritesh Shah August 2, 2017 52 / 61


MUX & DEMUX

Basic 4 Input Multiplexers

Figure: 4 Input Multiplexers


(SIT) Pritesh Shah August 2, 2017 53 / 61
MUX & DEMUX

16 Input MUX from 8 Input MUX

Figure: 16 Input MUX from 8 Input MUX

(SIT) Pritesh Shah August 2, 2017 54 / 61


MUX & DEMUX

Applications of MUX

Data Selection
Data Routing
Operation Sequencing
Parallel to serial conversion
Waveform Generation
Logic Function Generator

(SIT) Pritesh Shah August 2, 2017 55 / 61


MUX & DEMUX

Logic Function Generator using MUX

A MUX can be used in place of logic gates to implement a logic expression.


Examples:
1 use a MUX to implement the logic function F= A ⊕ B ⊕ C

(SIT) Pritesh Shah August 2, 2017 56 / 61


MUX & DEMUX

Logic Function Generator using MUX

A MUX can be used in place of logic gates to implement a logic expression.


Examples:
1 use a MUX to implement the logic function F= A ⊕ B ⊕ C
2 Use a MUX having three data select inputs to implement the logic for
the function
P given below. Also realize the same using a 16:1 MUX.
F = m(0, 1, 2, 3, 4, 10, 11, 14, 15)

(SIT) Pritesh Shah August 2, 2017 56 / 61


MUX & DEMUX

Logic Function Generator using MUX

A MUX can be used in place of logic gates to implement a logic expression.


Examples:
1 use a MUX to implement the logic function F= A ⊕ B ⊕ C
2 Use a MUX having three data select inputs to implement the logic for
the function
P given below. Also realize the same using a 16:1 MUX.
F = m(0, 1, 2, 3, 4, 10, 11, 14, 15)
3 Implement the function F (a, b, c) = ab + b̄c using a 4:1 MUX.

(SIT) Pritesh Shah August 2, 2017 56 / 61


MUX & DEMUX

Demultiplexer

A MUX takes several inputs and transmit one of them to the output.
A demultiplexer performs the reverse operation, it takes a single input
and distributes it over several outputs.
A demultiplexer can be through of as a ’distributor’.
The demux takes one input data source and selectively distributes it
to 1 of N output channels just like a multi position switch.
Also called as 1 to N (2n ) device

(SIT) Pritesh Shah August 2, 2017 57 / 61


MUX & DEMUX

Demultiplexer

Figure: Functional diagram of a general demultiplexer

(SIT) Pritesh Shah August 2, 2017 58 / 61


MUX & DEMUX

1 to 4 Line Demultiplexer

Figure: 1 to 4 Line Demultiplexer

(SIT) Pritesh Shah August 2, 2017 59 / 61


Next Lecture

Next Lecture

Programmable Logic Devices

(SIT) Pritesh Shah August 2, 2017 60 / 61


Next Lecture

Thank You

(SIT) Pritesh Shah August 2, 2017 61 / 61

You might also like