1. Primary Storage (RAM and ROM)
Primary storageis directly accessed by the CPU. It holds the data and instructions that the CPU needs to access while the computer is running. The CPU can access data from primary storage much faster than secondary storage.
RAM (Random Access Memory)
- Holds programs and datacurrently in useby the CPU.
- Volatile— contents are lost when the computer is powered off.
- Read and write— data can be read from and written to.
- Larger than ROM.
- Access time is much faster than secondary storage.
- When you run an application, data is retrieved from secondary storage and placed temporarily into RAM.
ROM (Read Only Memory)
- Holdsstartup instructionsfor the computer, known as thebootstrap.
- Contains theBIOS(Basic Input Output System).
- Non-volatile— contents are retained when the computer is powered off.
- Read-only— cannot be written to.
- Smaller than RAM.
- In embedded systems, programs may be stored in ROM.
Why a Computer Needs Both RAM and ROM
- ROMstores the permanent instructions needed to start the computer (BIOS/bootstrap). Without ROM, the computer wouldn't know how to start up.
- RAMprovides the temporary workspace for running programs. Without RAM, there would be no space to run programs efficiently.
- RAM is volatile and can be written to, while ROM is non-volatile and read-only — they serve different purposes.
DRAM vs SRAM
| DRAM (Dynamic RAM) | SRAM (Static RAM) |
|---|---|
| Uses transistors and capacitors | Uses flip-flops to hold each bit |
| Needs constant refreshing | Does not need refreshing |
| Less complex circuitry | More complex circuitry |
| Consumes more power (needs refreshing) | Consumes less power |
| Less expensive to manufacture | More expensive to manufacture |
| Slower data access time | Faster data access time |
| Higher memory capacity | Lower memory capacity |
| Used in main system memory | Used in processor cache memory |
Real-Life Example: Remote-Controlled Toy Car
ROM
- Stores the factory settings such as remote control frequencies
- Stores the 'start-up' routines when the toy car is first switched on
- Stores the set routines — how buttons control turning left, acceleration, stopping, etc.
RAM
- The user may wish to program in their own routines; these new instructions would be stored in the RAM chip
- The RAM chip stores the data/instructions received from the remote control
Activity 1: RAM and ROM
- Describe the purpose of the ROM in a computer. [2]
- Describe the purpose of the RAM in a computer. [2]
- Explain why a computer needs both RAM and ROM. [4]
Solution:
- ROM stores the start-up instructions / bootstrap [1]. It is used to start the computer / contains the BIOS [1].
- RAM stores the parts of the OS / programs that are running [1]. It stores data currently in use for access by the CPU [1].
- ROM stores the permanent instructions needed to start the computer [1]. RAM provides the temporary workspace for running programs [1]. Without ROM, the computer wouldn't know how to start up [1]. Without RAM, there would be no space to run programs efficiently [1].
Check Your Understanding: Primary Storage
1. What is primary storage? [2 marks]
- [1]Storage that is directly accessed by the CPU
- [1]Includes RAM, ROM, registers and cache
2. What is the difference between volatile and non-volatile memory? [2 marks]
- [1]Volatile memory loses its contents when the power is turned off (e.g. RAM)
- [1]Non-volatile memory retains its contents when the power is turned off (e.g. ROM)
3. What is stored in ROM? [2 marks]
- [1]Startup instructions / bootstrap / BIOS
- [1]The instructions needed for a computer to start up once the power is switched on
4. Explain the difference between DRAM and SRAM. [4 marks]
- [1]DRAM uses capacitors and needs constant refreshing
- [1]SRAM uses flip-flops and does not need refreshing
- [1]SRAM is faster but more expensive; DRAM is slower but cheaper
- [1]DRAM is used for main memory; SRAM is used for cache memory
5. A smart TV uses RAM. Give two examples of data that the smart TV could store in RAM. [2 marks]
- [1]Current channel being watched / current video being streamed
- [1]Web browser / applications that are running / data being downloaded or buffered
6. Describe how RAM and ROM chips could be used in a microwave oven. [4 marks]
- [1]RAM stores user settings (time, weight, defrost settings)
- [1]RAM stores temporary data such as the current time remaining
- [1]ROM stores the microwave wavelength / pre-programmed cooking times
- [1]ROM stores safety systems / the control program