Session 2 Computing Components Nell Dale John Lewis

  • Slides: 78
Download presentation
Session 2: Computing Components Nell Dale • John Lewis

Session 2: Computing Components Nell Dale • John Lewis

Session Goals Begin to understand the jargon used in computing List the components and

Session Goals Begin to understand the jargon used in computing List the components and their function in a von Neumann machine Describe the fetch-decode-execute cycle of the von Neumann machine

Session Goals (cont. ) Describe how computer memory is organized and accessed Name and

Session Goals (cont. ) Describe how computer memory is organized and accessed Name and describe different auxiliary storage devices Define parallel computer configurations

Computing as a Tool Programmer / User Systems Programmer (builds tools) Applications Programmer (uses

Computing as a Tool Programmer / User Systems Programmer (builds tools) Applications Programmer (uses tools) Domain-Specific Programs User with No Computer Background 20

Computing as a Discipline Four Necessary Skills 1. 2. 3. 4. Algorithmic Thinking Representation

Computing as a Discipline Four Necessary Skills 1. 2. 3. 4. Algorithmic Thinking Representation Programming Design 21

Computer Components Consider the following ad

Computer Components Consider the following ad

Sizes in Perspective Admiral Grace Murray Hopper n A coil of wire nearly 1,

Sizes in Perspective Admiral Grace Murray Hopper n A coil of wire nearly 1, 000 feet long w Distance traveled by an electron along the wire in the space of a microsecond n A short piece of wire w In the space of a nanosecond n A bag containing grains of pepper w In the space of a picosecond

Sizes in Perspective

Sizes in Perspective

Stored-Program Concept Figure 5. 1 The von Neumann architecture

Stored-Program Concept Figure 5. 1 The von Neumann architecture

System Components Hardware n I/O devices (input/output) w keyboard, mouse, monitor, etc. n n

System Components Hardware n I/O devices (input/output) w keyboard, mouse, monitor, etc. n n n CPU Primary Storage Secondary Storage Software

Typical System Computer case Monitor Printer Speakers Modem Keyboard Mouse

Typical System Computer case Monitor Printer Speakers Modem Keyboard Mouse

Computer Components Power supply Hard drive Expansion card Expansion slot System board CD-ROM or

Computer Components Power supply Hard drive Expansion card Expansion slot System board CD-ROM or DVD-ROM Floppy disk Drive bay Central Processing Unit (CPU) Random access memory (RAM)

Processing

Processing

The Fetch-Execute Cycle Fetch the next instruction Decode the instruction Get data if needed

The Fetch-Execute Cycle Fetch the next instruction Decode the instruction Get data if needed Execute the instruction

The Fetch-Execute Cycle

The Fetch-Execute Cycle

Sample Processing Sequence Two numbers in main memory are added 1. Instruction is transferred

Sample Processing Sequence Two numbers in main memory are added 1. Instruction is transferred from memory into the CPU 2. Location of the instruction being processed is updated in the instruction counter (IC) or program counter (PC) 3. The instruction just fetched is stored in the instruction register (IR) 4. CU decodes the instruction to add two numbers • • 5. 6. 7. 8. 9. operator [operand 1], [operand 2], [operand 3] ADDW 3 first_no, second_no, answer • W = words, 3 = no of operands in the instruction Numbers are located in main memory Fetched into internal registers of the ALU by the CU Addition is carried out by ALU Sum stored in new memory location by CU The IC is updated to point to the next instruction

Memory is a collection of cells, each with a unique physical address

Memory is a collection of cells, each with a unique physical address

Computer Architecture Microprocessor (examples Pentium, Pentium II, Power. PC, etc. ) n n n

Computer Architecture Microprocessor (examples Pentium, Pentium II, Power. PC, etc. ) n n n includes Bus Interface Unit, Arithmetic & Logic Unit (ALU), Control Unit, registers motherboard is simply the main circuit board that contains most of these parts the CPU (central processing unit) is considered to be most of these parts taken as a whole Bus n n connects the microprocessor to the RAM & ROM addresses for data and instructions are important

CPU (Central Processing Unit) Processes instructions, performs calculations, and manages the flow of information

CPU (Central Processing Unit) Processes instructions, performs calculations, and manages the flow of information Performance: n CPU speed is a major factor in determining how fast a computer operates (faster the speed, faster computer operates) w Measured in gigahertz (GHz) A clock cycle relates to the clock that controls the timing in the microprocessor. w For example, a 1. 4 GHz (gigahertz) clocked microprocessor generates 1. 4 billion clock cycles per second. n Each generation of CPU is more powerful than the one before. It's clock cycles are faster at a given speed

Processing The Central Processing Unit (CPU) is the main chip in a computer n

Processing The Central Processing Unit (CPU) is the main chip in a computer n n n Processes instructions Performs calculations Manages the flow of information

Types of CPUs (Chips) Intel Pentium Processor Intel Celeron n Needs of home machines

Types of CPUs (Chips) Intel Pentium Processor Intel Celeron n Needs of home machines AMD Athlon Processor n Business and home use AMD Duron Processor n Home use VIA Cyrix Processor n Inexpensive CPU

Main Memory / Primary Storage Speeds up computer by storing data the computer has

Main Memory / Primary Storage Speeds up computer by storing data the computer has recently used n n Internal Cache: On CPU chip (L 1 or primary cache External Cache: On the system board and consists of Static RAM (SRAM chips) w Sometimes built into chip RAM – slower main memory n Each time the computer requests data from RAM, the computer places a copy of the data in memory cache w Constantly contains the most recently used data

Storage Devices Primary storage n RAM (Random Access Memory, or just “memory” for short)

Storage Devices Primary storage n RAM (Random Access Memory, or just “memory” for short) w active data that is being stored, lost if power is cut off so save often n ROM (Read-Only Memory) w commands that are permanently stored on chips w PC’s use BIOS, Macs use the Toolbox Secondary storage n n Hard disk, floppy disks Slower method of storage & retrieval but “safer”

Random Access Memory – Temporarily stores data inside a computer n n Constantly overwritten

Random Access Memory – Temporarily stores data inside a computer n n Constantly overwritten Measured in megabytes (MB) If you have limited memory or you have many programs open, your computer may need to use part of the hard drive to simulate more memory

RAM and ROM RAM stands for Random Access Memory n Inherent in the idea

RAM and ROM RAM stands for Random Access Memory n Inherent in the idea of being able to access each location is the ability to change the contents of each location ROM stands for Read Only Memory n The contents in locations in ROM cannot be changed RAM is volatile, ROM is not n This means that RAM does not retain its bit configuration when the power is turned off, but ROM does

Using Memory 1. Look through documents on your desk (internal cache) 2. Look through

Using Memory 1. Look through documents on your desk (internal cache) 2. Look through documents in your desk drawer (external cache) 3. Looking through documents in your filing cabinet (RAM) 4. Go out and get it from the trunk of your car (secondary storage)

Control Unit Control unit is the organizing force in the computer There are two

Control Unit Control unit is the organizing force in the computer There are two registers in the control unit n n The instruction register (IR) contains the instruction that is being executed The program counter (PC) contains the address of the next instruction to be executed ALU and the control unit called the Central Processing Unit, or CPU

Arithmetic/Logic Unit Performing basic arithmetic operations such as adding Performing logical operations such as

Arithmetic/Logic Unit Performing basic arithmetic operations such as adding Performing logical operations such as AND, OR, and NOT Most modern ALUs have a small amount of special storage units called registers

Input/Output Units An input unit is a device through which data and programs from

Input/Output Units An input unit is a device through which data and programs from the outside world are entered into the computer n Keyboard, the mouse, and scanning devices An output unit is a device through which results stored in the computer memory are made available to the outside world n Printers and video display terminals

Math Coprocessors A special processing unit that assists the CPU in performing certain operations.

Math Coprocessors A special processing unit that assists the CPU in performing certain operations. n A math coprocessor is a chip or part of a chip that specializes in doing math. Hardware that attaches to the motherboard or is part of the CPU. Also called numeric coprocessors or floating point units (FPU).

Flow of Information The parts are connected to one another by a collection of

Flow of Information The parts are connected to one another by a collection of wires called a bus Figure 5. 2 Data flow through a von Neumann architecture

Bus Electronic pathway that carries information between devices in a computer n Bus Width

Bus Electronic pathway that carries information between devices in a computer n Bus Width (think lanes of a highway) w 8 bits is one character n Bus Speed (think speed limit) w Measured in MHz (millions of cycles per second)

Parallel Processing

Parallel Processing

Synchronous processing One approach to parallelism is to have multiple processors apply the same

Synchronous processing One approach to parallelism is to have multiple processors apply the same program to multiple data sets Figure 5. 6 Processors in a synchronous computing environment

Pipelining Arranges processors in tandem, where each processor contributes one part to an overall

Pipelining Arranges processors in tandem, where each processor contributes one part to an overall computation Figure 5. 7 Processors in a pipeline

Peripherals

Peripherals

Ports are connectors at the back of a computer system that you use to

Ports are connectors at the back of a computer system that you use to plug in an external device. This allow instructions and data to flow between the computer and the device

Any Port in a Storm Parallel port – 25 holes; female connector; LPT 1;

Any Port in a Storm Parallel port – 25 holes; female connector; LPT 1; printer or storage devices Monitor port Keyboard port Serial port – 9 or 25 pins; male connector; COM 1; mouse or modem Game port Network port USB port n n 127 devices Printer, modem, joy stick Firewire

USB and Firewire High-speed ports that allow information to quickly transfer between a computer

USB and Firewire High-speed ports that allow information to quickly transfer between a computer and an external device n USB w Supports up to 127 device n n n USB 1. 0: 12 megabits per second USB 2. 0: 480 Mbps FIREWIRE w 63 devices at 400 Mbps w Can purchase Firewire expansion card

Storage Devices

Storage Devices

Secondary Storage Devices Because most of main memory is volatile and limited, it is

Secondary Storage Devices Because most of main memory is volatile and limited, it is essential that there be other types of storage devices where programs and data can be stored when they are no longer being processed Secondary storage devices can be installed within the computer box at the factory or added later as needed

Magnetic Disks A read/write head travels across a spinning magnetic disk, retrieving or recording

Magnetic Disks A read/write head travels across a spinning magnetic disk, retrieving or recording data Figure 5. 5 The organization of a magnetic disk

Hard Drives Magnetically stores data on rotating disks called platters Capacity is measured in

Hard Drives Magnetically stores data on rotating disks called platters Capacity is measured in bytes Speed is measured in revolutions per minute

Floppy Drives and Drives Removable media n n Can be write-protected Can be damaged

Floppy Drives and Drives Removable media n n Can be write-protected Can be damaged magnetically

Magnetic Tape The first truly mass auxiliary storage device was the magnetic tape drive

Magnetic Tape The first truly mass auxiliary storage device was the magnetic tape drive Figure 5. 4 A magnetic tape

Tape Drive Backup helps you copy files to tape cartridges Try to find a

Tape Drive Backup helps you copy files to tape cartridges Try to find a drive that can store the entire contents of your hard drive

Removable Storage Devices Jazz Drive – 2 GB Zip Drive – 250 MB LS-120

Removable Storage Devices Jazz Drive – 2 GB Zip Drive – 250 MB LS-120 Drive – 120 MB

Compact Disks A CD drive uses a laser to read information stored optically on

Compact Disks A CD drive uses a laser to read information stored optically on a plastic disk CD-ROM is Read-Only Memory DVD stands for Digital Versatile Disk

CD-ROM (Read-only memory) - can’t be changed 650 Mb of data n n Equal

CD-ROM (Read-only memory) - can’t be changed 650 Mb of data n n Equal to entire set of encyclopedias 400 Floppy disks Speed determines how fast a disk spins n Look for 48 X Speed of CD-ROM drive is the transfer rate n In Kb (e. g. 3600 Kbs)

CD-R & CD-RW Drives CD-R (Compact Disc – Recordable) n Permanent store; not erasable

CD-R & CD-RW Drives CD-R (Compact Disc – Recordable) n Permanent store; not erasable CD-RW n n n Can be erased and rewritten Read / Write and Re-write speeds Usually 74 minutes Special software needed to record onto a disk n Referred to as burning a CD

DVD-ROM Drive DVD – Digital Versatile Disk n n Generally cannot change the information

DVD-ROM Drive DVD – Digital Versatile Disk n n Generally cannot change the information stored on a disk Similar to CD but stores more information Speed determines transfer rate (6 X) Capacity w w 1 1 2 2 side / 1 layer – 4. 7 GB side / 2 layer – 8. 5 GB sides / 1 layer – 9. 4 GB sides / 2 layers – 17 GB

Input and Output

Input and Output

Input Devices Keyboards Mice n n Trackballs Pointing Devices

Input Devices Keyboards Mice n n Trackballs Pointing Devices

Scanners A scanner is a device that reads images and text into a computer

Scanners A scanner is a device that reads images and text into a computer n n Optical Character Recognition (OCR) software that places scanned text into a document that can be edited in a word processor Color depth is measured in bits and indicates the number of colors a scanner can detect

Resolution determines the amount of detail a scanner can detect w Ranges from 600

Resolution determines the amount of detail a scanner can detect w Ranges from 600 dpi to 2400 dpi w You usually don’t need to scan at a higher resolution than a printer can produce or a monitor can display n n Most monitors are 72 dpi Printers vary

Output Devices

Output Devices

Printers Speed of a printer is measured in pages per minute (PPM). A higher

Printers Speed of a printer is measured in pages per minute (PPM). A higher speed represents faster output Resolution determines the quality of images n n A higher resolution results in sharper images Printer resolution is measured in dots per inch (dpi) w 600 dpi is acceptable; 1200 is better for images n Resolution expressed with two numbers represents dots per inch across and down

Types of Printers Ink-jet: has a print head that sprays ink through tiny nozzles

Types of Printers Ink-jet: has a print head that sprays ink through tiny nozzles onto a page n n n 2 to 10 pages (ppm) 360 to 2400 dots per inch Color printers spray cyan, magenta, yellow and black to create different colors Laser-printer n n n Works like a photo copier Speed of 4 to 16 pages Have a CPU 600 to 2400 Memory – 2 mb to 8 Mb

Print Buffer and Spoolers Printer buffer: section of memory printer stores information waiting to

Print Buffer and Spoolers Printer buffer: section of memory printer stores information waiting to print Printer spooler: program on your computer that stores information waiting to print n n Stores more information than the buffer One spooler for each connected printer

Monitors Video cards translate instructions from the computer into a form Most computes the

Monitors Video cards translate instructions from the computer into a form Most computes the monitor can understand n require at least 2 mb of video card memory

Monitor Metrics The smaller the dot pitch, the crisper the image n 0. 28

Monitor Metrics The smaller the dot pitch, the crisper the image n 0. 28 mm is acceptable Refresh rate is measured in hertz (Hz) n n Times per second computer redraws the image 72 Hz or more is acceptable

Communications Modems let a computer exchange information through telephone lines Speed of a modem

Communications Modems let a computer exchange information through telephone lines Speed of a modem determines how fast it sends and receives messages n 56, 000 bps (56 Kbps) w V. 90 standard: receive 56 K and send 33. 6 K n Speed at which information flows depend on the quality of the phone line

High-speed Connections ISDN – Integrated Services Digital Network n n Digital phone line 56

High-speed Connections ISDN – Integrated Services Digital Network n n Digital phone line 56 Kbps to 128 Kbps Cable Modem n n Same cable as TV 4000 Kbps DSL – Digital subscriber line n n High speed digital phone line 1000 – 6000 Kbps

Operating Systems

Operating Systems

Operating Systems Software that controls the overall activity of the computer n n Ensure

Operating Systems Software that controls the overall activity of the computer n n Ensure that all of the parts of the computer work together smoothly Functions: w Control hardware w Run software w Manage information n Programs that run on one operating system platform do not generally run on others

Software: Systems Software Operating systems n n Controls the hardware components (disks, CPU, printers,

Software: Systems Software Operating systems n n Controls the hardware components (disks, CPU, printers, etc. ) Windows XP, Windows NT/2000, Windows 9 -X, MS-DOS, OS/2, Mac. OS, Unix, Linux, Be. OS

Types of Operating Systems MS-DOS w Command driven Windows n n n Windows Windows

Types of Operating Systems MS-DOS w Command driven Windows n n n Windows Windows UNIX MAC OS 3. 1 9 X (95, 98) ME XP NT 2000

Unix Can run single computer or entire network Developed on mainframes in late ’

Unix Can run single computer or entire network Developed on mainframes in late ’ 60’s True multi-tasking OS Most widely used operating system on Internet

LINUX Unix-based system offered as freeware on the Internet

LINUX Unix-based system offered as freeware on the Internet

Software

Software

Software System software runs the machine Application software helps you accomplish specific tasks Manufacturers

Software System software runs the machine Application software helps you accomplish specific tasks Manufacturers also may create minor software updates called patches, to make corrections or improvements to software

Utility Programs Utility: A program that performs a specific task on your computer n

Utility Programs Utility: A program that performs a specific task on your computer n n n Norton utilities: recover files Virusscan: anti-virus software Acrobat Reader: View PDF (Portable Document Format) files Winfax pro Via. Voice – Speech recognition Win. Zip – Compress and decompress files

Application Software: Word processor Spreadsheets Presentation Software Database Software Internet Software

Application Software: Word processor Spreadsheets Presentation Software Database Software Internet Software

Software: Application Software Office products n n Word processors Spread sheets Presentation software Email

Software: Application Software Office products n n Word processors Spread sheets Presentation software Email Business applications n n General ledger Financials w Accounts payable w Accounts receivable n n HRMS Fixed assets/inventory

Database Programs Helps you manage large collections of related information Uses n n n

Database Programs Helps you manage large collections of related information Uses n n n Store information Find information Analyze and print information

Databases Organized in: n Tables w Collection of information about a specific topic n

Databases Organized in: n Tables w Collection of information about a specific topic n Field w Category of information n Record w Single instance of information

Programming Software Text Editor n Used by the programmer while coding the program in

Programming Software Text Editor n Used by the programmer while coding the program in a programming language w Like a word processor - creates a text file containing the program's instructions or "source code" n n Examples are “nled” and “vi” editors in Unix systems Other editors are Note. Pad and Word. Pad which are text-based

Programming Software Interpreters n Translates source code into machine code line by line Compiler

Programming Software Interpreters n Translates source code into machine code line by line Compiler n Translates source code into an object file, than uses linker to create an executable file w A source module (source code) becomes an "object" module (compiled module) w Then it is linked with system modules to become a "load" module (linked module) It is usually more efficient to use a compiler