IGCSE Computer Science Unit 3 - Hardware
3.3 - Data Storage
Candidates should be able to:
a. Understand what is meant by primary storage, including RAM & ROM
b. Understand what is meant by secondary storage
c. Describe the operation of magnetic, optical and solid-state storage & give examples
d. Describe what is meant by virtual memory, how it is created & used, why it is necessary
e. Understand what is meant by cloud storage
f. Explain advantages & disadvantages of storing data on the cloud vs storing it locally
Primary Storage
Primary storage refers to internal computer memory that is accessed directly by
the CPU. This includes cache memory (within the CPU itself}, RAM and ROM.
Random Access Memory (RAM)
AKA: Main Memory, Primary Memory, Internal Memory
• Memory module(s) for temporary storage of data
• Fast to access - data can be accessed directly from any memory address
• Data can be read from/ written to RAM
• Volatile - data is lost when the power is turned off.
• Holds all program instructions & data currently in use
• Capacity generally quite small (several GB)
• More RAM= better performance
• Embedded systems may only need a small amount
Read Only Memory (ROM)
• Memory containing permanent instructions
• Used by computer when it boots up
• Read from BIOS (Basic Input/ Output System)
• Non-volatile (data persists when power is turned off)
• Read Only (under normal computer use)
Cache Memory
• Super fast access memory
• Situated in or next to CPU
• Small capacity
• Temporary storage
• Contains instructions waiting to be executed by CPU
• Volatile
1
IGCSE Computer Science Unit 3 - Hardware
Secondary Storage
Secondary storage refers to memory that retains its contents when the computer is
switched off (non-volatile). It can be used to hold both programs and data. Its capacity is
usually considerably greater than that of main memory.
When you run a program or load a file they are copied from secondary storage into the
main memory. When you save a file, it is copied from the main memory to the secondary
storage.
Differences between Primary & Secondary Storage
Primary Storage Secondary Storage
Accessed directly by CPU (fast) No direct access by CPU, must go via RAM (slower)
Temporary storage (volatile) Permanent storage (non-volatile)
Small capacity Large capacity
Internal, fixed. May be removable
Off-Line Storage
Offline storage refers to any type of storage device or medium that you remove from your
computer, such as USB drives, CDs & external hard drives.
Storage Technologies
Secondary storage can be divided into three main categories:
Magnetic
Stores binary data on a disk or tape coated with a material where different
areas on the surface can be magnetised North or South to store the binary
digits O or 1.
Optical
Stores binary data in a surface where different areas either reflect or do not
reflect laser light differently to store the binary digits O or 1.
Solid state (Flash memory)
Stores binary data on semi-conductor material where different areas act as
switches, either open or closed, to store the binary digits O or 1.
2
IGCSE Computer Science Unit 3 - Hardware
Properties of Storage Devices & Media
The following table shows the properties associated with storage devices and media, that
will help to determine which device / media is best suited to a particular purpose.
Property Description
The amount of data that can be stored, measured in bits / bytes / MB /
Capacity
GB etc.
Portability How easy it is to transfer data to/from the device/media
How well the device/media lasts over time... is it easily damaged (e.g.
Durability
optical media easily scratched)
Reliability How consistently does it perform
Access speed How quickly data can be read from and/or written to the device/media.
Cost What is the cost per KB, MB, GB etc. of data
MAGNETIC
Hard Disc Drive {HDD)
• Data is stored by magnetising the surface of flat, circular plates called platters. These
rotate at very high speeds and a read/write head moves from side to side to load and
save data. The drive is inside a sealed unit because even a speck of dust could cause the
heads to crash.
Data is stored on the disc in blocks arranged in tracks and sectors. These are created
when the hard disc is first formatted and this must take place before the disc can be
used.
For a drive to read data from a disc, the read/write head must move in or out to align
with the correct track (the time to do this is called the seek time). It must wait then until
the correct sector rotates round until it underneath the read/write head.
• Applications: The hard drive is usually the main backing storage media for a typical
computer or server. It is used to store:
o The operating system,
o Applications software
o Files such as documents, music, video etc.
• Advantages: Very fast access to data. Data can be read directly from any part of the hard
disc (random access). The access speed is over 1000 KB per second.
• Disadvantages: Moving parts mean that they don't respond well to being thrown
around & will eventually fail. Data could be wiped by (extremely powerful) magnet. Can
be quite noisy. Higher power consumption than drives without moving parts.
3
IGCSE Computer Science Unit 3 - Hardware
OPTICAL
Compact Disc (CD), Digital Versatile Disc (DVD} & Blu-Ray Disc
• All examples of optical media storage.
• Advantages: Portable & cheap to produce.
• Disadvantages: Small memory capacity, easily damaged, slower data transfer
• Typical applications: Distribution of software programs/music/video/games
CD DVD 8/u-Ray
Capacity 650MB 4.7 GB 25GB - 128GB
Usage Music / Software Movies Movies / Console Games
Data Transfer Slower �
� �
� Faster
How it Works
The surface of an optical disc uses a layer of reflective aluminium, which is covered in tiny
indentations called pits. The spaces between the pits are known as lands.
Optical discs are created using a laser. The disc is
rotated whilst the laser beam burns indentations
into the surface of the disc (pits). The data is
written in concentric, spiralling tracks. The pits
and lands represent binary values (ls and Os).
This process is called burning data to the disc.
CD
The size of the pits and distance between them
are smaller on a Blu-ray disc, and are read using a
violet/blue laser, which has a shorter wavelength
DVD
than the red laser used to read a CD or DVD. This
means that the storage capacity of a Blu-ray disc
is much greater as more pits can be created on
the surface. Blu-ray discs may also have multiple
reflective layers, thereby significantly increasing
their storage capacity.
Optical discs are read by shining a laser at the surface of the disc as it is spinning and sensing
the intensity of the light reflected. Light reflects back at a different intensity when
transitioning between pits and land. More light being reflected stands for a 1 and less light
being reflected stands for a 0 (or vice versa).
4
IGCSE Computer Science Unit 3 - Hardware
Optical Disc Types
Compact Discs, DVDs and Blu-ray discs are all available in numerous formats... such as CD
ROM, DVD-RW etc. but what do the letters mean?
Optical Media Suffix Description
Read Only Memory. You cannot write to a ROM disc. Data
is written to the ROM disc at time of manufacture and
CD/ DVD/ BD ROM cannot be erased or overwritten. Music CDs, Movie DVDs,
Console Game BDs etc. are all purchased on ROM discs.
Recordable. You can write to one of these discs one time
CD/ DVD/ BD R only. Once written to, it becomes a ROM disc. Data is
stored in one long spiral track.
Rewritable. Can be written to, erased and rewritten to
CD/ DVD RW numerous times. Data is stored in one long spiral track.
BD RE Recordable Erasable. Blu-ray version of RW
Rewritable. Data stored in concentric tracks, so very fast
access. Can read and write at the same time. Often used
DVD RAM for Digital TV recording (set top boxes) and camcorders,
also good for archival storage of data because of long life
(est. 30 years)
5
IGCSE Computer Science Unit 3 - Hardware
SOLID STATE
Solid state storage devices typically use flash memory to store data persistently. A Solid
State Drive (SSD) may be used in place of or in tandem with a magnetic HDD inside a
computer as secondary storage. Offline storage devices such as USB drives, SD cards and
external SSDs use the same flash memory.
Solid State Drive (SSD) (Flash Memory)
A solid-state drive (SSD) is a data storage device that uses solid-state memory to store data
in the same way as a traditional hard disk drive. SSDs use microchips to store data instead of
magnetised disks and do not contain any moving parts. SSDs use the same interface as hard
disk drives, thus easily replacing them in most applications.
Typical applications: Same as hard disk drives. Persistent
storage for Operating System.
Advantages: Less susceptible to physical shock, no noise,
lower access time and latency than hard disk drives. Not
affected by magnets! Lower power consumption.
Disadvantages: Currently, storage capacity not as high as for HDDs (but this is constantly
improving). Data cannot be overwritten - existing data must be deleted first. Limited
number of write operations in lifetime of SSD due to the degradation of the isolating layers
in the floating gates over time.
Floating Gates
Flash memory uses floating gates to store electrons, allowing individual gates to have a
value of 1 (no electrons) or O (some electrons). Changes in voltage applied to the gate allow
electrons to pass through the isolation layer and into or out of the floating gate.
SILICON SUBSTRATE SILICON SUBSTRATE
[Link] SUBSTRATE [Link] SUBSTRATE
6
IGCSE Computer Science Unit 3 - Hardware
Cloud Storage
• Data is not stored on your device
• Data is stored remotely... in the CLOUD!
• Physical servers and storage are needed to store data
• Server farms/ data warehouses
e.g. OneDrive/ Google Docs/ Drop Box etc...
Advantages:
• Access your data • Don't need to worry about
Anywhere Data security
Any time Maintenance of HW
On any device Backups/ Syncing/ Updating
Disadvantages:
• No Internet= No access!
• Can be expensive
• Lack of support
• More vulnerable to cybercrime
• Data privacy
Virtual Memory
When RAM is full (too many processes/ applications running at the same time), there needs
to be a way for the CPU to execute instructions that are not currently available in RAM.
To enable this, Virtual Memory is used...
• An area of memory in secondary storage is allocated.
• Currently unused/inactive pages of instructions in RAM are moved to secondary storage.
• Pages of required instructions are copied from secondary storage into RAM.
• The CPU can now access the instructions it needs.
• Once complete, instructions can be moved back into RAM from secondary storage.
This is very slow & inefficient, and overuse will cause disk thrashing!
A computer with limited RAM becomes slow if...
• Too many programs running
• Too many large files loaded
• Processor intensive operations (e.g. rendering graphics, movie editing)
7
IGCSE Computer Science Unit 3 - Hardware
-
Virtual Memory
1
g 2
g
'
�
SECONDARY STORAGE
B
Q
RAM
CPU
•• Q
SECONDARY STORAGE RAM
CPU
RAM IS FULL, BUT OTHER INSTRUCTIONS MUST RUN ... INACTIVE PAGES MOVED FROM RAM TO VIRTUAL MEMORY
3
g 4
g
11111
'I
CPU B CPU
Q Q
SECONOARY STORAGE RAM SECONDARY STORAGE RAM