Memory Microprocessor System Design EHB432E Lecture -5 n · 2017. 3. 16. · Far more convenient...
Transcript of Memory Microprocessor System Design EHB432E Lecture -5 n · 2017. 3. 16. · Far more convenient...
-
Microprocessor System DesignEHB432ELecture -5
Prof. Dr. Müştak E. Yalçın
Istanbul Technical University
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 1 / 22
Memory
Stores large number of bitsmxn: m words of n bits eachk = log2(m) address input signalsor m = 2k words e.g., 4, 096x8 memory: 32, 768 bits, 12 address inputsignals, 8 input/output data signals
Memory accessr/w: selects read or writeenable: read or write only when assertedmultiport: multiple accesses to di↵erent locations simultaneously
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 2 / 22
Memory
Write ability/ storage permanence
Traditional ROM/RAM distinctionsROM read only, bits stored without powerRAM read and write, lose stored bits without power
Traditional distinctions blurredAdvanced ROMs can be written to e.g., EEPROMAdvanced RAMs can hold bits without power e.g., NVRAM
Write abilityManner and speed a memory can be written
Storage permanenceability of memory to hold stored bits after they are written
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 3 / 22
Memory
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 4 / 22
-
Memory
Ranges of write ability:
High end [processor writes to memory simply and quickly, e.g., RAM]Middle range [processor writes to memory, but slower e.g., FLASH,EEPROM]Lower range [special equipment, ”programmer”, must be used towrite to memory e.g., EPROM, OTP ROM]Low end [bits stored only during fabrication e.g., Mask-programmedROM]
Range of storage permanence
High end [essentially never loses bits e.g., mask-programmed ROM]Middle range [holds bits days, months, or years after memory’s powersource turned o↵ e.g., NVRAM]Lower range [holds bits as long as power supplied to memory e.g.,SRAM]Low end [begins to lose bits almost immediately after written e.g.,DRAM]
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 5 / 22
ROM: ”Read-Only” Memory
Nonvolatile memoryCan be read from but not written to, by a processor in an embeddedsystemTraditionally written to, ”programmed”, before inserting to embeddedsystemUses
Store software program for general-purpose processorStore constant data needed by systemImplement combinational circuit (BLG 231E Digital Circuits)
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 6 / 22
Mask-programmed ROM
Connections ”programmed” at fabrication(mask)
Lowest write ability (once)
Highest storage permanence
OTP ROM: One-time programmable ROM
Connections ”programmed” after manufacture by user
Very low write ability (typically written only once and requires ROMprogrammer device)
Very high storage permanence
Commonly used in final productsAtmel: OTP EPROM
EPROM: Erasable programmable ROM
Programmable component is a MOS transistor
Better write ability (can be erased and reprogrammed thousands of times)
Reduced storage permanence (program lasts about 10 years )
Typically used during design development
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 7 / 22
A datasheet, data sheet, or spec sheet is a document that summarizes theperformance and other technical characteristics of a product, machine,component (e.g., an electronic component), material, a subsystem (e.g., apower supply) or software in su�cient detail to be used by a designengineer to integrate the component into a system. Wikipedia
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 8 / 22
-
Datasheet:27C64
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 9 / 22
EEPROM: Electrically erasable programmable ROM
Programmed and erased electronicallytypically by using higher than normal voltagecan program and erase individual words
Better write abilitycan be in-system programmable with built-in circuit to provide higherthan normal voltagewrites very slow due to erasing and programmingcan be erased and programmed tens of thousands of times
Similar storage permanence to EPROM (about 10 years)
Far more convenient than EPROMs, but more expensiveAtmel EEPROMs
Datasheet:Atmel AT28C010
Datasheet:Atmel 24AA32A
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 10 / 22
Flash Memory
Extension of EEPROMSame gate principle, write ability and storage permanence
Fast eraseLarge blocks of memory erased at once, rather than one word at a timeBlocks typically several thousand bytes large
Writes to single words may be slowerEntire block must be read, word updated, then entire block writtenback
Used with embedded systems storing large data items in nonvolatilememory
Toshiba: NAND Flash Datasheet:Atmel
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 11 / 22
Random-access memory (RAM)
Typically volatile memorybits are not held without power supply
Read and written to easily by embedded system during execution
Internal structure more complex than ROMa word consists of several memory cells, each storing 1 biteach input and output data line connects to each cell in its columnrd/wr connected to every cellwhen row is enabled by decoder, each cell has logic that stores inputdata bit when rd/wr indicates write or outputs stored bit when rd/wrindicates read
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 12 / 22
-
SRAM: Static RAMMemory cell uses flip-flop to store bitRequires 6 transistorsHolds data as long as power supplied
DRAM: Dynamic RAMMemory cell uses MOS transistor andcapacitor to store bitMore compact than SRAM”Refresh” required due to capacitor leakdynamic memory cells must be repeatedly readand restored, this process is called memoryrefresh.Typical refresh rate 15.625 microsec.Slower to access than SRAM
YouTube :RAMs YouTube:SRAM YouTube:DRAM
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 13 / 22
HM6264 Datasheet
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 14 / 22
DRAM Architecture
Address bus multiplexed between row and column components
Row and column addresses are latched in, sequentially, by strobingras and cas signals, respectivelyRefresh circuitry can be external or internal to DRAM device
strobes consecutive memory address periodically causing memorycontent to be refreshedrefresh circuitry disabled during read or write operation
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 15 / 22 Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 16 / 22
-
YouTube: Raed YouTube: Refresh YouTube: Write
KM41464 Samsung, Datasheet
256 rows and 256 cols., 256 rows refresh in 4ms therefore 15µs per row!Refresh cycle shown needs an external DRAM controller to step through the rows and supply refresh signals atappropriate times
More modern method is ”CAS before RAS” refresh (memory uses the otherwise unused CAS before RAS input toinitiate a refresh cycle) which is associated with an internal refresh address counter. DRAM controller only choosesrefresh times.
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 17 / 22
DRAMs commonly used as main memory in processor basedembedded systems (high capacity, low cost)
Many variations of DRAMs proposedFPM DRAM: fast page mode DRAM
EDO DRAM: extended data out DRAMSDRAM/ESDRAM: synchronous and enhanced synchronous DRAM
SDRAM latches data on active edge of clockEliminates time to detect ras/cas and rd/wr signalsA counter is initialized to column address then incremented on activeedge of clock to access consecutive memory locations
MT48LC32M8A2 Micro, Datasheet
Prof. Dr. Müştak E. Yalçın (İTÜ) MSD January, 2016 18 / 22