Chapter 9
Memory
Objectives • At the end of this chapter, students should be able to:– Discuss the basic organization of a memory (RAM). – Describe the read and write operation. – Explain how to expand the memory capacity of a memory.
2
Memory Components • Five memory components are: Input Data
Output Data I2 I1 I0
Read/Write ME
O2 O1 O0
A1 A0
Address
• Memory components are manufactured in sizes
2n x m n = number of address lines m = word size/number of input and output lines 3
Memory Components
Remember, Address line (in bits)
n
2 xm
Word size / Input line/ Output line (in bits)
Memory capacity (in bits or bytes) / memory cell 1 byte = 8 bits
4
Example Given an 8 x 4 bit memory IC. a) Draw the memory diagram. Data Input Lines
Read/Write Lines
4
4 Data Output Lines
8x4 bit
Memory Enable Lines 3 Address Lines
b) Identify the number of address lines. For 8 x 4 bit, 2n x m = 23 x 4 Therefore, the number of address lines = 3 bits
5
Example c) Determine the number of data input /output lines. Number of data input /output lines = Word size = 4 bits d) Calculate the memory capacity in bits/bytes. Memory capacity in bits = 8 x 4 bits = 32 bits Memory capacity in bytes = 8 x 4 bits = 4 bytes 8 e) Calculate the number of memory cells. Number of memory cells = 8 x 4 bits = 32 cells
6
Example f) Identify the number of IC(s) needed to expand the memory capacity to 16 x 4bit. Number of ICs = 16 = 2 ICs 8 g) Name the decoder used to expand the memory capacity to 16 x 4bit. Type of decoder = 1:2 decoder (based on no.of ICs) h) Draw the expanded memory diagram. (Refer to the next slide for the diagram) 7
Expanded Memory Diagram Data Input Lines
R/W Lines
Data Output Lines
8x4bit 0
4
4 8x4bit 1 0
1
1:2 decoder A
3 Address Lines
8