meljun cortes computer fundamental_very_good_lecture

38
1 COMPUTER FUNDAMENTALS COMPUTER FUNDAMENTALS Basics of computer and its operation: Functional Components and their interconnections MELJUN CORTES. MELJUN CORTES.

Upload: meljun-cortes

Post on 12-Apr-2017

523 views

Category:

Education


0 download

TRANSCRIPT

11

COMPUTER FUNDAMENTALSCOMPUTER FUNDAMENTALS

Basics of computer and its operation: Functional Components and their interconnections

MELJUN CORTES.MELJUN CORTES.

22

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSUnderlying Structure

Logical Structure of Digital Computers

Secondary

Memory

33

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSInput/Output

Secondary

Memory

44

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSInput/Output

TerminalTerminal Simpler than a PCSimpler than a PC Designed strictly for input and outputDesigned strictly for input and output Has keyboard and screenHas keyboard and screen Does not have a processorDoes not have a processor Connected to computer with Connected to computer with

telecommunication linetelecommunication line Allows user to key data directly into computerAllows user to key data directly into computer

55

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSInput/Output

TerminalTerminal Special types:Special types:

Point-of-sale (retail)Point-of-sale (retail) ATMs (banking)ATMs (banking)

66

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSInput/Output Common input methods:Common input methods:

Magnetic ink character recognition (MICR)Magnetic ink character recognition (MICR) – – used to process bank checksused to process bank checks

Optical character recognition (OCR)Optical character recognition (OCR) – directly – directly scans typed, printed, or handwritten materialscans typed, printed, or handwritten material

ImagingImaging – inputs digital form of documents – inputs digital form of documents and photosand photos

Bar code labelingBar code labeling – scans bar codes on – scans bar codes on packages or products, and reads into packages or products, and reads into computercomputer

77

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMS Common input methods:Common input methods:

Light PenLight Pen – A Light Pen is a pointing device shaped like a – A Light Pen is a pointing device shaped like a pen and is connected to a VDU. pen and is connected to a VDU. The tip of the light pen contains a light-sensitive element The tip of the light pen contains a light-sensitive element which, when placed against the screen, detects the light which, when placed against the screen, detects the light from the screen enabling the computer to identify the from the screen enabling the computer to identify the location of the pen on the screen. location of the pen on the screen.

Input/Output

http://doit.ort.org/course/input/275.htm

88

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMS Common input methods:Common input methods:

Touch Screen Touch Screen A Touch Sensitive Screen is a pointing A Touch Sensitive Screen is a pointing device that enables the user to interact with the device that enables the user to interact with the computer by touching the screen. computer by touching the screen.

Input/Output

http://doit.ort.org/course/input/275.htm

99

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSInput/Output

Common output methods:Common output methods: PrintPrint – output to paper using various types – output to paper using various types

of printersof printers Computer output microfilm (COM)Computer output microfilm (COM) – –

microfilm generated for archive copies in microfilm generated for archive copies in small spacesmall space

Voice response unitsVoice response units – computer recognizes – computer recognizes input, generates verbal response messagesinput, generates verbal response messages

1010

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSInput/Output

Multimedia – relatively new term for computer input and output in the form of text, graphics, sound, still images, animations, and/or video

Of interest …

1111

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSComputer Memory

Secondary

Memory

1212

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSComputer Memory

MemoryMemory All data flows to and from memoryAll data flows to and from memory Divided into Divided into cellscells::

Each has a unique addressEach has a unique address Memory cell types:Memory cell types:

ByteByte – stores one character of data – stores one character of data WordWord – stores two or more characters of data – stores two or more characters of data

1313

Types of MemoryTypes of Memory

P rim ary S econ d ary

M em ory

ROM RAM

SRAM DRAMPROM EPROM EAPROM EAPROM

1414

Primary MemoryPrimary Memory It is the main or internal memory . It is the main or internal memory . It can be broadly categorized into It can be broadly categorized into

two partstwo parts

RAMRAM (Random Access Memory) (Random Access Memory) ROMROM (Read Only Memory) (Read Only Memory)

1515

RAMRAM It is known as the It is known as the Read and Write Read and Write

memorymemory. This memory is . This memory is volatile. volatile.

Whatever information you store is Whatever information you store is temporarytemporary in nature and when you switch in nature and when you switch off the computer everything is erased.off the computer everything is erased.

1616

Dynamic RAMDynamic RAM Dynamic Memory is often referred to as volatile Dynamic Memory is often referred to as volatile

memory. memory. Data is stored within the capacitance of a Data is stored within the capacitance of a

transistor. The transistor. The capacitorcapacitor is unable to prevent is unable to prevent the charge from slowly discharging. This would the charge from slowly discharging. This would result in the loss of data. A solution to this result in the loss of data. A solution to this problem is the introduction of additional problem is the introduction of additional circuitry which performs a 'memory refresh' by circuitry which performs a 'memory refresh' by periodically restoring the charge. periodically restoring the charge.

