Professional Documents
Culture Documents
Fundamentals of Hardware and Software
Fundamentals of Hardware and Software
3
What is a computer?
A computer is an electronic device, operating processed into meaningful form and that is
under the control of instructions stored in its own valuable to the user
memory that can accept data (input), process the
data according to specified rules, produce Supermarket receipt
information (output), and store the information for
future use.
Supermarket items
2 Medium Sodas $1.49 each
1 Small Turkey Sub $3.49 each
1 Caesar Salad $4.49 each
1 Bag of Chips $0.99 each There are two main component of a computer:
3 Cookies $0.39 each
1. Hardware
Amount Received $20
2. Software.
Supermarket POS
1. Calculation: Computes each item’s total price by
multiplying the quantity ordered by the unit price.
4
The computer system Advantages and
overview disadvantages of using a
computer
There are numerous advantages and disadvantages
of using a computer.
Advantages
1. Speed
Many computers process billions or trillions
of operations in a single second.
2. Reliability
Computers are everywhere: at work, at school,
The electronic components in modern
and at home. While some computers sit on top of
computers are dependable and reliable
a desk or on the floor, mobile computers and
because they rarely break or fail.
mobile devices are small enough to carry. Mobile
devices, such as many cell phones, often are
classified as computers. 3. Consistency
Given the same input and processes, a
People use all types and sizes of computers for a
computer will produce the same results —
variety of reasons and in a range of places:
consistently. A computing phrase — known
as garbage in, garbage out — points out that
Consumers use computers to correspond with
the accuracy of a computer’s output depends
businesses, employees with other employees
on the accuracy of the input.
and customers, students with classmates and
teachers, and family members and military
personnel with friends and other family 4. Storage
members.
Many computers store enormous amounts of
Local and national news, weather reports, data and make this data available for
sports scores, airline schedules, telephone processing anytime it is needed.
directories, maps and directions, job listings,
credit reports, and countless forms of 5. Communications
educational material always are accessible.
Most computers today can communicate
Banks place ATMs (automated teller with other computers, often wirelessly, to
machines) all over the world, so that share computer resources
customers can deposit
5
Disadvantages generated when using a computer. Strategies
that support green computing include
1. Health Risks recycling, regulating manufacturing
processes, extending the life of computers,
Prolonged or improper computer use can
and immediately donating or properly
lead to injuries or disorders of the hands,
disposing of replaced computers.
wrists, elbows, eyes, neck, and back.
2. Violation of Privacy
Nearly every life event is stored in a
computer. In many instances, where
personal and confidential records were not
protected properly, individuals have found
their privacy violated and identities stolen.
3. Public Safety
Innocent computer users have fallen victim
to crimes committed by dangerous strangers.
5. Impact on environment
Computer manufacturing processes and
computer waste are depleting natural
resources and polluting the environment
with toxic materials and potentially
dangerous levels of lead, mercury, and flame
retardants.
6. Green computing
This involves reducing the electricity
consumed and environmental waste
6
7
Fundamentals of Hardware
On completion of this unit, students should appreciate the fundamental hardware and terminologies and concepts; develop
expertise in the operation and use of microcomputer-based systems.
What is computer
hardware?
Computers contain many electric, electronic, and
mechanical components known as hardware.
Hardware is the physical component of the
computer system.
8
Major hardware components and their functions
Processing
Processing is the manipulation of data according
to specified rules.
Processing device
The only processing device is the processor. The
processor is installed on the motherboard.
processor motherboard
9
ALU
It performs arithmetic, comparison, and Input
other operations
The CU executes instructions by performing the Input is whatever goes into the computer. Input
following steps: can take a variety of forms, from commands you
enter from the keyboard to data from another
Step (1) - fetching the instructions from memory computer or device.
Step (2) - decoding the instructions
Input devices
Step (3) - fetching the data required by the
instructions from memory An input device is any peripheral device that
allows entering data and instructions into a
Step (4) - sending the data and instructions to the computer.
ALU for processing.
Step (5) - sending the data to the memory unit after a. Keyboard devices
processing. – Keyboard.
6. A light-sensitive input device which, when it 13. A sound capture is an input device that
allows a user to capture sound into the
touches the screen, detects the presence or
absence of light. It is used to select an entry computer for processing.
or indicate a position.
Peripheral: A peripheral (or peripheral device) is
7. Users can interact with touch screens by any hardware you connect to a computer or
mobile device to expand its capabilities. Examples
touching areas of the screen.
11
include a keyboard, mouse, microphone, monitor, Output
printer, scanner, webcam, and speakers.
Output is any peripheral that conveys information
from a computer to one or more people
Output devices
An output device is any hardware component that
conveys information from a computer to one or
more people.
Display technologies
o Cathode Ray Tube (CRT)
o Liquid Crystal Display (LCD)
o Plasma
o High Definition TV (HDTV)
12
Pixel: A pixel (short for picture element) is c. Audio output
the smallest element in an electronic image. – speakers
13
5. Impact printers are used mostly in business Storage
to produce large volumes of print quickly.
Terms associated with output Storage is the act of keeping data/information for
access by a computer processor.
1. Hard copy: Printed information that exists
physically and is a more permanent form of
Storage devices
output than that presented on a display
device (soft copy). A storage device records (writes) and/or retrieves
(reads) items to and from storage media. Storage
2. Soft copy: Temporary output presented on a devices often also function as a source of input
display device. and output because they transfer items from
storage to memory and vice versa.
3. Human-readable: output devices that
produced hard or soft copies of information 1. Primary storage
or data that can be read and interpreted by
humans. 2. Secondary storage
b. Secondary storage
– Hard Disk Drive (HDD)
– Optical drives
– Floppy Disk Drive (FDD)
optical disc
times. CD-RW overcomes the major
disadvantage of CD-R because it allows users Floppy disk
to write and rewrite data, instructions, and
information on the CD-RW disc multiple Tape disk
times — instead of just once. Reliability of the
slower less expensive
disc tends to drop, however, with each
16
Comparison of secondary storage retrieve information directly without having
to scan a series of records.
Devices are chosen for a particular use based on
their:
8. Device interfaces:
1. storage capacity
IDE: An acronym for Integrated Drive
2. access speed Electronics
3. size
SCSI: An acronym for Small
4. portability Computer System Interface
5. cost.
SATA: An acronym for Serial
Advanced Technology Attachment.
Terms associated with storage
17
Communications 6. Hub
18
19
Fundamentals of Software
This section differentiates between system programs and application programs.
20
Disk checker can scan the contents of a hard Functions of System Software
disk to find files or areas that are corrupted in
some way, or were not correctly saved, and Operating systems
eliminate them for a more efficiently operating Most operating systems perform similar functions
hard drive; a Disk cleaner can find files that that include:
unnecessary to computer operation, or take up
– Startup and shut down a computer
considerable amounts of space. Disk cleaner
helps the user to decide what to delete when – Provide a user interface
his hard disk is full.
– manage:
21
General Purpose Application Software: a. Acrobat Reader
the big five b. Nitro
c. FoxIt
a. Word Processing
d. PDF-XChange Viewer
b. Spreadsheet
e. Sumatra
c. Database Management
d. Graphics Presentation 5. Flash players
e. Communication
Application Software Examples
Other software General purpose
(written for any specific – word
1. Burning Software:
business or organization – Excel
a. Nero burning software but can be used or – Access
b. Alcohol 120 adopted to suit a specific – PowerPoint
need)
c. Power ISO
Integrated Software – Microsoft Office
(set of related programs 2013, 2010, 2007
2. Media Players: combined in a unified – Microsoft works
a. Power DVD package that allows data
to be transferred – AppleWorks
b. Windows Media Player between the programs) – Lotus SmartSuite
c. VLC Media Player
– Air Traffic Control
d. Apple QuickTime Software,
e. Nero MediaHome Specialize Software – Accounting
(written for a specific
f. RealPlayer Software
field rather than a broad
application area) – Airline
g. Winamp
Reservation
h. KMPlayer Software
i. DivX
22
(software has no restrictions from the copyright User Interface management
holder regarding modification of the software’s
internal instructions and its redistribution)
Shareware
(Copyrighted software that is distributed at no Command Interface
cost for a trial period. To use a shareware
program beyond that period, you send payment to
the program developer)
Freeware
(Copyrighted software provided at no cost by an
individual or a company that retains all rights to
the software)
Public-domain software
(Copyrighted software provided at no cost by an The Command requires the user to type in
individual or a company that retains all rights to commands to communicate with the user. An
the software) example of an OS that provides a command
driven interface is MS-DOS (Microsoft disk
operating system)
Menu Interface
Menu is a list of options from which you can
choose. The keyboard or mouse is used to select
choices in a menu drive interface.
23
Data manipulation
This subsection describes how data are stored and manipulated within the computer system
– Binary (Base 2)
1492 = 2 + 90 + 400 + 1000
– Octal (Base 8) (expanded in base 10)
24
The Binary Number System
Base Valid digits 6 8º = 61 = 6
2 0, 1 5 8¹ = 58 = 40
4 8² = 4 64 = 256
Each place value is a power of 2.
8 0, 1, 2, 3, 4, 5, 6, 7 A 16º = 10 1 = 10
15 16¹ = 15 16 = 240
– Each place value is a power of 8.
1 16² = 1 256 = 256
– Octal to decimal:
The hexadecimal number 1FA = 10 + 240 + 256
digit0 8º + digit1 8¹ +..
= 506 (base 10)
Example
Solution
25
Conversions Convert the decimal number 57 to binary using 8-
bit representation.
Decimal-to-Binary conversion
Example Solution
Step (2): Write the remainders, from bottom to top, as the 5710 = 001110012 (8 bits) ans.
binary number.
Example
Positional 23 22 21 20
values 8 4 2 1
binary digits 1 1 1 0
Example
26
Decimal-to-Octal conversion Octal-to-Decimal conversion
Convert the decimal number 46510 to its octal digit0 8º + digit1 8¹ + ...
equivalent:
Example
Solution
Find the decimal equivalent of the octal number
Method 1: Repeated division (by 8) 1378
Example
Example
Convert the decimal number 254810 to its octal
equivalent. What is the decimal equivalent of the octal
number 16018?
Solution
Solution
Method 1: Repeated division (by 8)
1 8º = 11 = 1
Dividing Decimal number Octal
remainder
number
0 8¹ = 08 = 0
by 2548
8 318 4 6 8² = 6 64 = 384
8 39 6 1 8³ = 1 512 = 512
8 4 7
8 0 4 16018 = 1 + 0 + 384 + 512 = 89710
27
Decimal-to-Hexadecimal conversion Hexadecimal-to-Decimal conversion
Example – hexadecimal to decimal:
Convert the decimal number 580 10 to its digit0 16º + digit1 16¹ + ...
hexadecimal equivalent.
Example
Solution
Convert the hexadecimal number 20B316 to its
decimal equivalent.
Dividing Decimal number Octal
remainder Solution
by 580 number
16 36 4
3 16º = 31 = 3
16 2 4
16 0 2 B 16¹ = 11 16 = 176
0 16² = 0 256 = 0
58010 = 24416
2 16³ = 2 4096 = 8192
28
Binary-to-Octal / Hexadecimal 10110000112 = 2C416 ans.
conversion
Octal/Hexadecimal-to-Binary
Binary numbers require three digits to be able to
represent one digit in octal. When converting conversion
binary to octal, group the binary number into To convert from octal to binary, simply write
groups of three digits starting from the right, and down the three bit binary pattern for each octal
convert each group of three digits to one octal digit.
digit.
Example
Example
Convert the octal number 2638 to binary.
Convert the binary number 01110112 to octal.
Solution
Solution
263 = 010 110 011
0111011 = 010 111 011
2638 = 101100112 ans.
= 2 7 3
To convert from hexadecimal to binary, simply
01110112 = 2738 ans. write down the four bit binary pattern for each
hexadecimal digit.
Similarly, binary numbers require four digits to be
able to represent one digit in hexadecimal. When
converting from binary to hexadecimal, group the Example
binary number into groups of four digits starting
Convert the hexadecimal number 2A4E16 to
from the right, and convert each group of four
binary.
digits to one hexadecimal digit.
Solution
Example
2A4E16 = 0010 1010 0100 1110
Convert the binary number 10110000112 to
hexadecimal. 2A4E16 = 101010010011102 ans.
Solution
01110112 = 2738
29
Binary arithmetic 01012 + 10012 = 11102 ans.
0
0 1 1 0 1 1
Rule # 2 1 + 0 1 1 0 0
+ 0 1 0 0 1 1 1
1
0110112 + 011002 = 1001112 ans.
Rule # 3 0
+ 1
1 (c) 10010112 + 01011002
Rule # 4 1
1
+ 1
1 0 1 0 0 1 0 1 1
+ 0 1 0 1 1 0 0
Rule # 5 1
1 1 1 1 0 1 1 1
+ 1
1 1 10010112 + 01011002 = 1001001012 ans.
Example
Example
Perform the following binary addition
Using 8-bits, perform the following calculations
Solution:
Solution:
(a) 10011002 + 11001012
(a) 01012 + 10012
1 1 1
1
0 1 0 0 1 1 0 0
0 1 0 1
+ 0 1 1 0 0 1 0 1
+ 1 0 0 1
1 0 1 1 0 0 0 1
1 1 1 0
30
10011002 + 11001012 = 101100012 ans. Subtraction of binary numbers
+ 1 1 1 1 1 1 1 1
0
1 1 1 1 1 1 1 1 0 10
Rule # 5 1 0
111111112 + 111111112 = 111111112 ans. ‒ 1
1
Example
1 0 1 0
‒ 1 1 0
0 1 0 0
31
(b) 101102 ‒ 11002 Integers (positive and negative
0 10
numbers)
1 0 1 1 0
‒ 1 1 0 0 Positive numbers are represented as usual in
0 1 0 1 0 regular binary. However, negative numbers are
represented differently. There are many schemes
101102 ‒ 11002 = 010102 ans. for representing negative integers with patterns of
bits. Some examples are:
(c) 100012 ‒ 1002
– Signed and Magnitude
1
0 10 10
– One's Complement
1 0 0 0 1 – Two's Complement
‒ 1 0 0
0 1 1 0 1 Sign and Magnitude representation
In signed magnitude, the left-most bit is not
100012 ‒ 1002 = 011012 ans. actually part of the number, but is just the
equivalent of a +/- sign. "0" indicates that the
number is positive, "1" indicates negative.
Example
Solution:
Example
Solution:
32
One’s complement representation
Step 1: convert into 97 = 11000012
binary In one’s complement, the binary digits are
flipped.
Step 2: add zeros to = 1 11000012 (8 bits)
the left of the binary ↓
number to complete
the 8 bits.
‒ 97 Example
‒ 97 = 11100001 (8 bits sign and magnitude) Give the one’s complement representation of
100001112
Solution:
Range of values Change all zeros to ones and all ones to zeros.
‒ (2(n ‒ 1) ‒ 1) to + (2(n ‒ 1) ‒ 1).
100001112 = 011110002
Advantages
100001112 = 011110002 (one’s complement) ans.
Useful for applications that require the
magnitude to be distinct from the sign.
Example
Disadvantages
Using 8 bits, give the one’s complement
There are two ways of representing the value representation of ‒ 5410.
zero: all bits set to zero, and all bits except the
sign bit set to zero. This makes the math a bit
Solution:
confusing.
Step 1: Convert the
More importantly it is difficult to perform decimal number into 54 = 110110
binary.
arithmetic operations; we need to treat
negative operands as special cases. Step 2: Add zeros to
the left of the binary 00110110
number to complete
the number of bits.
33
Two’s complement representation
Step 3: Then change 011000102
Most widely used method of representation. all zeros to ones and
all ones to zeros. = 100111012
To get a negative number, do the one’s
complement of the binary number. Then add 1 to
Step 4: Add 1 to the binary number.
this. 1
1 0 0 1 1 1 0 1
Example 1
+
Using 8 bits, give the one’s complement 1 0 1 1 1 1 1 0
representation of NEGATIVE 67.
‒ 98 = 101111102
Solution: (Two’s complement of ‒ 9810) ans
1 0 1 1 1 1 0 0 Disadvantages:
+ 1
1 0 1 1 1 1 0 1 Requires one extra bit of storage
Solution:
34
Binary Coded Decimal (BCD)
1. They use more memory since each decimal digit requires
Another way to represent decimals in binary form four binary digits
is binary coded decimals (BCD's). BCD's are 2. Arithmetic operations are difficult to program and
binary numbers that code each decimal digit significantly slower.
separately as a four digit binary number.
Example
Solution:
Step 1: Simply write down the four bit binary pattern for
each decimal digit
1 3 6
13610 = 000100110110
(BCD representation of 13610) ans.
Example
Solution:
Step 1: Simply write down the four bit binary pattern for
each decimal digit
+ 875 = 10101000111101
‒ 942 = 1011100101000010
35
Representation of characters The EBCDIC code
PCs use a standard binary code to represents EBCDIC (Extended Binary Code Decimal
letters of the alphabet, numerals, punctuation Interchange Code) is a similar coding system used
marks and other special characters. mainly on mainframe systems.
– ASCII
– EBCDIC
36
The parity method for Example
Parity Bits
There are two methods for checking parity:
– Odd
– Even
Odd Parity
The parity checking circuit counts the number of
“1” bits and adds the parity bit to make the total
number of “1” bits an ODD number.
Even Parity
The parity checking circuit counts the number of
‘1’ bits and adds the parity bit to make the total
number of 1 bits an EVEN number.
Example
37
38