Memory and Programmable Logic

Download as pdf or txt
Download as pdf or txt
You are on page 1of 8

Memory and Programmable Logic

Memory Device:
Device to which binary information is transferred for storage,
and from which information is available for processing as needed.

Memory Unit:
is a collection of cells capable of storing a large quantity of binary
information.

In digital systems, there are two types of memories:

1. RAM
2. ROM

Memory and Programmable Logic


1. Random-Access Memory (RAM)
RAM is the place in a computer where the operating system , application
programs, and data in current use are kept so that they can be quickly reached
by the computer's processor.

2. Read-Only Memory (ROM):


ROM is a type of memory that is as fast as RAM, but has two important
differences: It can not be changed, and it retains its contents even when the
computer is shut off. It is generally used to start your computer up and load the
operating system.

1
Random-Access Memory
Memory unit:
Stores binary information in groups of bits called words.

Memory word:
group of 1’s and 0’s and may represent a number,
character(s), instruction, or other binary-coded information.

Most computer memories use words that are multiples of 8 bits (byte ).
32-bit word à 4 bytes

Random-Access Memory
Each word in memory is assigned an address 0 up to 2k – 1 (k = # of
address lines).

memory content

How many bytes is this memory module? 2KB

2
RAM: Write and Read Operations

To transfer a new word to be stored into memory:

1. Apply the binary address of the word to address lines.


2. Apply the data bits that must be stored in memory to the data
input lines.
3. Activate the write input.

To transfer a stored word out of memory:

1. Apply the binary address of the word to address lines.


2. Activate the read input.

Memory Types
Integrated circuit RAM units are available in two possible operating modes:
static and dynamic.

Static RAM (SRAM) consists of of internal latches that store the binary
information. The stored information remains valid as long as power is
applied to the unit.

Dynamic RAM (DRAM) stores the binary information in the form of


electric charges on capacitors provided by the MOS transistors.
The charge on the capacitors tends to decay with time and the capacitors
must be periodically recharged by refreshing of the dynamic memory every
few milliseconds.

• DRAM offers reduced power consumption, large integration of units on


chip.
• SRAM is faster; has shorter read and write cycles, SRAM is used in cache.
Disadvantages: high power consumption, low density, expensive.

3
Memory Hierarchy

physical size of memory decreases

memory access time increases

Volatile vs. Non-Volatile Memory

§ RAM (static and dynamic) is said to be volatile, since


information is lost when power is turned off.

§ Non-volatile memory retains its information even when


power is turned off.

1. Magnetic disks: stored data is represented by the direction of


magnetization.
2. CD: compact disc is a piece of polycarbonate (a type of
plastic) on which a spiral track has been impressed. This
spiral track is a series of indentations ("pits") separated by
flat areas ("land").
3. ROM: The internal storage elements are set to their values
once and after that are only read.

4
RAM Memory Cell

The storage part of the cell is modeled by an SR latch with


associated gates.

A 1 in the read/write input provides the read operation by forming a


path from the latch to the output.
A 0 in the read/write input provides the write operation by forming a
path from the input to latch.

4 x 4 RAM

WRITE operation: the data available in the input lines are transferred
into the four binary cells of the selected word. The memory cells that are
not selected are disabled.
READ Operation: the four bits of the selected word go through OR
gates to the output terminals.

6
Commercial RAM

Commercial RAM à thousands of words, with each word 1 - 64 bits.


A memory with 2k words of n bits/word requires k address lines that go
into a k x 2k decoder.

Two Dimensional Decoding

404

The idea of two-dimensional decoding is to arrange the memory cells in an


array that is as close as possible to square. Use two k/2-input decoders
instead of one k-input decoder. One decoder performs the row selection and
the other the column selection in a two dimensional matrix configuration.
How many words can be selected?

7
Constructing 256K X 8 RAM (similar to 7-8)
1. How many 64K x 8 RAM chips are needed to
provide a memory capacity of 256KB?
2. How many lines of the address must be used to
access 256K bytes? How many of these lines are
connected to the address inputs of all chips?
3. How many lines must be decoded for the chip
select inputs of all chips?

64K X 8 RAM chip


Capacity: 64K words of 8 bits each

How many chips are needed to construct 256K x 8?


What is the size of the decoder?

10
256K X 8 RAM
- Three-state outputs are connected
together to form 8 data output lines.

- Just one chip select (CS) will


be active at any time.

- RAM requires 18-bit address:


16 LSB address are applied to
the inputs of each RAM.
2 MSB are applied to 2-to-4 decoder.

- Address bits 16 and 17 are used for


chip selection.

32 X 8 ROM chip

11

You might also like