This document discusses the basic hardware features of the PC, including the processor, memory, registers, keyboard, monitor, disk drives, and other external components. It explains bits and bytes as the fundamental units of digital information storage. Various number systems are covered, including binary, decimal, hexadecimal, and how to convert between them. Storage sizes and numeric data representation in computers are also summarized.
How to Troubleshoot Apps for the Modern Connected Worker
Class2
1. IBM PC Assembly Language and Programming by Peter AbelChapter 1: Basic Feature of PC hardware Mohammed Nazimuddin(나짐) Email:nazim@eslab.inha.ac.kr 1210 Hi-tech centre.
2. Hardware Features Internal Hardware Processor Memory Register External hardware Keyboard Monitor Disk CD-ROM
3. Bits and Bytes Bits The fundamental building block of computer storage is Bit. A bit may be Off 0 On 1
4.
5. Related Bytes Word 2-Byte(16-bit) Double Word 4-Byte(32-bit) Quadword 8-Byte(64-bit) Paragraph 16-byte(128) Kilobyte(KB) Megabyte(MB)
18. Numeric Data Binary storage two’s complement, one’s complement, sign and magnitude, or biased representations ASCII storage sequence of ASCII bytes representing the digits of the number expressed in some radix Binary Coded Decimal sequence of nybbles representing digits 0-9 of the number
19. Binary Storage A pre-arranged storage size is used typically byte, word, doubleword, or quadword Represent a number in base two and encode the bits 197d is 11000101b at least 8 bits will be required to store this number (leading zeros are added if necessary to fill additional bits for larger storage sizes)
46. Negative Binary Number A negative binary value is expressed in Two’s complement notation. Two’s complement Reverse the bit Add 1 Example: +65 Reverse bits Add 1 Number -65 01000001 10111110 1 10111111
47. Subtraction How to Subtract 42 from 65 ? 65 : +(-43) : = 22
48. PC Components System Board Processor, main memory, connectors, hard disk, etc… Bus A bus with wires attached to the system board connects the components. Processor 8088,8086,80286….Pentium Execution and Bus control unit
49. Execution and Bus control Unit EU: Execution Unit BIU: Bus interface Unit Program control Instruction Queue . .
50. Intel 8086 Organization Registers - storage locations found inside the processor for temporary storage of data Data Registers (16-bit) AX, BX, CX, DX Address Registers (16-bit) Segment registers: CS, SS, DS, ES Pointer registers: SP, BP, IP Index registers: SI, DI Status (Flags) register (16-bit)
51. Data Registers The data registers may be used for general purposes, however each has special uses AX : Accumulator BX : Base CX : Count DX : Data Each byte of the 4 data registers can be accessed independently AH, AL, BH, etc. These are referred to as 8-bit registers, but remember they are part of an existing register
52. Memory 8086 - 1 megabyte of memory (220 bytes) Each byte is accessed by specifying an address (00000h through FFFFFh) 20-bit addresses must be formed from 16-bits of information
54. Segment Registers 20-bit addresses are obtained by combining two 16-bit registers, segment:offset Address = segment*16(10h)+offset Example CS: 010C IP: 14D2 Address = 010C*10+14D2 = 010C0+14D2 Address = 02592 Each segment is 64K, segments can start at any paragraph boundary
55. Program Segments During program execution, the segment registers are only changed if memory not currently accessible in an active segment must be accessed Program bytes are arranged into distinct segments for convenience CS -> segment containing machine instructions SS -> segment containing storage for the stack DS -> segment containing data values and storage ES -> segment for additional data or special memory operations Programmers must be aware of this organization
56. Instruction and Stack Pointers IP contains the address of the next instruction to be executed IP specifies an offset into the CS segment IP is not the operand of any instruction SP points to the top item on the stack SP is an offset into the SS segment SP can be used as an operand in some instructions
57. BP and Index Registers BP is a Base Pointer Specifies an offset into any segment, but most commonly the Stack segment SI and DI are called Index registers They normally specify an offset into the Data segment, although they can be used as offsets into any segment Sometimes they hold a number to be added to the address of an array (index)
58. Flags Individual bits are used to store the status of the microprocessor Bits are set or cleared as the result of many operations Bits may be affected indirectly (by the execution of an instruction) or directly by an instruction designed to access the status word.