|
Previous Page Index Next Page
MEMORY
Memory is an important part of embedded systems. The cost and performance of an embedded system heavily depends on the kind of memory devices it utilizes. In this section we will discuss about “Memory Classification”, “Memory Technologies” and “Memory Management”.
(1) Memory Classification
Memory Devices can be classified based on following characteristics
(a) Accessibility
(b) Persitance of Storage
(c) Storage Density & Cost
(d) Storage Media
(f) Power Consumption
Accessibility
Memory devices can provide Random Access, Serial Access or Block Access. In a Random Access memory, each word in memory can be directly accessed by specifying the address of this memory word. RAM, SDRAMs, and NOR Flash are examples of Random Access Memories. In a Serial Access Memory, all the previous words (previous to the word being accessed) need to be accessed, before accessing a desired word. I2C PROM and SPI PROM are examples of Serial Access Memories. In Block Access Memories, entire memory is sub-divided in to small blocks (generally of the order of a KByte) of memory. Each block can be randomly accessed, and each word in a given block can be serially accessed. Hard Disks and NAND flash employ a similar mechanism. Word access time for a “RAM” (Random Access Memory) is independent of the word location. This is desirable of high speed application making frequent access to the memory.
Persistence of Storage
Memory devices can provide Volatile storage or a non-Volatile stroage. In a non-Volatile storage, the memory contents are preserved even after power shut down. Whereas a Volatile memory looses its contents, after power shut down. Non-Volatile storage is needed for storing application code, and re-usable data. However volatile memory can be used for all temporary storages. RAM, SDRAM are examples of volatile memory. Hard Disks, Flash (NOR & NAND) Memories, SD-MMC, and ROM are example of non-Volatile storages.
Storage Cells
Memory Device may employ electronic (in terms of transistors or electron states) storage, magnetic storage or optical storage. RAM, SDRAM are examples of electronic storage. Hard Disks are example of magnetic storage. CDs (Compact Discs) are example of optical storage. Old Computers also employed magnetic storage (magnetic storages are still common in some consumer electronics products).
Storage Density & Cost
Storage Density (number of bits which can be stored per unit area) is generally a good meausre of cost. Dense memories (like SDRAM) are much cheaper than their counterparts (like SRAM).
Power Consumption
Low Power Consumption is highly desirable in Battery Powered Embedded Systems. Such systems generally employ memory devices which can operate at low (and ultra low) Voltage levels. Mobile SDRAMs are example of low power memories.
(2) Memory Technologies
RAM
RAM stands for Random Access Memory. RAMs are simplest and most common form of data storage. RAMs are volatile. The figure below shows typical Data, Address and Control Signals on a RAM. The number of words which can be stored in a RAM are proportional (exponential of two) to the number of address buses available. This severely restricts the storage capacity of RAMs (A 32 GB RAM will require 36 Address lines) because designing circuit boards with more signal lines directly adds to the complexity and cost.
DPRAM (Dual Port RAM)
DPRAM are static RAMs with two I/O ports. These two ports access the same memory locations - hence DPRAMs are generally used to implement Shared Memories in Dual Processor Systems. The operations performed on a single port are identical to any RAM. There are some common problems associated with usage of DPRAM:
(a) Possible of data corruption when both ports are trying to access the same memory location - Most DPRAM devices provide interlocked memory accesses to avoid this problem.
(b) Data Coherency when Cache scheme is being used by the processor accessing DPRAM - This happens because any data modifications (in the DPRAM) by one processor are unknown to the Cache controller of other processor. In order to avoid such issues, Shared memories are not mapped to the Cacheable space. In case processor's cache configuration is not flexible enough (to define the shared memory space as non-cacheable), the cache needs to be flushed before performing any reads from this memory space.
Dynamic RAM
Dynamic RAMs use a different storage technique for data storage. A Static RAM has four transistors per memory cell, whereas Dynamic RAMs have only one transistor per memory cell. The DRAMs use capactive storage. Since the capacitor can loose charge, these memories need to be refreshed periodically. This makes DRAMs more complex (because we need to have extra control) and power consuming. However, DRAMs have a very high storage density (as compared to static RAMs) and are much cheaper in cost. DRAMs are generally accessed in terms of rows, columns and pages which significantly reduces the number of address buses (another advantage over RAM). Generally you need a SDRAM controller (which manages different SDRAM commands and Address translation) to access a SDRAM. Most of the modern processors come with an on-chip SDRAM controller.
OTP- EPROM, UV-EPROM and EEPROM
EPROMs (Electrically Programmable writable Read Only Memory) are non-volatile memories. Contents of ROM can be randomly accessed - but generally the word RAM is used to refer to only the volatile random access memories. The operating voltage for writing in to the EPROMs is much higher than the operating voltage. Hence you can write in to a PROM in-circuit (which signifies ROM). You need special programming stations (which have write mechanism) to write in to the EPROMs.
OTP-EPROMs are One Time Programmable. Contents of these memories can not be changed, once written. UV-EPROM are UV erasable EPROMs. Exposure of memory cells, to UV light erases the exisiting contents of these memories and these can be re-programmed after that. EEPROM are Eletricaly Erasable EPROMs. These can be erased electrically (generally on the same programming station where you write in to them). The write cycles (number of times you can erase and re-write) for UV-EPROM and EEPROM is fairly limited. Erasable PROMs use either FLOTOX (Floating gate Tunnel Oxide) or FAMOS (Floating gate Avalanche MOS) technology.
Flash (NOR)
Flash (or NOR-Flash to be more accurate) are quite similar to EEPROM in usage and can be considered in the class of EEPROM (since it is electically erasable). However there are a few differences. Firstly, the flash devices are in-circuit programmable. Secondly, these are much cheaper as compared to the conventional EEPROMs. These days (NOR) Flash are widely used for storing the boot code.
NAND FLASH
These memories are more dense and cheaper than NOR Flash. However these memories are block accessible, and can not be used for code execution. These devices are mostly used for Data Storage (since it is cheaper than NOR flash). However some systems use them for storing the boot codes (these can be used with external hardware or with built-in NAND boot logic in the processor).
SD-MMC
SD-MMC cards provide a cheaper mean of mass storage. These memory cards can provide storage capacity of the order of GBytes. These cards are very compact and can be used with portable systems. Most modern hand-held devices requiring mass storage (e.g. still and video cameras) use Memory cards for storage.
Hard Disc
Hard Discs are Optical Memory devices. These devices are bulky and they require another bulky hardware (disk reader) for reading these memories. These memories are generally used for Mass storage. Hence they memories do not exist in smaller and portable systems. However these memories are being used in embedded systems which require bulk storage without any size constraint.
Previous Page Index Next Page
|