Anda di halaman 1dari 8

INTERNAL ARCHITECTURE OF 8086 BY:- AMANDEEP REG.11000597 data with which the computer is going to be working.

Input/Output The input/output or I/O section allows the computer to take in data from the outside world or send data to the outside world. Peripherals such as keyboards, video display terminals, printers and modems are connected to the I/O section. These allow the user and the computer to communicate with each other. The actual physical devices used to interface the computer buses to external systems are often calledports.

ABSTRACT This project work on micro processor takes account of INTERNAL ARCHITECTURE OF 8086 MICRO PROCESSOR by taking into concentration about all the aspects of 8086. Computers The major parts are the central processing unit or CPU, memory and the input and output circuitry or I/O and three sets of parallel lines called Buses connecting these parts together. The three buses are called address bus, data bus and control bus

Central Processing Unit The Central Processing unit or CPU controls the operation of the computer. It fetches the binary-coded instructions from memory, decodes the instructions into a series of simple actions and carries out these instructions. The CPU contains an arithmetic and logic unit or ALU which can perform arithmetical and logical calculations like add, subtract, AND, OR, etc., The CPU also contains an address counter which is used to hold the address of the next instruction to be fetched from the memory, general purpose registers which are used for

Memory The memory section usually consists of RAM and ROM. It may also havemagnetic floppy disks, magnetic hard disks or laser option disks. Memory has twopurposes. The first purpose is to store the binary codes for the sequence of instructionsyou want the computer to carryout. The second purpose of the memory is to store thebinary-coded

temporary storage of binary data, and circuitry which generates and the control bus signals. Address Bus The address bus consists of 16, 20, 24 or more parallel signal lines. On these linesthe CPU sends out the address of the memory location that is to be written to or readfrom. The number of memory locations that the CPU can address is determined by thenumber of address lines. If the CPU has Naddress lines then it can directly address 2Nmemory locations. For example, a CPU with 16 address lines can address 216 or 65, 536memory locations. Data Bus The data bus consists of 8, 16, 32 or more parallel signal lines. The data bus lines arebi- direct ional. Control Bus The control bus consists of 4 10 parallel signal lines. The CPU sends out signalson the control bus to enable the outputs of addressed memory devices or port devices.Typical control bus signals arememory/read, memory write , I/O read, and I/O write. Toread a byte of data from a memory location, for example, the CPU sends out the addressof the desired byte on the address bus and then sends out a memory read signal on thecontrol bus. The memory read signal enables the addressed memory device

to output thebyte of data on the data bus where it is read by the CPU. Hardware, Software, and Firmware When working around computers you hear the terms hardware, software andfirmware.H ardware is the name given to the physical devices and circuitry of thecomputer.S of tware refers to the programs written for the computer.Fir mware is the termgiven to the programs stored in ROMs or in other devices which keep their storedinformation when the power is turned off.

What is a Microprocessor ? The entire CPU with timing and control functions on a single chip is known asMicroprocessor. Therefore a Microprocessor or MPU is an integrated circuit that containsmany processing capabilities of a large computer. Microprocessor Evolution A common way of categorizing is by the number of bits that their ALU can workwith at a time. A Microprocessor with a 4 - bit ALU will be referred to as a 4-bitMicroprocessor, regardless of the number of address lines or the number of data bus linesthat it has. The first microprocessor was the Intel 4004 produced in 1971. This 4004 was a4 - bit device

intended to be used with some other devices in making a calculator .Somelogic designers, however, saw that this device could be used to replace PC boards full ofcombinationaland sequential logic devices. Also, the ability to change the function of asystem by just changing the programming, rather than redesigning the hardware, is veryappealing. It was these factors that pushed the evolution of microprocessors. In 1972Intel come out with the 8008 which was capable of working with 8-bitwords. In 1974 Intel announced the 8080 which had a much larger instruction set than8008. The 8080 is referred to as a second-generation microprocessor. Soon after Intel produced 8080, Motorola came out with MC 6800, another 8-bitgeneral purpose CPU. Some of the other competitors were the MOS technology 6502 andthe Zilog Z80. The 16-bit microprocessors entered the marketplace in the late 1970s andearly 1980s. Then came the 32-bit processors.

