What is RAM (Random Access Memory)?
RAM is the biggest piece of memory which exists on the computer hardware or many other Devices. RAM is used to store the programs and data being used by the CPU in real time. The data on the random access memory can be read, written, and erased any number of times.
It is a volatile memory which means the data stored in the RAM evaporates the moment you cut the power supply. That’s one of the reasons we can’t use random access memory as permanent storage despite the fact that it’s way faster than the traditional magnetic disk-based hard drives.
All of the modern operating systems we use have built-in workarounds to handle RAM’s volatile nature. All the work done is constantly saved on the hard drive to avoid situations where unexpected system shutdown would result in data loss.
TYPES OF RAM :
SRAM (Static RAM): It stores a bit of data using the state of a six transistor memory cell. SRAM is way faster than DRAM but costlier. is a type of semiconductor memory that uses bistable latching circuitry (flip-flop) to store each bit. SRAM exhibits data remanence, but it is still volatile in the conventional sense that data is eventually lost when the memory is not powered.
SRAM is also used in personal computers, workstations, routers and peripheral equipment: CPU register files, internal CPU caches and external burst mode SRAM caches, hard diskbuffers, router buffers, etc. LCD screens and printers also normally employ static RAM to hold the image displayed (or to be printed). Static RAM was used for the main memory of some early personal computers such as the ZX80, TRS-80 Model 100 and Commodore VIC-20.
DRAM (Dynamic RAM): It stores a bit data using a pair of transistor and capacitor which constitute a DRAM memory cell. It
stores each bit of data in a separate tiny capacitor within an integrated circuit. The capacitor can either be charged or discharged; these two states are taken to represent the two values of a bit, conventionally called 0 and 1. The electric charge on the capacitors slowly leaks off, so without intervention the data on the chip would soon be lost. To prevent this, DRAM requires an external memory refresh circuit which periodically rewrites the data in the capacitors, restoring them to their original charge. Because of this refresh requirement, it is a dynamic memory as opposed to static random-access memory (SRAM) which does not require data to be refreshed. Unlike flash memory, DRAM is volatile memory (vs. non-volatile memory), since it loses its data quickly when power is removed. However, DRAM does exhibit limited data remanence.
DRAM is widely used in digital electronics where low-cost and high-capacity memory is required. One of the largest applications for DRAM is the main memory (colloquially called the “RAM”) in modern computers and graphics cards (where the “main memory” is called the graphics memory). It is also used in many portable devices and video game consoles. In contrast, SRAM, which is faster and more expensive than DRAM, is typically used where speed is of greater concern than cost, such as the cache memories in processors.
What is ROM (Read Only Memory) ?
Another notable memory type present on the computer is the ROM. As the name suggests, the data on the memory can only be read by the computer. So, what’s the reason these read-only memory chips are in use when we have the RAM chips?
The ROM is a non-volatile memory; it doesn’t forget the data even if the power supply is removed. ROM is used to store firmware for the hardware which hardly gets any update, for instance, the BIOS.
The data on the traditional form of ROM is hardwired to it, i.e., written at the time of manufacturing. Over time, the read-only memory has been developed to support erasing and rewriting of data, although, it can’t achieve the efficiency level of a random access memory chip.
Types Of ROM :
Mask ROM: This is the type of ROM for which the data is written during the manufacturing of the memory chip.
PROM (Programmable Read-only Memory): Programmable read-only memory (PROM) Programmable read-only memory (PROM) is read-only memory ( ROM ) that can be modified once by a user. PROM is a way of allowing a user to tailor a microcode program using a special machine called a PROM programmer . It is non-volatile.
EPROM (Erasable Programmable Read-only Memory): The data on this non-volatile memory chip can be erased by exposing it to high-intensity UV light.
EEPROM (Electrically Erasable Programmable Read-only Memory): The data on this non-volatile memory chip can be electrically erased using field electron emission (Fowler–Nordheim tunneling). Modern EEPROMs are quite efficient in terms of their read-write capabilities.
The types mentioned above were the semiconductor-based ROMs. Optical Storage media like CD-ROM is also a form of read-only memory.
RAM vs. ROM (Difference Between RAM & ROM)
RAM vs. ROM | RAM | ROM |
Data | The data is not permanent and it can be altered any number of times. | The data is permanent. It can be altered but only a limited number of times that too at slow speed. |
Speed | It is a high-speed memory.
Read/Write Speed = 6 GB/s |
It is much slower than the RAM.
R/W Speed about 200 MB/s |
CPU Interaction | The CPU can access the data stored on it. | The CPU can not access the data stored on it. In order to do so, the data is first copied to the RAM. |
Size & Capacity | Large size with less capacity. | Small size with higher capacity. |
Usage | Primary memory (DRAM DIMM modules), CPU Cache (SRAM). | Firmware like BIOS or UEFI. RFID tags, microcontrollers, medical devices, and at places where a small and permanent memory solution is required. |
Cost | It doesn’t come cheap. | Way cheaper than RAM. |
The ROM is cheap and can hold data permanently but it has its limitations. On the other hand, RAM is quite useful than the read-only memory but it can make a burning hole in your pocket.
ROM is not that much incompetent as you might think. The Flash memory we find on removable storage media like Solid State Drives, USB drives, SD cards, etc. is an advanced implementation of the EEPROM type of read-only memory. The derivative provides faster storage solution than traditional hard drives. Still, the number of read/write operations is an issue.
If you have something to add to this article on the difference between RAM and ROM, tell us in the comments below.