Computer System Notes

Processor

  • Also called CPU (Central Processing Unit), it is a critical device and the core of a computer.

  • Computer Configuration:

    • Input device

    • CPU

      • Control device

      • Operation device

    • Main memory

    • Output device

    • Auxiliary storage devices

    • Peripheral devices

    • Flow of control

    • Flow of data

Basic Framework of CPUs

  • Initially, CPUs comprised multiple chips.

  • Advancements in technology enabled CPUs to be contained in a single chip called a “Microprocessor.”

  • CPU incorporates "control" functions (sending instructions) and "operation" functions (performing calculations).

Types of CPU

Developer

Brand

Description

Intel

Pentium

Successor to the x86 family of processors. Includes Pentium Pro, Pentium II, Pentium III, Pentium 4, and Pentium D.

Intel

Celeron

CPU aimed at lower-cost computers. The brand name remains consistent across version upgrades.

AMD

Athlon

Includes Athlon MP for servers, Athlon and Athlon XP for general computers, and Mobile Athlon and Mobile Athlon 4 for laptops.

AMD

Duron

CPU aimed at lower-cost computers, designed to compete with Intel Celeron processors.

Motorola, IBM, Apple

PowerPC

Includes the PowerPC 601, 603, 604, 740, 750, G4, and G5. PowerPC processors are used in Apple Macintosh computers.

Clock Frequency

  • Definition: A cyclical signal that coordinates the timing of operations within the CPU or with external devices.

  • Indicates the number of signals per second.

  • CPUs with the same bits can have different throughput based on clock frequency.

  • Higher clock frequency results in greater data processing capacity and faster speed.

  • Measured in Hertz (Hz).

Bus Width

  • Definition: A path used to exchange data between devices.

  • Indicates the number of signal lines in the bus, measured in bits.

  • Internal Bus: Exchanges data inside the CPU.

  • External Bus: Exchanges data between the CPU and memory or peripheral devices.

Calculation of CPU Instruction Execution Count

  • Example:

    • A CPU operates at 200MHz and executes one machine language instruction at an average of 0.5 clocks.

    • Calculation:

      • CPU clock frequency ÷ Clocks per instruction

      • 200MHz÷0.5clocks200MHz ÷ 0.5 clocks

      • =200×106= 200 \times 10^6 clocks per second ÷ 0.5 clocks per instruction

      • =400= 400 million instructions per second

Storage Devices

  • Definition: Devices that store data required for computer processing.

Memory

  • Refers to devices used to store programs and data required for computer operation.

Types of Memory

  • RAM

    • DRAM

    • SRAM

  • ROM

    • Mask ROM

    • EPROM

    • EEPROM

RAM (Random-Access Memory)

  • Volatile memory: Stored content is lost when power is off.

  • Data can be read and written.

  • Used as main memory or cache memory.

DRAM (Dynamic Random-Access Memory) vs. SRAM (Static Random-Access Memory)

Comparison Item

DRAM

SRAM

Capacity

Large

Small

Processing Speed

Slow

Fast

Cost

Low

High

Refresh Function (Electricity)

Available

Not Available

Power Consumption

High

Low

ROM (Read-Only Memory)

  • Non-volatile memory: Retains stored content after power is turned off.

  • Used for data, programs, and rewriteable ROMs (flash memory or BIOS storage).

EPROM (Erasable Programmable Read-Only Memory) & EEPROM (Electrically Erasable Programmable Read-Only Memory)

Type

Characteristics

Mask ROM

Data is written during manufacturing and cannot be rewritten.

EPROM

Data can be written afterwards and erased using ultraviolet light.

EEPROM

EPROM that can erase data electrically. Flash memory is a typical type used in digital cameras and IC cards.

Flash Memory

  • Electrically rewriteable EEPROM.

  • Used for BIOS storage or as an auxiliary storage device in computers.

BIOS (Basic Input/Output System)

  • Program that controls input/output between the computer unit and peripheral devices.

  • Stored in ROM and integrated into the motherboard.

  • Abbreviation for “Basic Input/Output System.”

Memory Applications

Type

Characteristics

Main Memory

Stores programs and data that the CPU processes. DRAM is used.

Cache Memory

Speeds up computers by addressing differences in access speeds between the CPU and main memory. Multiple cache levels exist (primary and secondary), with SRAM used.

VRAM

Dedicated memory for temporary storage of image data shown on the display. Typically separate from main memory and integrated into graphics accelerator boards. DRAM is used.

Cache Memory Functionality

  • Without Cache Memory:

    • Data is constantly exchanged between the CPU and main memory, leading to wait times and reduced efficiency.

  • With Cache Memory:

    • Data is stored in the cache when the CPU reads it from main memory.

    • Subsequent access to the same data is faster since the CPU reads from the cache memory.

    • Improves processing efficiency.

Types of Main Memory

  • Memory types vary based on the computer.

  • Expanding main memory involves adding the correct type of memory.

SIMM and DIMM

  • SIMM: Single In-line Memory Module

  • DIMM: Dual In-line Memory Module

  • Expansion memory is added to expand built-in standard memory.

Storage Media

  • Devices that store created data and files.

  • Also known as “auxiliary storage devices.”

Magnetic Disk

  • Storage media that uses magnetization to read and write data.

Construction of Magnetic Disk

  • Formatting (initialization) is required to organize the disk into tracks and sectors for data storage.