written for the8080/8085 to be easily converted to run on the 8086. The word 16-bit means that its arithmetic logical unit, internal registers, and mostof its instructions are designed to work with 16-bit binary words. The 8086 has a 16-bitdata bus, so it can read data form or write data to memory and ports either 16-bits or 8-bits at a time. The 8086 has a 20-bit address bus, so it can address any one of220 or1,048,576 memorylocations. Each of the 1,048,576 memory addresses of the 8086represents a bytewide location. Words will be stored in two consecutive memorylocations. If the first byte of a word is at an even address, the 8086 can read the entireword in one operation. If the first byte of the word is at an odd address, the 8086 will readthe first byte of the word in one operation, and the second byte in another operation.

The INTEL 8086 Microprocessor Introduction The 8086 was the first 16-bit Microprocessor to be introduced by IntelCorporation. It is designed to be upwardly compatible with the older 8080/8085 series of8-bit microprocessors. The upward compatibility allows programs INTERNAL ARCHITECTURE OF 8086

capacity in order to speedup operations. This function is carried in twoways. First, by fetching the instructions before they are needed by the execution unit andstoring them in the instruction queue, the 8086 MPU is able to increase computing speed.Second, by taking care of all bus-control functions, the EU is free to concentrate onprocessing data and carrying out the instructions. The instruction pointer contains thelocation or address of the next instruction to be executed. ( INTERNAL BLOCK DIAGRAM ) Parts of the diagrams are discussed below :Execution unit (EU) The EU is where the actual processing of data takes place inside the 8086 MPU. Itis here that the arithmetic and logic unit (ALU) is located, along with the registers used tomanipulate data and store immediate results. The EU accepts instructions and data thathave been fetched by the BIU and then processes the information. Data processed by theEU can be transmitted to the memory or peripheral devices through the BIU. ALU The ALU is the calculator part of the execution unit. It consists of electroniccircuitry that performs arithmetic operations or logical operations on the binaryrepresented electrical signals. The control system for the execution unit can also bethought of as part of ALU. It provides a path for the flow of instructions into the ALU,the general registers, and the flag register. Flag Register Aflag is a flip-flop which indicates some condition produced by the execution ofan instruction or controls certain operations of the EU. The Flag Register is a specialregister associated with the ALU. A 16-bitflag register in the EU contains nine activeflags. Fig.5 shows the location of the nine flags in the flag register.

Bus Interface Unit (BIU) The BIU is made up of theaddress generation and bus-control unit, the instruction queue, and the instruction pointer. It has the task of making sure that the bus is used to its fullest

Stack Pointer Register A Stack, is a section of memory set aside to store addresses and data while asubprogram is being executed. An entire 64 K bytes segment is set aside as Stack in 8086MPU. The upper 16 bits of the starting address for this segment is kept in the stacksegment register. The Stack Pointer (SP) register contain the 16-bit offset from the start ofthe segment to the memory location where a word was most recently stored on the Stack.The memory location where a word was most recently stored is called the top of Stack. Bus control The bus-control unit performs the bus operations for the MPU. It fetches andtransmits instructions, data and control signals between MPU and the other devices of thesystem. Instruction Queue The instruction queue is used as a temporary memory storage area for datainstructions that are to be executed by the MPU. The BIU, through thebus-control unit,prefetches instructions and stores them in the instruction queue. This allows the executionunit to perform its calculations at maximum efficiency. Because the BIU and EUessentially operate independently, the BIU concentrates on loading instructions into theinstruction queue. This usually takes more time to do than the calculations performed bythe

execution unit. In effect, the BIU and the EU work in parallel. The instruction queue isaf irst- in, f irst- out (FIFO) memory. This means that the first instruction loaded into theinstruction queue by the bus control unit will be the first instruction to be used the ALU.

BUS A Bus is a group of common wires in which signals travel. The three types of buses used are the Address Bus, the Data Bus and the control Bus. Address Bus An address is a unique location in memory. It is like a mailbox in the post office,where each mail box has its own unique number to identify its location. An address busconsists of 16,20,24 ormore parallel signal lines. On these lines the CPU sends out theaddresses of the memory location that is to be written to or read from. The total numberof memory locations is determined by the number or address lines. In the8086 theaddress is determined bya 20-bit number. This gives us 220 possible address locations, or1,048,576 bytes of memory. An address bus is made up of 20 wires, or conductors, labeledA0 through A19 ,with A0 as the LSB and A19 as the MSB. It is used to locate or find information inmemory. It is also used to define a location in memory where information is to be stored.The address bus is some times used to identify

