Types of Memory

Primary Memory

Primary memory is the memory that is directly accessible to the CPU.There are two types of primary memory:
1. RAM (Random Access Memory)
2. ROM (Read Only Memory)

Difference between RAM and ROM

RAM (Random Access Memory): ROM (Read Only Memory):
1. It is volatile, 1. It is non-volatile,
2. It is temporary storage, 2. It is permanent storage,
3. It is expensive, 3. It is cheap,
4. Allows reading and writing, 4. Allows reading only,
5. Very faster and uses more power. 5. Fast and uses less power.

Difference between PROM, EPROM and EEPROM

The Differences between PROM, EPROM and EEPROM are:

PROM EPROM EEPROM
1. Programmable Read Only Memory. 1. Erasable programmable Read Only Memory. 1. Electronically Erasable Programmable Read Only Memory.
2. Can be modified only once by user (It is not Erasable). 2. Can be erased and reuse. 2. Can be erased electronically.
3. Erasure is not achieved. 3. Erasure is achieved by exposing the chip to ultraviolet light. 3. Erasure is achieved by exposing the chip to electric light.

Cache Memory
Cache memory is a small, high speed memory system that stores copies of the data from the most frequently used main memory locations. It is placed between main memory and CPU. The main advantage of cache memory is that it is faster than main memory and it consume less time to load.

Buffer
A buffer in a computer is a storage space set aside to hold data before it gets processed. Buffers usually use a First In-First Out (FIFO) arrangement where data being buffered comes in one end and data is read in order from oldest to newest. It’s advantage is, it deals with the speed mismatch between I/O and computer system.

Secondary Memory

The secondary memory memory is long term memory which is used to store the data and information for future use. It supplements the limited storage capacity and the volatile characteristics. List of main types of secondary storage devices are:
• Magnetic Tape
• Magnetic Disk
• Optical Disk

Magnetic Tape:
Magnetic tape is a non-volatile storage. It is used for storing large volumes of data that are needed to be sequentially accessed and processed. Magnetic tape is called sequential access media because data of tape can only be accessed in sequential form.

Magnetic Disk:
Magnetic disk is a secondary storage device which provides large storage capabilities. It is a thin, circular plate/platter made of plastic, which is usually coated on both sides with a magnetizable recording material, such as iron oxide. Recorded data are read by read/write heads. Two types of magnetic disks commonly used in microcomputers are:
• Hard Drive
• Floppy Disk

Optical disk:
Optical disk is a rotating disk coated with a thin metal or some other material that is highly reflective. Optical disk works in following ways:
A very fine laser beam is used for recording/reading of data on the disk. The digital data on the optical disk is recorded in the form of microscopic pits and lands. A pit represents a binary 0 and the land represents a binary 1.

Differences between Primary Memory and Secondary Memory

The difference between primary and secondary memory are:

Primary Memory Secondary Memory
1. Primary Memory is temporary. 1. Secondary Memory is permanent.
2. It is directly accessible by processor/CPU. 2. It is not directly accessible by the CPU.
3. Nature of Parts of Primary memory varies, RAM is volatile in nature, ROM is non-volatile in nature. 3. It’s always non-volatile in nature.
4. Primary memory devices are more expensive than secondary memory devices. 4. Secondary memory devices are less expensive when compared to promary memory devices.
5. It is also known as main memory. 5. It is also known as external or auxillary memory.
6. It is faster to read/ write operations. 6. It is slower to read/ write operations.
7. Example of Promary Memory are: RAM, ROM,Cache memory, and Register etc. 7. Example of Secondary Mmeory are: Hard Disk, Floppy Disk, Magnetic Tpaes etc.