Title: SA19CS Computing Science
1SA19CS Computing Science
Lecture 3 Hardware Nuts and bolts
Written by Derek Watson
2Learning Outcomes
- After this lecture you will
- Know how a computer uses binary codes to
represent data in electrical form. - Be able to describe how the computer systems CPU
and memory components process program
instructions and data.
3Two Computer Architectures
- Digital Computers
- count
- Analogue Computers
- measure
4Data Representation
- Binary system - data is represented by
- combinations of 0s and 1s, which correspond
to the two states on and - off
- Bit - a binary digit
- Byte - a group of 8 bits representing a
character - Word - a unit of storage containing a number
- of bits typically 16, 32 or 64 bits
5Binary Coding Systems - 1
- 8 bit system
- ASCII American Standard Code For Information
Interchange - most widely used code for microcomputers
- EBCDIC Extended Binary Coded Decimal
- Interchange Code
- used mainly for large computers
6Binary Coding Systems - 2
- 16 bit system
- Unicode
- used for languages which have more
- characters than can be represented by an 8
bit system. - can represent up to 65,536 characters.
7Data Representation
ON
OFF
BIT
BYTE
4
1
2
8
4
1
2
8
Zone
Digit
8ASCII Coding
- Character ASCII EBCDIC
- A 0100 0001 1100 0001
- B 0100 0010 1100 0010
- C 0100 0011 1100 0011
- D 0100 0100 1100 0100
- E 0100 0101 1100 1001
- 0 0011 0000 1111 0000
- 1 0011 0001 1111 0001
- 2 0011 0010 1111 0010
- 3 0011 0011 1111 0011
- 4 0011 0100 1111 0100
9A Schematic Diagram of a Computer
CPU
Control
Data
Output devices
Input devices
Main memory
Information
Arithmetic logic unit
Secondary storage
10Components of the CPU
Controls transfer of data between CPU and memory,
and CPU I/O devices.
Control Unit
Performs arithmetic computations and logical
(comparing) operations on data
Arithmetic/Logic Unit
Holds instructions, data, intermediate and final
results of processing
Memory
11Personal Computer
hard disk
secondary storage
monitor
output
system unit
process
printer
output
disk drive
mouse
keyboard
secondary storage
input
input
12System or Mother Board
- Connects all the components of a computer system
and allows peripheral devices for input, output,
secondary storage and communications to
communicate with the system unit. - Large flat board covered with sockets for chips
and other control boards (cards) - a chip consists of a tiny square of silicone
material with circuits etched onto its surface.
It can contain a processor or be used as memory.
Its mounted on a carrier which plugs into a
socket on the system board.
13System or Mother Board
14The Microprocessor
- A chip containing the CPU
- Control Unit
- Arithmetic and Logic Unit (ALU)
- Register
- Bus
15Immediate Access Memory
16Immediate Access Memory
Address
2
3
Column
0
1
2
3
4
5
6
7
8
9
10
11
12
13
0
1
Row
2
3
4
17Measuring Memory Capacities
- Kilobyte (Kb) 1 thousand bytes (actually 1024)
- Megabyte (Mb) 1 million bytes
- Gigabyte (Gb) 1 billion bytes
- Terabyte (Tb) 1 trillion bytes
18Registers
- Special storage locations used by the control
unit and the ALU as high speed staging areas. - Program instructions and data are normally loaded
into the registers from memory just before
processing.
19Microprocessors
Processor Manufacturer Type Usage Pentium Intel C
ISC IBM compatible PCs PowerPC Motorola RISC Apple
ALPHA DEC RISC Workstations MIPS Silicon
Graphics RISC Workstations, video games
CISC (complex instruction set computer) designed
by Intel and found in all PCs. RISC (reduced
instruction set computer) uses fewer
instructions than CISC.
20System Clock
- Controls the speed of operations in a computer.
- A crystal oscillates at a fixed speed expressed
in megahertz (MHz). - 1 MHz 1 million cycles (beats) per second.
- The faster the clock speed the faster the
processor (but not necessarily the computer) can
process data.
21Processor Speeds
- Typical microprocessor speeds
- 500 - 600 MHz (cheap PC)
- 700 - 750 MHz (mid range PC)
- 1000 MHz (top of the range)
- 1000 MHz 1 GHz (Gigahertz)
22Expansion Slots and Cards
- Expansion slots are special sockets on the system
board. - Provide the PCs open architecture
- Allow new devices to be added easily by plugging
in interface (expansion or controller) cards. - TV tuner card
- disk controller card
- network adaptor card
- SCSI (small computer system interface) card.
- Plug and Play aims to remove interface problems.
23Card
24Bus
- A line which connects system components.
- A data highway along which data is passed from on
part of a CPU to another - The higher capacity the bus, the faster data is
transferred. - Bus architectures
- ISA (Industry Standard Architecture) slow but
widely used. - PCI (Peripheral Component Interconnect) 20 times
faster than ISA, replacing ISA. - AGP (Accelerated Graphics Port) twice as fast as
PCI used for graphics and 3D animation.
25The Parity Bit
Used to check that a bit string has been sent
correctly. An extra bit is added. On an even
parity computer the sum of the bits in each byte
must be an even number. On an odd parity computer
the sum of the bits in each byte must be an odd
number.
Even parity
26Ports
Sockets used to connect the system box to
peripheral devices for specific or general
purposes.
Parallel port
Parallel plug
Audio port
Mouse port
Keyboard port
Serial port
27Ports
Serial ports send data 1 bit at a time. used for
mouse, keyboard
Parallel ports send 8 bits along parallel
wires. used for printer
USB (Universal Serial Bus) replacing serial and
parallel ports, faster. One USB port can handle
several devices.
28Special Purpose Ports
- AGP (Accelerated Graphics Port)
- monitor, video input
- Firewire ports are faster than USB
- high-speed printers, video cameras
29Memory - 1
- RAM Random-Access Memory
- Volatile holds data and instructions
temporarily as long as the the computer is
switched on. - Flash RAM or flash memory is a newer type which
is non-volatile but its expensive. - Amount of RAM in a computer determines which
programs will run and how efficiently e.g. Excel
2000 needs 20 MB, extra is needed for data or
other applications. - Using virtual memory allows a computer to divide
large programs into sections. Sections are stored
on disk and loaded into the CPU when required. - Cache memory stores the most frequently accessed
data stored in RAM
30Memory Chips
31Memory - 2
- ROM Read-Only Memory
- permanent holds data and instructions even when
the computer is switched off. - Data or program instructions are read only and
cannot be changed. - Other forms of ROM
- PROM - Programmable ROM
- EPROM - Erasable PROM
- used to contain fixed start-up programs, e.g.
booting program to start a computer, or
instructions to put characters on the screen.
32Memory - 3
- CMOS complementary metal-oxide semiconductor
- Powered by a battery and retains its contents
when the computer is switched off. (unlike RAM) - its contents can be changed when hardware devices
or time are changed. - Used for flexible start-up instructions e.g. date
and time, size of RAM, type of keyboard and
monitor, mouse and disks.