which I/O port is used for input/outputoperations. Data Bus A data bus is used to move information ( data and instruction ) from the MPU tomemory and other devices. This is referred to as a write operation. The data bus is alsoused to receive information into the MPU. This is called as a read operation. Because thedata bus receives and transmits information, it is known as abi - directional bus. However,it cannot receive and transmit dataat the same time. The Intel8086 has a 16-bit data bus labeled D0 to D15, where D0 is the LSB andD15 is the MSB. The 8086 microprocessor multiplex the address and data buses.Multiplexing is the process of using the same wires or pins to do different things atdifferent times. When acting as a data bus, the signal lines carry read/write information formemory or input/output information for I/O devices. When acting asan address bus, thesame signal lines are used to locate information. Control Bus The CPU sends out signals on the control bus to enable the outputs of addressedmemory devices or port devices. The control line determines the sequence of operations tobe performed. The control bus consists of 4 to 10 parallel signal lines. Typical control bussignals are memory read,

memory write, I/O read, and I/O write. To reada byte of datafrom a memory location, for example, the CPU sends out the address of the desired byteon the address byte and then sends out a memory read signal on the control bus. Thememory read signal enables the addressed memory device to output the byte of data on tothe data bus where it is required by the CPU.

RAM & ROM, ADDRESSING MODES & CONTEXT SWITCHING Memory A memory stores large number of binary words. Since the early 1970s, ICs or semiconductor memory have been the most widely used type of primary memory found inmicro computers. The simplest form of computer memory is the basicflipflop and a flip-flop is called a memory cell which can be used store a single bit ( 0 or 1). 8 or 16 cells areconnected together to form a memory byte or memory word. Each memory byte or wordhas a unique location in the memory called ana d dress. Therefore, memory is a placewhere data bits ( 0 or 1) can be stored and then later retrieved when the computer needsit. The process of storing data into the memory is calledwrit i n g. Theprocess of retrievingdata from the memory is calledre ad i n g. Accordingly, we saythat a microprocessor is in

a write cycle or performing a write operation when it is storing data into memory. The process by which a microprocessor retrieves data from memory is called a read cycle or read operation. Memory classification Memory can be classified into three general types,ROM andRAM. ROM standsfor read- only memory. ROM generally contains permanently stored data that cannot bechanged. It can be read but not written into. The main feature of ROMs is that they are non-volatile, which meansthat the information stored in them is not lost when the power is removed. RAM, on the other hand, is memory that can be read from or written to. RAMstands for random-access memory, but since ROMs are also random access, the majordifference is that RAM is memory thatcan be read or written to. RAM is actuallyread/write memory. RAMmemory is volatile memory, that is, it is lost whenever thepower is switched off. ROM ROMs can be classified into three general types. A maskable ROM is a ROMthat is programmed with information or data by the manufacturer. Once programmed these data bits cannot be altered or changed. A programmable ROM, orPROM, is a device that

can be programmed by a user. Once programmed, the data in a PROM, like a ROM, cannot be altered or changed . An erasable PROM, orEP ROM,is a type of ROM that can be programmed by an user but whose data may be erased or changed with use of specialized equipment. RAM RAM or read/write memory, is a type of volatile memory from which data can be read and into which data can be written. RAM can be classified as eitherStatic or dynamic. A Static RAM is essentially a matrix of flipflops. Therefore, we can write a new data word in a RAM location at any time by applying the word to the flip-flop data inputand clocking the flip-flops. The stored data word will remain on the flip-flop outputs aslong asthe power is left on.

Addressing Modes The different ways that a processor can access data are referred to as its addressing modes. It is the way by which the location of the operand is determined. How an operand is addressed in a program dependson the types and location of the data. There are three general types of addressing modes: Immediate addressing modes.

Register addressing modes.

What is an interrupt ? Aninterrupt is the method of accessing the MPU by a peripheral device. Aninterrupt is used to cause a temporary halt in the execution of a program. The MPUresponds to the interrupt with an interrupt service routine, which is a short program orsubroutine that instructs the MPU on how to handle the interrupt. When the 8086 is executing a program, it can get interrupted because of one of the following. 1.Due to an interrupt getting activated. This is called as hardware interrupt. 2.Due to an exceptional happening during an instruction execution, such as division of a number by zero. This is generally termed asexceptions orTra ps. 3.Due to the execution of an Interrupt instruction like "INT 21H". This is called a Software interrupt.

REFRENCE http://www.scribd.com/doc/97 55070/Microprocessor-8086 http://www.scribd.com/doc/26 677766/8086-MicroprocessorArchitecture http://www.scribd.com/search ? cat=redesign&q=microproces sor+8086&x=0&y=0 http://www.scribd.com/doc/97 55070/Microprocessor-8086