μComputer Structure μProcessor Memory Bus System I/O Ports
PPI (INTEL) 8255, PIA (MOTOROLA) 6821 I Port O Port Thermocouple Amplifier AD Converter Temperature mV V Word DA Converter Driving Circuit Valve Word V Hydraulic or Electric Signal Flow Control
Memory memory address content FFFFF H H H H F1 H 29 H D5 H 00 H 23 H 78 H Address Space 8 bits20 bits Volatile: RAMs (R,W) Non-volatile: ROM, PROM, EPROM, EEROM
The μProcessor The 8086 or 8088 μP Available in 40 Pins DIP Performs arithmetic and logical operations Decodes program instructions Controls the μComputer operation Contains some memory μP = CPU
The System Bus Address Bus Data Bus Control Bus The address bus contains 16 unidirectional lines The data bus contains 8 bidirectional lines The control bus is made of individual lines that are unidirectional in most of the cases, but sometimes are bidirectional
Program Execution μPμPmemory Address Bus Data Bus Program counter Address decoder Instructions & data Instruction register Instruction decoder
μP History bit Word8080INTEL bit Word4040INTEL bit WordTMS1000Texas Instruments bit WordF8Fairchild bit Word6800MOTOROLA bit Word6502COMMODORE bit Word8085ÌNTEL bit WordZ80ZILOG bit Word8086INTEL bit Word8088INTEL bit Word68000MOTOROLA
Introduction to μP Microprocessors and Peripherals Brey Merrill ISBN: X
How A 16 bit word is stored in 2 consecutive 8 bit memory locations ABCD H H H CD H AB H
Software Model of the 8086 or 8088 μP 8086 or 8088 μP AH BH CH DH AL BL CL DL Data Registers Segment Registers CS DS SS ES Index Registers SI DI Pointer Registers SP BP IP Instruction Pointer SR Status register 9 bits AX BX CX DX
XXXX0 H Memory Segmentation CS DS SS ES Code Segment Data Segment Stack Segment Extra Segment H FFFFF H 64KB XXXX0 H Physical Address
Dedicated and General Use of Memory 0H0H 7F H 80 H FFFEF H FFFFF H 128 Bytes to store pointers to interrupt service routines Each pointer requires 4 memory locations Open memory reserved 12 Bytes
Physical &Logical Addresses H H H H H H H H H H 0280A H 0280B H Physical Address Segment Base Offset 000B H Logical Address 0280 H :000B H 0280B H
Address of the next instruction to be executed Instruction Pointer 1234 H + Code Segment 8888 H Physical address 89AB4 H Logical address 8888 H :1234 H H H = 89AB4 H General purpose registers AX BX CX DX Accumulator register Base register Count register Data register
Pointer & Index Registers SP BP Stack pointer Base pointer SS:SP points to the top of the stack The top of the stack is the next stack location that can accessed SS:BP is used in the based addressing mode SS:BP can be used to examine the values of the parameters passed to a subroutine and held in the stack SI DI Source index Destination index DS:SI DS:DI Indexed type of addressing For indexing source or destination addresses
Status Register CFPFAFZFSFOFIFDFTF Control flagsStatus flags carry parity auxiliary carry zero sign overflow trap direction Interrupt enable CY, NC