Unit 5
Unit 5
)
(A Govt. Aided UGC Autonomous & NAAC Accredited Institute, Affiliated to R.G.P.V, Bhopal)
Unit-5
Introduction to Memory, Memory Decoding, Error Detection and
Correction, Programmable Logic Array, Programmable Array Logic,
Sequential Programmable Devices, RTL and DTL Circuits, TTL, ECL, MOS,
CMOS, Application Specific Integrated Circuits.
COURSE OUTCOMES
After completion of the course students would be able to:
CO1. explain the computer architecture for defining basic component and
functional unit.
CO2. recall different number system and solve the basic arithmetic operations.
CO3. develop the understanding of combinational circuits.
CO4. analyze the basic concept of sequential circuits.
CO5. compare various memories.
CO6. solve the boolean functions using logic gates.
---------------------------------------------------------------------------------------------------------------
5-1. Introduction
There are two types of memories that are used in digital
systems:
Random-access memory(RAM): perform both the write and
read operations.
Read-only memory(ROM): perform only the read operation.
G =31
G=30
RAM – 2
RAM - 1
2GB
G=30
Read/Write = 1
DataOut Mem[Address];
Read/Write =0
Mem[Address] DataIn;
Timing Waveforms (write)
The access time and cycle time
of the memory must be within a
time equal to a fixed number of
CPU clock cycles.
The memory enable and the
read/write signals must be
activated after the signals in
the address lines are stable to
avoid destroying data in other
memory words.
Enable and read/write signals
must stay active for at least
50ns.
Timing Waveforms (read)
The CPU can transfer
the data into one of its
internal registers
during the negative
transition of T3.
• A memory with 2k words of n bits per word requires k address lines that go into
kx2k decoder.
Coincident decoding
address
A decoder with k inputs
and 2k outputs requires 2k 10 X 1024
AND gates with k inputs
per gate.
Two decoding in a two-
dimensional selection
scheme can reduce the
number of inputs per gate.
1K-word memory, instead
of using a single 10X1024
decoder, we use two 5X32 Fig. 5-7 Two-Dimensional Decoding
Structure for a
decoders. 1K-Word Memory
Address multiplexing
DRAMs typically have four times the density of SRAM.
The cost per bit of DRAM storage is three to four times less
than SRAM. Another factor is lower power requirement.
Address multiplexing
Address multiplexing will reduce the number of pins in the
IC package.
P1 = XOR of bits(3,5,7,9,11) = 1 ⊕ 1 ⊕ 0 ⊕ 0 ⊕ 0 = 0
P2 = XOR of bits(3,6,7,10,11) = 1 ⊕ 0 ⊕ 0 ⊕ 1 ⊕ 0 = 0
P4 = XOR of bits(5,6,7,12) = 1 ⊕ 0 ⊕ 0 ⊕ 0 = 1
P8 = XOR of bits(9,10,11,12) = 0 ⊕ 1 ⊕ 0 ⊕ 0 = 1
P8 P4 P2 P1
0 0 0 0 0
1 0 0 0 1
2 0 0 1 0
3 0 0 1 1
4 0 1 0 0
5 0 1 0 1
6 0 1 1 0
7 0 1 1 1
8 1 0 0 0
9 1 0 0 1
10 1 0 1 0
11 1 0 1 1
12 1 1 0 0
13 1 1 0 1
14 1 1 1 0
Hamming Code
The data is stored in memory together with the parity bit as 12-bit
composite word.
Bit position: 1 2 3 4 5 6 7 8 9 10 11 12
0 0 1 1 1 0 0 1 0 1 0 0
When read from memory, the parity is checked over the same
combination of bits including the parity bit.
C1 = XOR of bits(1,3,5,7,9,11)
C2 = XOR of bits(2,3,6,7,10,11)
C4 = XOR of bits(4,5,6,7,12)
C8 = XOR of bits(8,9,10,11,12)
Error-Detection
A 0 check bit designates an even parity over the
checked bits and a 1 designates an odd parity.
Since the bits were stored with even parity, the
result,
C = C8C4C2C1 = 0000, indicates that no error has
occurred.
If C ≠ 0, then the 4-bit binary number formed by
the check bits gives the position of the erroneous
bit.
C1 = XOR of bits(1,3,5,7,9,11)
C2 = XOR of bits(2,3,6,7,10,11)
0 0 1 1 0 0 0 1 0 1 0 0 Error in bit 5
0 0 1 1 1 0 0 1 0 1 1 0 Error in bit 11
Evaluating the XOR of the corresponding bits, get the four check bits
C8 C4 C2 C1
For no error: 0 0 0 0
with error in bit 1: 0 0 0 1
with error in bit 5: 0 1 0 1
with error in bit 11: 1 0 1 1
1 1 1 1 p1 p2 p4
P1 p2 1 p4 111 p8 11111111
Hamming Code
The Hamming Code can be Table 5-2
used for data words of any
length.
Total bit in Hamming Code
is n + k bits, the syndrome
value C consists of k bits
and has a range of 2k value
between 0 and 2k − 1. the
range of k must be equal
to or greater than n + k,
giving the relationship
2k-1 ≥ n + k
Single-Error correction, Double-Error
detection
The Hamming Code can detect and correct only a single
error.
By adding another parity bit to the coded word, the
Hamming Code can be used to correct a single error and
detect double errors. Becomes 001110010100P13.
1 0 1 1 0 0 1 0
X : means connection
Table 5-5
1 elements
0 elements
PLA table by simplifying the function
Both the true and complement
of the functions are simplified in
sum of products.
We can find the same terms
from the group terms of the
functions of F1, F1’,F2 and F2’
which will make the minimum
terms.
F1 = (AB + AC + BC)’
F2 = AB + AC + A’B’C’ Fig. 5-15 Solution to the Example
PLA implementation
Fig. 5.15
5-7. Programmable Array Logic
The PAL is a programmable logic device with a fixed OR array and a
programmable AND array.
Fig. 5-16 PAL with Four Inputs. Four Outputs, and Three-Wide AND-OR Structure
PAL
When designing with a PAL, the Boolean functions
must be simplified to fit into each section.
Unlike the PLA, a product term cannot be shared
among two or more OR gates. Therefore, each
function can be simplified by itself without regard
to common product terms.
The output terminals are sometimes driven by
three-state buffers or inverters.
Example
w(A, B, C, D) = ∑(2, 12, 13)
x(A, B, C, D) = ∑(7, 8, 9, 10, 11, 12, 13, 14, 15)
y(A, B, C, D) = ∑(0, 2, 3, 4, 5, 6, 7, 8, 10, 11, 15)
z(A, B, C, D) = ∑(1, 2, 8, 12, 13)
w = ABC’ + A’B’CD’
x = A + BCD
w = A’B + CD + B’D’
w = ABC’ + A’B’CD’ + AC’D’ + A’B’C’D = w + AC’D’ + A’B’C’D
PAL Table
z has four product terms, and we can replace by w with two
product terms, this will reduce the number of terms for z from
four to three.
Table 5-6
PAL implementation
D
Fuse map for example