Dynamic memory is Dynamic memory is cheapercheaper than Static than Static memory and is used in larger memory systems.memory and is used in larger memory systems.

1717

Static RAM Static RAM Static memory is more Static memory is more expensiveexpensive to to

produce than Dynamic memory, but produce than Dynamic memory, but because of its because of its lower power lower power consumptionconsumption it is often used in small it is often used in small to medium sized systems. to medium sized systems.

Static memory Static memory retains dataretains data within a within a cell until the data is overwritten or lost cell until the data is overwritten or lost as a result of power being shut down. as a result of power being shut down.

1818

ROMROM It is a memory unit that It is a memory unit that performs the performs the

ReadRead operationoperation only and only and does not have does not have a write capability. a write capability.

The Binary information in the The Binary information in the ROMROM is is made permanent during the hardware made permanent during the hardware production of the unit and it is not production of the unit and it is not accessible to users to store information. accessible to users to store information.

1919

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSComputer Files

Secondary

Memory

(Secondary Storage)

2020

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMS

When power is off, everything stored When power is off, everything stored in memory is lostin memory is lost

Computer files are used to store data Computer files are used to store data long termlong term

File storage devices:File storage devices: Magnetic tape drives, disk drives, floppy Magnetic tape drives, disk drives, floppy

drivesdrives Optical CD or DVD drivesOptical CD or DVD drives

Computer Files (Secondary Storage)

2121

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMS

Sequential access filesSequential access files Usually stored on magnetic tape drivesUsually stored on magnetic tape drives

Direct access filesDirect access files Stored on Direct Access Storage Devices Stored on Direct Access Storage Devices

((DASDDASD) - magnetic disk drives) - magnetic disk drives

Computer Files

2222

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMS

Types of DASDTypes of DASD Fixed (hard) drivesFixed (hard) drives

Computer Files

Figure 2.7 Diagram of a Magnetic Disk Drive

2323

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMS

Types of DASDTypes of DASD Removable:Removable:

Floppy drivesFloppy drives Zip drivesZip drives Newest: portable Newest: portable

DASD for PCs – DASD for PCs – keychain drivekeychain drive

Computer Files

Figure 2.8 Iomega’s Mini USB Keychain Drive

2424

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMS Newer type of DASDNewer type of DASD

Optical Disk StorageOptical Disk Storage

CD-ROMCD-ROM 700 megabytes700 megabytes read-onlyread-only CD-RCD-R recordablerecordable CD-RWCD-RW rewritablerewritable

DVD-ROMDVD-ROM 4.7 gigabytes4.7 gigabytes read-onlyread-only DVD-RDVD-R recordablerecordable DVD-RW DVD-RW rewritablerewritable

Computer Files

2525

Secondary MemorySecondary MemoryIt is theIt is the PermanentPermanent memory. The memory. The

information stored is permanent in information stored is permanent in nature and it uses external storage nature and it uses external storage devices like devices like Floppy disk, Magnetic Floppy disk, Magnetic disk, CD-ROM etc.disk, CD-ROM etc.

2626

Secondary Storage DevicesSecondary Storage Devices This is a floppy This is a floppy

disk! We used it to disk! We used it to store information store information and it’s main and it’s main advantage is that it advantage is that it is transportable is transportable because of its size.because of its size.

2727

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSBits and Coding Schemes

Each memory cell is a set of circuitsEach memory cell is a set of circuits Each circuit is on or off (represented by 1 or 0)Each circuit is on or off (represented by 1 or 0) Each circuit corresponds to a Each circuit corresponds to a bitbit (binary digit) (binary digit) Most computers – 8 bits (circuits) represents a Most computers – 8 bits (circuits) represents a

character (character (bytebyte)) 2 common bit coding schemes used today:2 common bit coding schemes used today:

ASCIIASCII EBCDIC EBCDIC

2828

Bits and Coding Schemes

Figure 2.4 Computer Coding Schemes

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

.

2929

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSArithmetic/Logical Unit

Secondary

Memory

3030

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMS Consists of VLSI circuits Consists of VLSI circuits

on a silicon chipon a silicon chip Carries out: Carries out:

arithmetic – add, subtract, arithmetic – add, subtract, multiply, divide …multiply, divide …

logical operations – logical operations – comparing two numberscomparing two numbers

Arithmetic/Logical Unit

3131

CPU - Registers (1 of 2)CPU - Registers (1 of 2) The CPU also contains a The CPU also contains a

small high speed small high speed memorymemory which is used to which is used to store temporary results store temporary results and control information. and control information.

This memory consists of This memory consists of a number of a number of registersregisters, , each performing a each performing a specific function. specific function.

