Computer memory is used to store two things:
- Instruction to execute a program.
- Data the computer can follow instantly of instruction.
As programs or the set of instructions is kept in primary memory. In short memory unit stores:
- Data and instructions received from input devices.
- Intermediate result of processing.
- result for output, before they are released to an output device.
There are two kinds of computer memory: primary and secondary.
![](https://i0.wp.com/htolock.com/wp-content/uploads/2024/05/computer-memory.jpg?resize=640%2C427&ssl=1)
Primary Memory / Internal:
The primary memory of a computer is also known as its main memory. It is used to hold pieces of program instructions and data, the intermediate result of processing, and preserve, and an intermediate result of ongoing programs,
Random Access Memory(RAM):
The primary storage is referred to as Random Access Memory(RAM) because it is possible to randomly select and use any location of the memory to directly store and retrieve data. It takes some time to reach any address of the memory as the first address. It is also called read/write memory. The storage of data and instructions inside the primary storage is temporary. As soon as the computer is switched off the contents of the primary memory are lost. The memories, that lose their content because of the failure of the power supply, are known as volatile memories. It can be classified into two types.
- DRAM: Dynamic random access memory(DRAM) is a type of random access memory that stores each bit of data in a separate capacitor within an integrated circuit. Since the real capacitor leaks charge, the information eventually fades unless the capacitor charge is refreshed periodically.
- SRAM: Static random access memory (SRAM) is a type of semiconductor memory where the word static indicates that, unlike dynamic RAM(DRAM), it does not need to be periodically refreshed.
Read-Only Memory(ROM):
Read-only memory(Usually known by its acronym, ROM) is a class of storage media used in the computer and other electronic devices. As because data stored in ROM cannot be modified(at least not very quickly or easily), it is mainly used to distribute firmware. They are categorized into three types.
- PROM: This is a form of digital memory where the setting of each bit( explained later) is locked by a fuse or anti-fuse. Such PROMs are used to store programs permanently.
- EPROM: It is a type of memory chip that retains its data when its power supply is switched off. In other words, it is non-volatile. It is an array of floating-gate transistors individually programmed by an electronic device that supplies higher voltages than those normally used in digital circuits. Once programmed, an EPROM can be erased only by exposing it to strong ultraviolet light.\
- EEPROM: Which stands for electrically erasable programmable Read-Only Memory, is a type of non-volatile memory used in computers and other electronic devices to store small amounts of data that must be saved when power is removed.
Cache Memory(CM):
The Cache is a temporary storage area where frequently accessed data can be stored for rapid access. Once the data is stored in the cache, future use can be make by accessing the cached copy rather than re-computing the original data, so that the average access time is shorter.
Registers:
The Register is a temporary memory inside a CPU is used to storing information, whose contents can be accessed more quickly than storage available elsewhere.
Secondary Memory:
It is often necessary to store many millions of bytes of data in a computer. But, the storage capacity of primary storage is less as well as volatile. As a result, additional memory called secondary storage is used with most computer system. It is not directly accessible by the CPU. The computer usually uses its input / output channels to access secondary storage and transfers the desired data using intermediate area in primary storage. Secondary storage does not lose the data when the device is powered down , so it is non-volatile. Consequently, modern computer systems typically have an order of magnitude more secondary storage than primary storage and data is kept for a longer time there. Over the years several devices and media have been used as secondary memory. they are as follows.
FFD(Floppy Disc Drive):
The floppy disk (or a 3.5 floppy for today’s standard) is a magnetic storage medium mainly used for computers. A floppy drive is the part of the computer that reads from and writes to the floppy disk. Floppy disks store less data than a CD-ROM or USB flash drive. A current 3.5 inch floppy can take 1.44 megabytes of data. This is usually enough for text documents. Special floppies were made to hold 2.88 MB of data, but they were not commonly available. Today, floppy disks have been replaced by other storage media, like memory sticks. A few years ago, the zip disk was made as a replacement for floppies.
HDD(Hard Disc Drive):
The HDD is used by a computer to store operating System(OS) and the user’s data. In the majority of computer, hard disk drives are permanently placed in an internal drive bay at the front of the CPU cabinet and are connected with one ATA / SCSI cable and power cable. Unlike other drives, the hard disk drive is the only drive that is not physically accessed by the user like the floppy disk drive or the CD-ROM drive. Hard Disk stores digitally encoded data on rapidly rotating patterns with magnetic surfaces.
CD-ROM:
The compact disk is another storage device. Like the floppy disk, it is also not fixed in the system unit. Only the drive(CD-ROM) is fixed with the system. CD can store vast quantities of data-600MB or more.
CD-RW:
CD-ReWritable disk is a type of CD disk that enables you to write onto it in multiple sessions. One of the problems with CD-R disks is that you can only write to them once. With CD-RW drives and disks, you can treat the optical disk just like a floppy or hard disk, writing data onto it multiple times.
DVD-RW:
DVD-RW disc is a rewritable optical disc with equal storage capacity to a DVD-R, typically 4.7 GB. The format was developed by pioneer in November 1999 and has been approved by the DVD forum. Unlike DVD-RAM, it is playable in about 75% of conventional DVD players. The smaller Mini DVD-RW holds 1.46 GB, with a diameter of 8 cm.
The primary advantage of DVD-RW over DVD-R is the ability to erase and rewrite to a DVD-RW disc. According to pointer, DVD-RW discs may be written to about 1,000 times before needing replacement, making them comparable with the CD-RW standard. DVD-RW discs are commonly used for volatile data, such as backups or collection of files. They are also increasingly used for home DVD video recorders. One benefits to using a rewritable disc is if there are writing errors when recording data, the disc is not ruined and can still store data by creasing the faulty data.
Megnetic Taps:
It is a medium for magnetic recording generally consisting of a thin magnetic coating on a long and narrow strip of plastic. Nearly all recording taps of this type, weather used for recording audio or video or for computer data storage. Devices that record and playback audio and video using magnetic tape are generally called tape recorders and video tape recorders respectively. A device that stores data on magnetic taps can be called a tape drive, a tape unit, or a stramer.