Memory 1 Technician Series ©Paul Godin Created March 2008 Edit Jan 2014.
-
Upload
ursula-woods -
Category
Documents
-
view
218 -
download
5
Transcript of Memory 1 Technician Series ©Paul Godin Created March 2008 Edit Jan 2014.
Memory 1Technician Series
©Paul GodinCreated March 2008
Edit Jan 2014
Memory
◊ Digital systems often require the ability to retain and access binary values. Programmable devices and devices that access programs require memory systems to store values for, and after, processing.
◊ Memory systems are comprised of D Flip-Flop or D Latch configurations that are addressed with a decoder.
◊ This presentation addresses basic concepts associated with memory devices.
Memory1.2
Memory Devices
Memory
Read Only Random Access
Storage
Masked ROM
PROM
EPROM
EEPROM
CD-ROMDrives
Flash
SRAM
DRAM
DIMM
SIMM
SDRAM
Memory1.3
Memory
◊ Memory comes in 2 general varieties:
◊ RAM (Random Access Memory)◊ Often considered “volatile” because the data is lost when the
system is turned off.◊ RAM is used by systems to store values that are intended to
change regularly.◊ RAM is fast.
◊ ROM (Read Only Memory)◊ Considered permanent or semi-permanent memory and “non-
volatile” because data is not lost when the system is turned off.◊ ROM is used by systems to store values that are not intended to
change or that change only rarely.◊ ROM is slow for writing operations.
Memory1.4
READ ONLY MEMORY
Memory1.5
ROM Varieties – MP-ROM
◊ Mask-Programmed ROM (MP-ROM): ◊ A mask programmed ROM has had the values of the data
bits built into the device on manufacturing it and is therefore very application-specific.
◊ Have very high initial set up costs for manufacturing. Selected only when a large production run is required.
◊ These devices cannot be re-programmed.◊ Examples of Mask-Programmed ROM include game
cartridges and operating systems for smart cards.
◊ Today the availability, variety and lower costs of other ROM types means the use of MP-ROM is somewhat rare.
Memory1.6
ROM Varieties - PROM
◊ Programmable Read-Only Memory (PROM):◊ Memory devices that contain fusible links that can be
custom programmed one-time (OTP). During the programming process the undesired links are burned open.
◊ Once programmed, PROMs are much less susceptible to data loss than most other ROM devices.
◊ PROMs are inexpensive and come in a variety of shapes and sizes based on the application desired.
◊ Examples of PROMs include operating systems for automotive computers and other portable devices. Proms are also used in space vehicles due to their ruggedness.
Memory1.7
ROM Varieties - EPROM
◊ Erasable Programmable ROM (EPROM)◊ Devices that can be custom programmed by the user. ◊ Once programmed, the data is non-volatile. ◊ EPROMs can be erased by exposing the circuit to UV light
through a small glass window (typically about 20 minutes). Window should be covered with a sticker.
◊ Can be re-programmed as often as desired. ◊ EPROMs are more expensive than most other ROM
devices (except MP-ROM) and have one of the lowest densities. They are much less popular today than the past.
Memory1.8
ROM Varieties - EEPROM
◊ Electrically Erasable ROM (EEPROM)◊ Provide the user with the ability to custom program ROM
with the option of erasing the data electrically. ◊ Some EEPROMS can be selectively erased, where only
portions of the memory may be cleared and re-written. ◊ More expensive and has lower density than other ROM
devices.◊ Very popular for many applications. Permits user to
update code without physically handling the device. Used in many computer-based applications.
Memory1.9
ROM Varieties - Flash
◊ FLASH◊ Flash memory incorporates the advantages of erasable
non-volatile memory with a fast erase capability.◊ Permits selective write capability where specific
addresses may be re-written.◊ Flash ROM is very popular due to its relatively high
speed, ease of use, portability and cost reductions. Used extensively in portable digital electronic applications.
Memory1.10
Flash memory: K9GAG08U0M on a badly soldered boardhttp://www.flash-extractor.com/
RANDOM ACCESS MEMORY
Memory1.11
RAM (Random Access Memory)
◊ Referred to as “Read/Write Memory”, this memory is utilized for temporary storage. This is a volatile memory, meaning the data is present as long as power is applied to the IC.
Memory1.12
RAM Varieties – SRAM
◊ SRAM◊ Static RAM basically consists of flip-flop memory devices.
These individual flip-flops will retain data as long as power is maintained to the device.
◊ Very fast and is often used in applications where speed is of primary concern.
◊ The primary disadvantage is the amount of continuous power it requires and the amount of heat it generates.
◊ Typically used for microprocessor registers and cache.
Memory1.13
RAM Varieties - DRAM
◊ DRAM◊ Dynamic RAM utilized capacitive charges to maintain
binary values. ◊ has a lower power consumption than SRAM. ◊ requires frequent recharging of the capacitors otherwise
the data will be lost. ◊ Slower than SRAM but continues to improve.◊ DRAM is static sensitive.
Memory1.14
RAM Structure
◊ DIMM, SIMM, DDR, SDRAM◊ Memory modules may take on various physical forms to
make them easier to handle. ◊ Single In-line Memory Module (SIMM) has a set on
contacts on one side of the board only and 32 bit access.◊ Dual In-line Memory Module has contacts on both sides of
the board and are designed for 64 bit access.◊ Double Data Rate is memory that performs an operation
on both the rising and the falling edge of the clock.◊ SDRAM, EDO, FPM and others offer various options of
handling data while maintaining the highest rates of speed.
Memory1.15
STORAGE
◊ Various storage devices are used for maintaining large amounts of information and are in a different category than Memory. These storage systems include:
◊ CD and DVD-ROMs◊ hard drives◊ floppy drives◊ tape storage ◊ other systems
◊ Storage devices are considered I/O (Input/Output) devices.
Memory1.16
MEMORY – BASIC CONCEPTS
Memory1.17
Basic Terminology
◊ Bit◊ A single binary digit (1 or 0) ◊ abbreviated with a small b◊ Communication-based systems use bits as the standard
unit of measure. i.e. USB 2.0 transfer rate is 480 Mbps (Megabits per second), and basic Ethernet is 10 Mbps.
◊ Byte◊ 8 bits ◊ Abbreviated with a capital B◊ Computer-based devices such as memory, hard drives,
ROM drives, flash drives and other similar devices have capacity rated in Bytes. i.e. a 100 GB drive has a stated capacity of 100 Billion Bytes, equal to 800 Billion bits.
Memory1.18
Memory Terminology
◊ Cell: the element that can store a single bit of data.
◊ Word: the number of bits that represent an instruction or data. Usually determined by the data bus width.
◊ Capacity: the total number of bits or bytes a memory device can store.
◊ Density: a ratio, describes the physical space occupied by memory.
Memory1.19
Memory Capacity
◊ Memory devices store bits of data from the data bus, therefore these bits are arranged with the same width as the data bus.
◊ An 8 bit bus has an 8 bit word.
D7 D6 D5 D4 D3 D2 D1 D0
This is a single 8-bit word
Memory1.20
Memory Capacity
◊ In turn, we can access each byte of information stored in a memory device by an individual address.
D7 D6 D5 D4 D3 D2 D1 D0
D7 D6 D5 D4 D3 D2 D1 D0
00
01
10
11
D7 D6 D5 D4 D3 D2 D1 D0
D7 D6 D5 D4 D3 D2 D1 D0
Ad
dre
ss
Memory1.21
Memory Capacity
D7 D6 D5 D4 D3 D2 D1 D0
D7 D6 D5 D4 D3 D2 D1 D0
00
01
10
11
D7 D6 D5 D4 D3 D2 D1 D0
D7 D6 D5 D4 D3 D2 D1 D0
Ad
dre
ss
This example has a 2-bit address (22)There are 4 storage locations for 8 bit wordsTotal capacity is 32 bitsThis memory unit is a “4 x 8” (4 x 8-bit words)
Memory1.22
◊ With more address bits comes increased capacity.
Memory Capacity
D7 D6 D5 D4 D3 D2 D1 D0
D7 D6 D5 D4 D3 D2 D1 D0
0000
0001
1110
1111 D7 D6 D5 D4 D3 D2 D1 D0
D7 D6 D5 D4 D3 D2 D1 D0
Ad
dre
ss
How many storage locations are there?
Memory1.23
Memory Notation
◊ Standard notation for memory is:# addressable locations x word size
◊ The number of addressable locations is somewhat “rounded”. It follows a pattern that is familiar to us:◊ 1, 2, 4, 8, 16, 32, 64, 128, 256, 512◊ Example: 128k is actually 131,072 addresses (217)
“32k x 8” means 32k of addresses (rounded) for 8 bit words
Memory1.24
Review Questions
Complete the following table.
4k x 8 64k x 16 256k x 4 512 x 32
Capacity (words)
Word Size
# address lines
# data lines
Memory1.25
Tri-State Devices
Logic States
What is the logic state at point A?
1 0
A
What is the logic state of just a piece of wire?
A 3rd Logic State?
◊ Digital logic has 2 logic states:◊ ‘0’, or low, representing ground, or zero volts◊ ‘1’, or high, representing Vcc, or full operational voltage
◊ Digital logic has 2 dynamic states:◊ ‘0’ to ‘1’ transition◊ ‘1’ to ‘0’ transition
◊ In some cases, connection to a common conductor, such as a BUS, is required. In these cases, we cannot connect two or more standard outputs together. The results will be short circuits, half voltages and unpredictable outcomes.
Tri-States
◊ A Tri-State buffer (or a 3-state buffer) utilizes a second input to electrically disconnect the output.
◊ The third state is called “high impedance”, or simply “Z”. ◊ The control input is often labeled “OE”, or Output Enable.
A OE Y Status
0 1 0Enabled (A to Y)
1 1 1
X 0 Z Disabled (high Z)
A
OE
Y
Elec 1.29
IEEE/ANSI Symbol for Tri-State
Tri-State Bus
In this example, several device outputs share the common bus. The control system is
designed to allow only 1 device to be connected to the bus; all
other devices are tri-stated.
Elec 1.30
Using Tri-State Devices
◊ “Tri-stated” is the term used to describe an output from a tri-state device that is in the high impedance state.
◊ Tri-states should be used cautiously…never allow a gate input to float. Pull-up resistors are frequently used with tristated buses.
A
OE
B X
Elec 1.31
USING MEMORY
Memory 2.32
Memory
Memory 2.33
Memory in a P System
◊ Memory is an integral part of microcomputers.
◊ Memory quickly provides the data and instructions the microprocessor needs to process.
◊ Memory provides an area where the microprocessor can quickly store processed data.
◊ Memory IC’s come in a variety of configurations and are selected based on the microprocessor and the bus structures.
Memory 2.34
Basic Requirements
◊ A microprocessor needs the ability to:◊ Select the memory device◊ Provide the address◊ Decide to read from it, or write to it◊ Ensure it is ready to send or receive the data
◊ Memory device circuits need:◊ Tri-state outputs because they are connected to a common bus◊ A decoder to select the appropriate word location◊ Direction control◊ Bus connections to receive or send data◊ An enabling input
Memory 2.35
Basic Elements
Memory Device
Data/Instructions
Address Select
Read/Write
Memory 2.36
Interconnection
CPU
MemoryA
dd
ress
Data
Sele
ctR
/W’
Memory 2.37
The 2114 Memory Chip
◊ The 2114 chip is an old device but it serves as a good example of a basic memory device
◊ Basic Characteristics:◊ Static RAM◊ Non-inverting◊ Common input and output pins◊ TTL compatible
Memory 2.38
RAM Requirements
◊ An input to control direction: a READ or a WRITE operation.
◊ An input to select the device.◊ Address input◊ Data input/output
A6 VccA5 A7A4 A8A3 A9A0 D0A1 D1A2 D2CS D3Gnd WE
21
14
Memory 2.39
Read/Write
◊ A RAM chip has a read/write selection:◊ If written as :
◊ A logic low will Enable Writing to the device◊ A logic high will Enable Reading from the device
◊ Write = Input to the memory device◊ Read = Output from the memory device
WE
Memory 2.40
Chip Select
◊ A RAM chip has a Chip Select:◊ If written as :
◊ A low will enable the output and enable the input◊ A high will tristate the output and disable the input
◊ CS is used to avoid bus contention problems.
CS
Memory 2.41
RAM Chip Questions
1. What is the word size?2. How many addressable locations are there?3. What is the capacity?4. What connections and input logic is required to
read from the device?5. What are the origins of the signals?
A6
Vcc
A5
A7
A4
A8
A3
A9
A0
D0
A1
D1
A2
D2
CS
D3
Gn
dW
E
2114
Memory 2.42
Function Table
CS’ WE’ D Mode
H X Hi-Z Disabled
L L H Write H
L L L Write L
L H Dout Read
A6 VccA5 A7A4 A8A3 A9A0 D0A1 D1A2 D2CS D3Gnd WE
21
14
Memory 2.43
Using 2 Memory IC’s
◊ The 2114 is a 210 4, or 1024 4 bit memory device. Each IC has a 4-bit word size; two ICs can be combined to create an 8 bit word.
Memory 2.44
Control and Timing
Memory Device
Data/Instructions
Address Select
Read/Write
Memory 2.45
Specifications
◊ Electrical:◊ Most electrical specifications resemble the TTL-LS
specifications.◊ 4.75 to 5.25 V for Vcc◊ VOH = 2.4V◊ VOL = 0.4V
◊ Exceeds TTL-LS specification for power:◊ ICC = 95 mA at room temperature
Memory 2.46
DRAM
◊ DRAM is used an memory in computer systems whereas SRAM is used internally by the microprocessor (cache).
◊ Dynamic RAM is inexpensive with greater density and much lower power consumption but is one of the slowest types of memory.
◊ The DRAM stores its values as a capacitive charge on tiny MOS capacitors and therefore requires continual refresh to maintain its values. This is a challenge for designing with DRAM.
◊ Computer systems may have separate circuitry to refresh the DRAM without using CPU cycles.
Memory 2.47
DRAM
◊ DRAM addressing is somewhat more complex. Each bit is accessed instead of each word as in SRAM. This increases the number of addresses and therefore the number of addresses.
◊ Addressing is done in a matrix configuration with the address split between Rows and Columns. Input pins RAS (Row Address Strobe) and CAS (Column Address Strobe) control the input address.
Memory 2.48
DRAM
◊ Representation of DRAM (4x4)
Memory 2.49
WIKI CC
DRAM
◊ A multiplexer is often used to reduce the number of address lines required.
◊ Refreshing DRAM is done in 2 manners:◊ Burst mode, where all values of a Row are enabled at
once, and access to memory is suspended for this time.◊ Distributed mode, where the refresh is done with
memory access functions. This is more complex to manage.
Memory 2.50
Review
◊ DRAM has advantages over SRAM:◊ Low power◊ High density
◊ DRAM has some disadvantages over SRAM:◊ More difficult to configure◊ Requires refresh cycles
◊ DRAM is popular with microcomputers
Memory 2.51
©Paul R. Godinprgodin°@ gmail.com
END
Memory1.52