Sequence for Read/Write Operations of Magnetic Disks

  1. Magnetic head moves to the target track.

  2. Waits for the target sector to rotate into position (rotational latency).

  3. Reads/writes data to/from the target sector (data transfer).

Fragmentation and Optimization (Defragmentation)

  • Fragmentation: Occurs when data is stored across multiple regions of the hard disk due to repeated adding, deleting, and moving data.

  • Optimization (Defragmentation): Repairs fragmentation to reduce seek operations and improve access speed.

Calculating the Capacity of Magnetic Disks

  • Storage Capacity Formula:

    • Storage capacity per sector ×\times No. of sectors per track ×\times No. of tracks per surface ×\times No. of storage surfaces

  • Example #1:

    • Floppy disk specifications:

      • No. of tracks per surface: 80

      • No. of sectors per track: 18

      • Sector length (bytes): 512

      • Storage surface: Both sides

    • Answer:

      • 512 bytes×18 sectors1 track×80 tracks1 surface×2 surfaces=1,474,560 bytes=1.4 MB512 \text{ bytes} \times \frac{18 \text{ sectors}}{1 \text{ track}} \times \frac{80 \text{ tracks}}{1 \text{ surface}} \times 2 \text{ surfaces} = 1,474,560 \text{ bytes} = 1.4 \text{ MB}

  • Example #2: Disk divided into 120-cylinder zones with sectors of different zones containing 200, 240, 280, and 320 sectors. Each sector contain 4096 bytes. What is the disk capacity.

    • 120×200+120×240+120×280+120×320=124,800bytes120 \times 200 + 120 \times 240 + 120 \times 280 + 120 \times 320 = 124,800 \text{bytes}

    • 124800 bytes×4096 bytes=511,180,800bytes124800 \text{ bytes} \times 4096 \text{ bytes} = 511,180,800 \text{bytes}

Number of Sectors Needed to Store Data Formula

  • Formula:

    • Data length ÷ Storage capacity per sector

  • Example #3:

    • For a floppy disk with 512 bytes per sector, how many sectors are needed to store 500, 1400, and 1600 bytes of data?

  • Answer:

    • 500 bytes ÷ 512 bytes = 0.976 (1 sector)

    • 1,400 bytes ÷ 512 bytes = 2.734 (3 sectors)

    • 1,600 bytes ÷ 512 bytes = 3.125 (4 sectors)

    • Total: 1 + 3 + 4 = 8 sectors

Optical Disks

  • Storage device that uses laser optics to read and write data.

  • Types:

    • CD-ROM: Compact Disc Read-Only Memory

    • CD-R: Compact Disc Recordable

    • CD-RW: Compact Disc Rewritable

    • DVD-ROM: Digital Versatile Disc Read-Only Memory

    • DVD-RAM: Digital Versatile Disc Random Access Memory

    • DVD-R: Digital Versatile Disc

    • DVD-RW: Digital Versatile Disc Rewritable

Other Storage Media than Magnetic Discs

  • Streamer (Magnetic Tape Drive):

    • Continuously reads and writes data.

    • Stores tens to hundreds of GB.

  • MO Device (Magneto-Optical Disk Drive):

    • Writes data using laser optics and magnetism.

    • Capable of repeated rewriting.

    • Stores hundreds of MB to several GB.

  • Flash Memory:

    • Non-volatile, rewriteable storage that retains content after power off.

    • USB Memory:

      • Reads and writes data using flash memory.

      • Stores tens of MB to tens of GB.

    • SD Memory Card:

      • Reads and writes data using flash memory.

      • Used in digital cameras and mobile phones.

      • Stores tens of MB to tens of GB.

Storage Hierarchy

  • A pyramid-shaped hierarchy illustrating the structure of storage devices used by computers.

  • Storage devices are stacked by data access speed.

  • Faster access speeds are at the top, closer to the CPU.

Input and Output Devices

  • Computers connect to peripherals (printers, scanners) using matching interfaces.

Input/Output Interfaces

  • Intermediary device/system for exchanging data between two points.

Types of Data Exchanged

  • Analog:

    • Electronic signal with a wave-like pattern.

    • Expressed as a continuous value.

  • Digital:

    • Electronic signal with a bar graph pattern (numerical value conversion).

    • Expressed as a concrete numerical value.

Serial Interface

  • Transfers data one bit at a time.

  • Uses fewer signal lines and is less prone to signal variation.

  • IEEE 1284:

    • Connects a computer to a printer.

  • SCSI:

    • Connects a computer to peripherals.

    • Up to seven external peripherals can be connected in a daisy chain method.

Daisy Chain Method

  • Diagram illustrating the connection of multiple SCSI devices (hard disks, CD-ROM drive, MO drive, printer, scanner) to a computer unit; uses terminators at the end.

Wireless Interface

  • Transfers data using infrared or wireless transmission technology.

  • Transmission speed varies depending on distance.

Standards for Wireless Interfaces
  • IrDA:

    • Uses infrared communication.

    • Distance: within two meters.

  • Bluetooth:

    • Uses 2.4GHz band.

    • Transmission speed: 1Mbps.

    • Range: 10 meters.

Device Driver

  • Software that enables the use of a peripheral.

  • Modern operating systems are “plug and play,” automatically enabling peripherals upon connection.