3232

CPU - Registers (2 of 2)CPU - Registers (2 of 2) AccumulatorsAccumulators - serve the purpose of holding data - serve the purpose of holding data

used in calculations.used in calculations. Address Registers -Address Registers - are used for storing the memory are used for storing the memory

location of data or instructions to be used by a location of data or instructions to be used by a program.program.

Stack Pointer - Stack Pointer - this register is used during sub-routine this register is used during sub-routine nesting and stack based arithmetic.nesting and stack based arithmetic.

Status RegisterStatus Register - this register provides a service to - this register provides a service to the CPU by maintaining the status of the last the CPU by maintaining the status of the last operation carried out by the ALU.operation carried out by the ALU.

Instruction PointerInstruction Pointer - sometimes referred to as the - sometimes referred to as the program counter, the pointer is responsible for program counter, the pointer is responsible for retaining the memory address of the next instruction retaining the memory address of the next instruction to be executed.to be executed.

3333

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSControl Unit

Secondary

Memory

3434

BBASIC ASIC CCOMPONENTSOMPONENTS OF OF CCOMPUTER OMPUTER SSYSTEMSYSTEMSControl Unit Controls computer to take advantage of speed Controls computer to take advantage of speed

and capacity of other componentsand capacity of other components Directed by list of operations (program) that tells Directed by list of operations (program) that tells

control unit what to docontrol unit what to do decoding the instructions within a computer decoding the instructions within a computer sequencing the reading and writing of data sequencing the reading and writing of data

within the CPU and externally on the data buswithin the CPU and externally on the data bus controlling the sequence in which instructions are controlling the sequence in which instructions are

executed executed controlling the operations performed by the ALUcontrolling the operations performed by the ALU

3535

TTHEHE S STORED-TORED-PPROGRAM ROGRAM CCONCEPTONCEPT

ProgramProgram – list of what computer – list of what computer needs to do for an applicationneeds to do for an application

InstructionInstruction – each individual step or – each individual step or operation in a programoperation in a program

Control unitControl unit – carries out one step or – carries out one step or instruction at a time at electronic instruction at a time at electronic speedspeed

3636

TTHEHE S STORED-TORED-PPROGRAM ROGRAM CCONCEPTONCEPT Note:Note: One of the primary measures One of the primary measures

of power of computers is the number of power of computers is the number of instructions it can execute in a of instructions it can execute in a given periodgiven period

MIPS – millions of instructions per second executed by the control unit

MFLOPS – millions of floating point operations per second

3737Cache Memory

EEXTENSIONS TO THE XTENSIONS TO THE BBASIC ASIC MMODELODELCache Memory High-speed storage to High-speed storage to

temporarily hold data temporarily hold data from main memory from main memory waiting to be processed waiting to be processed

Entire blocks of data Entire blocks of data moved at one time into moved at one time into cachecache

Enables CPU to execute Enables CPU to execute much fastermuch faster

Also incorporated into Also incorporated into DASD controllersDASD controllers

3838

Cache memoryCache memory Cache memory is random access memory (Cache memory is random access memory (RAMRAM) that a ) that a

computer computer microprocessormicroprocessor can access more quickly than it can can access more quickly than it can access regular RAM. As the microprocessor processes data, it access regular RAM. As the microprocessor processes data, it looks first in the looks first in the cachecache memory and if it finds the data there memory and if it finds the data there (from a previous reading of data), it does not have to do the (from a previous reading of data), it does not have to do the more time-consuming reading of data from larger more time-consuming reading of data from larger memorymemory. .

Cache memory is sometimes described in levels of closeness Cache memory is sometimes described in levels of closeness and accessibility to the microprocessor. An and accessibility to the microprocessor. An L1L1 cache is on the cache is on the same chip as the microprocessor. (For example, the same chip as the microprocessor. (For example, the PowerPCPowerPC 601 processor has a 32 kilobyte level-1 cache built into its 601 processor has a 32 kilobyte level-1 cache built into its chip.) chip.) L2L2 is usually a separate static RAM is usually a separate static RAM (SRAM(SRAM) chip. The ) chip. The main RAM is usually a dynamic RAM (main RAM is usually a dynamic RAM (DRAMDRAM) chip. ) chip.

Cache that is built into the CPU is faster than separate cache, Cache that is built into the CPU is faster than separate cache, running at the speed of the running at the speed of the microprocessormicroprocessor itself. However, itself. However, separate cache is still roughly twice as fast as Random Access separate cache is still roughly twice as fast as Random Access Memory (RAM). Cache is more expensive than RAM, but it is Memory (RAM). Cache is more expensive than RAM, but it is well worth getting a CPU and motherboard with built-in cache well worth getting a CPU and motherboard with built-in cache in order to maximize system performance. in order to maximize system performance.