micro- computing system hardware system software system monitor program, bios operating system: dos,...

31
Micro- computi ng system Hardwar e system Softwar e system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assemble r Interpre ter Compiler Service program Machine language Assembly language High-level language Object-oriented language System softwar e Program design languag e Applicati on software Middlewar e Micro- computer main board CPU Internal memory I/O interface circuit System bus Battery, chassis peripher als

Upload: whitney-clarke

Post on 01-Jan-2016

213 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

Micro-computing system

Hardware system

Software system

Monitor program, BIOS

Operating system: DOS, Windows, UNIX, Linux

Language processing program

Assembler

Interpreter

CompilerService program

Machine language

Assembly language

High-level language

Object-oriented language

Systemsoftware

Program design language

Application software

Middleware

Micro-computer main board

CPU

Internal memory

I/O interface circuit

System busBattery,chassis

peripherals

Page 2: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

Chapter 0

Introductionto Computing

Page 3: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Page 4: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Page 5: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Binary Numbers

Each digit (bit) is either 1 or 0 Each bit represents a power of 2

MSB – most significant bit LSB – least significant bit

Page 6: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Binary Addition

Starting with the LSB, add each pair of digits, include the carry if present.

Page 7: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Hexadecimal Addition Divide the sum of two digits by the number base (16). The quotient

becomes the carry value, and the remainder is the sum digit.

36 28 28 6A42 45 58 4B78 6D 80 B5

11

21 / 16 = 1, rem 5

Page 8: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Hexadecimal Subtraction

When a borrow is required from the digit to the left, add 16 (decimal) to the current digit's value:

C6 75A2 4724 2E

-1

16 + 5 = 21

Page 9: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Translating Binary to Decimal

Weighted positional notation shows how to calculate the decimal value of each binary bit:

dec = (Dn-1 2n-1) + (Dn-2 2n-2) + ... + (D1 21) + (D0 20)

D = binary digit

binary 00001001 = decimal 9:

(1 23) + (1 20) = 9

Page 10: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Translating Unsigned Decimal to Binary

Repeatedly divide the decimal integer by 2. Each remainder is a binary digit in the translated value:

37 = 100101

Page 11: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Translating Binary to Hexadecimal

• Each hexadecimal digit corresponds to 4 binary bits.

• Example: Translate the binary integer 000101101010011110010100 to hexadecimal:

Binary 000101101010011110010100 (2) equals hex 16A794 (16)

Page 12: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Converting Hexadecimal to Decimal

Multiply each digit by its corresponding power of 16:

dec = (D3 163) + (D2 162) + (D1 161) + (D0 160)

Hex 1234(16) equals (1 163) + (2 162) + (3 161) + (4 160), or

decimal 4,660 (10)

Hex 3BA4 (16) equals (3 163) + (11 * 162) + (10 161) + (4 160),

or decimal 15,268 (10)

Page 13: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Converting Decimal to Hexadecimal

decimal 422 (10) = 1A6 (16) hexadecimal

Page 14: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Signed Integers

The highest bit indicates the sign. 1 = negative, 0 = positive

Page 15: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Forming the Two's Complement

Negative numbers are stored in two's complement notation

Page 16: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Convert signed binary to decimal

Starting value 11110000(2)

Step 1: Reverse the bits 00001111

Step 2: Add 1 to the value from step 1 00001111

+ 1

Step 3: Form the two’s complement 00010000

Step 4: Covert to decimal and attach sign -16(10)

Page 17: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Convert signed decimal to binary

Starting value -16(10)

Step 1: Convert the absolute value into binary 00010000(2)

Step 2: Reverse the bits 11101111(2)

Step 3: Form the two’s complement 11110000(2)

Page 18: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Convert signed decimal to hexadecimal

Starting value -43(10)

Step 1: Convert the absolute value into hexadecimal 2B(16)

Step 2: Form the two’s complement D5(16)

Page 19: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

Convert signed hexadecimal to decimal

Starting value D5(16)

Step 1: Form the two’s complement 2B(16)

Step 4: Covert to decimal and attach sign - 43(10)

Page 20: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.1 Numbering and Coding System

ASCII code

Standard ASCII (0 – 127)Extended ASCII (0 – 255)

A: 41Ha: 61H B: 42H

b: 62H

0: 30H1: 31H

Page 21: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.2 Digital Primer

Logic gatesAND

Digital gate diagram for AND

OR

Digital gate diagram for OR

NOT

Digital gate diagram for NOT

ANDORNOT (Inverter)XORNANDNORTri-state buffer

Page 22: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.2 Digital Primer

Logic gates

Page 23: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.2 Digital Primer

Logic gates

Page 24: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.2 Digital Primer

Logic gates

NMOS AND gate AND gate using diodes

Page 25: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.3 Inside the Computer

Some important terminology

byte word

Page 26: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.3 Inside the Computer

Some important terminology

byte word

Page 27: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.3 Inside the Computer

Internal organization of computers

Page 28: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

Arithmetic unit

Memory storage unit

Control unit

Input Device Output Device

Basic architecture of computer

Page 29: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

Instruction 1Instruction 2Instruction 3

Instruction n

data 21data 12data 117data 13

program

data

Intermediate resultsFinal results

contentaddress

No.1

No.2

The storage of program and data

Page 30: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

0.3 Inside the Computer

Internal working of computers

Page 31: Micro- computing system Hardware system Software system Monitor program, BIOS Operating system: DOS, Windows, UNIX, Linux Language processing program Assembler

Homework

P18: 4, 6 P19: 15