RAM 2522 DK
RAM 2522 DK
RAM 2522 DK
1
Memory
2
Picture of Memory
Address Data
00000000
00000001
• You can think of memory as being one big array
00000002
of data.
.
– The address serves as an array index.
.
– Each address refers to one word of data. .
• You can read or modify the data at any given .
memory address, just like you can read or .
modify the contents of an array at any given .
index. .
.
.
.
FFFFFFFD
FFFFFFFE
FFFFFFFF
Word 3
Memory Signal Types
4
Memory Address, Location and Size
5
Size matters!
6
Read-only memory (ROM)
2k x n ROM • Non-volatile
– If un-powered, its content
k retains
ADRS Data n
Out • Read-only
CS
– normal operation cannot change
OE contents
7
ROM Programming
8
ROM Usage
9
ROM Structure
10
32Kx8 ROM
11
Typical commercial EEPROMs
12
Microprocessor EPROM application
13
ROM Timing
14
Memories and functions
15
Logic-in-ROM Example
16
PROM/Register Sequential Circuit
1024 x 8 PROM
Need to construct FSM with:
15 states ‘1’ PROG
6 inputs CS
4 outputs A9
OUTPUTS
A8
A7 O7
We need at least 4 FFs to INPUTS
A6 O6
store the 15 states A5 O5
A4 O4
# combinational logic inputs A3 O3
(i.e. PROM address signals) A2 O2
is 6 + 4 = 10; therefore the A1 O1
PROM must have a minimum A0 O0
of 210 or 1024 locations
17
Introduction to RAM
18
Block diagram of RAM
2k x n memory
k ADDRESS DATA n
IN/OUT
RD/WR’
CS
19
Reading RAM
2k x n memory
k ADDRESS DATA n
IN/OUT
RD/WR’
CS
20
Reading RAM
21
Writing RAM
2k x n memory
k ADDRESS DATA n
IN/OUT
RD/WR’
CS
22
Writing RAM
23
Static memory
• Static memory is modeled using one latch for each bit of storage.
24
RAM Cell with SR Latch
25
RAM Bit Slice Model
26
16-Word by 1-bit RAM Chip
27
16x1 RAM Using a 4x4 RAM Cell Array
28
8x2 RAM Using a 4x4 RAM Cell Array
29
SRAM Devices
30
Typical memory sizes
Address Data
• Some typical memory capacities: 00000000
– PCs usually come with 128-256MB RAM. 00000001
– PDAs have 8-64MB of memory. 00000002
– Digital cameras and MP3 players can have .
32MB or more of storage. .
.
• Many operating systems implement virtual
.
memory, which makes the memory seem larger
than it really is. .
– Most systems allow up to 32-bit addresses. .
This works out to 232, or about four billion, .
different possible addresses. .
– With a data size of one byte, the result is .
apparently a 4GB memory! .
– The operating system uses hard disk space FFFFFFFD
as a substitute for ―real‖ memory.
FFFFFFFE
FFFFFFFF
31
RAM Summary
32
Dynamic memory
33
DRAM Cell
34
DRAM Cell Read
35
DRAM Cell Write
36
DRAM Bit Slice
37
DRAM Including Refresh Logic
38
Dynamic vs. static memory
• Real systems augment dynamic memory with small but fast sections of
static memory called caches.
– Typical processor caches range in size from 128KB to 320KB.
– That’s small compared to a 128MB main memory, but it’s enough to
significantly increase a computer’s overall speed.
39
ROMs vs. RAMs
• Some newer types of ROMs do allow for easier writing, although the
speeds still don’t compare with regular RAMs.
– MP3 players, digital cameras and other toys use CompactFlash,
Secure Digital, or MemoryStick cards for non-volatile storage.
– Many devices allow you to upgrade programs stored in ―flash ROM.‖
40