8051 Microcontroller Interfacing With External Memory Pdf
- 8051 Microcontroller Interfacing With External Memory Pdf Free
- 8051 Microcontroller Interfacing With External Memory Pdf
As discussed in Chapter 1, the 8031 chip is a ROMless version of the 8051. In other words, it is exactly like any member of the 8051 family such as the 8751 or 89C51 as far as executing the instructions and features are concerned, but it has no on-chip ROM. Therefore, to make the 8031 execute 8051 code, it must be connected to external ROM memory containing the program code. In this section we look at interfacing the 8031 microcontroller with external ROM. Before we discuss this topic, one might wonder why someone would want to use the 8031 when they could buy an 8751, 89C51, or DS5000.
The reason is that all these chips have a limited amount of on-chip ROM. Therefore, in many systems where the on-chip ROM of the 8051 is not sufficient, the use of an 8031 is ideal since it allows the program size to be as large as 64K bytes. Although the 8031 chip itself is much cheaper than other family members, an 8031-based system is much more expensive since the ROM containing the program code is connected externally and requires more supporting circuitry, as we explain next.
Enhanced 8051 Architecture. – Single Clock Cycle per Byte Fetch. – 12 Clock per Machine Cycle Compatibility Mode. – Up to 20 MIPS Throughput at 20 MHz Clock Frequency. – Fully Static Operation: 0 Hz to 20 MHz. – On-chip 2-cycle Hardware Multiplier. – 256 x 8 Internal RAM. – External Data/Program Memory Interface. THE 8051/8052 MICROCONTROLLER Architecture, Assembly Language, and Hardware Interfacing Craig Steiner Universal Publishers Boca Raton, Florida.
First, we review some of the pins of the 8031/51 used in external memory interfacing. See Figure 14-7.
EA pin As shown in Chapter 4, for 8751/89C51/DS5000-based systems, we connect the EA pin to V cc to indicate that the program code is stored in the microcontroller’s on-chip ROM. To indicate that the program code is stored in external ROM, this pin must be connected to GND.
This is the case for the 8051-based system. In fact, there are times when, due to repeated burning and erasing of on-chip ROM, its UV-EPROM is no longer working. In such cases one can also use the 8751 (or 89C51 or any 8051) as the 8031. All we have to do is to connect the EA pin to ground and connect the chip to external ROM containing the program code.
Since the PC (program counter) of the 8031/51 is 16-bit, it is capable of accessing up to 64K bytes of program code. In the 8031/51, port 0 and port 2 provide the 16-bit address to access external memory.
Of these two ports, PO provides the lower 8 bit addresses AO – A7, and P2 provides the upper 8 bit addresses A8 – A15. More importantly, PO is also used to provide the 8-bit data bus DO – D7. In other words, pins PO.O – P0.7 are used for both the address and data paths. This is called address/data multiplexing in chip design. Of course the reason Intel used address/data multiplexing in the 8031/51 is to save pins.
How do we know when PO is used for the data path and when it is used for the address path? This is the job of the ALE (address latch enable) pin.
8051 Microcontroller Interfacing With External Memory Pdf Free
ALE is an output pin for the 8031/51 microcontroller. Therefore, when ALE = 0 the 8031 uses PO for the data path, and when ALE = 1, it uses it for the. In all our examples of 8051-based systems so far, we used either the on-chip ROM or the off-chip ROM for the program code. There are times that we want to use both of them. Is this possible? The answer is yes.
For example, in an 8751 (or 89C51) system we could use the on-chip ROM for the boot code, and an external ROM (using NV-RAM) will contain the user’s program. In this way, the system boot code resides on-chip and the user’s programs are downloaded into off-chip NV-RAM. In such a system we still have EA = V cc, meaning that upon reset the 8051 executes the on-chip program first; then, when it reaches the end of the on-chip ROM it switches to external ROM for the rest of the program code. Many 8051 trainers are designed using this method.
Again, notice that this is done automatically by the 8051. For example, in an 8751 (89C51) system with both on-chip and off-chip ROM code where EA = V cc, the controller fetches opcodes starting at address 0000, then goes on to address OFFF (the last location of on-chip ROM). Then the program counter generates address 1OOOH and is automatically directed to the external ROM containing the program code. See Examples 14-7 and 14-8. Figure 14-12 shows the memory configuration.
8051 Microcontroller Notes. 1. Narasimha Murthy.Ph.D yayavaram@yahoo.com INTEL 8051 MICRCONTROLLERIntroduction:A decade back the process and control operations were totally implemented by theMicroprocessors only. But now a days the situation is totally changed and it is occupied by thenew devices called Microcontroller. The development is so drastic that we can’t find anyelectronic gadget without the use of a microcontroller.
This microcontroller changed theembedded system design so simple and advanced that the embedded market has become one ofthe most sought after for not only entrepreneurs but for design engineers also.What is a Microcontroller? A single chip computer or A CPU with all the peripherals like RAM, ROM, I/O Ports,Timers, ADCs etc. On the same chip. For ex: Motorola’s 6811, Intel’s 8051, Zilog’s Z8 andPIC 16X etcMICROPROCESSORS & MICROCONTROLLERS:Microprocessor:A CPU built into a single VLSI chip is called a microprocessor.
It is a general-purpose deviceand additional external circuitry are added to make it a microcomputer. The microprocessorcontains arithmetic and logic unit (ALU), Instruction decoder and control unit, Instructionregister, Program counter (PC), clock circuit (internal or external), reset circuit (internal orexternal) and registers.
But the microprocessor has no on chip I/O Ports, Timers, Memory etc.For example, Intel 8085 is an 8-bit microprocessor and Intel 8086/8088 a 16-bit microprocessor.The block diagram of the Microprocessor is shown in Fig.1 1. Fig.1 Block diagram of a Microprocessor.MICROCONTROLLER:A microcontroller is a highly integrated single chip, which consists of on chip CPU (CentralProcessing Unit), RAM (Random Access Memory), EPROM/PROM/ROM (ErasableProgrammable Read Only Memory), I/O (input/output) – serial and parallel, timers, interruptcontroller. For example, Intel 8051 is 8-bit microcontroller and Intel 8096 is 16-bitmicrocontroller. The block diagram of Microcontroller is shown in Fig.2. 2. Fig.2.Block Diagram of a Microcontroller 3.
8051 Microcontroller Interfacing With External Memory Pdf
Distinguish between Microprocessor and MicrocontrollerS.No Microprocessor Microcontroller1 A microprocessor is a general A microcontroller is a dedicated chip which purpose device which is called a is also called single chip computer. CPU2 A microprocessor do not contain A microcontroller includes RAM, ROM, onchip I/OPorts, Timers, Memories serial and parallel interface, timers, interrupt etc. Circuitry (in addition to CPU) in a single chip.3 Microprocessors are most Microcontrollers are used in small, commonly used as the CPU in minimum component designs performing control-oriented applications. Microcomputer systems4 Microprocessor instructions are Microcontroller instructions are both bit mainly nibble or byte addressable addressable as well as byte addressable.5 Microprocessor instruction sets are Microcontrollers have instruction sets mainly intended for catering to catering to the control of inputs and large volumes of data. Outputs.6 Microprocessor based system Microcontroller based system design is design is complex and expensive rather simple and cost effective7 The Instruction set of The instruction set of a Microcontroller is microprocessor is complex with very simple with less number of large number of instructions.
For, ex: PIC microcontrollers have only 35 instructions.8 A microprocessor has zero status A microcontroller has no zero flag. FlagEVOLUTION OF MICROCONTROLLERS: 4. The first microcontroller TMS1000 was introduced by Texas Instrumentsin the year1974. In the year 1976, Motorola designed a Microprocessor chip called 6801 which replacedits earlier chip 6800 with certain add-on chips to make a computer. This paved the way for thenew revolution in the history of chip design and gave birth to a new entity called“Microcontroller”. Later the Intel company produced its first Microcontroller 8048 with aCPU and 1K bytes of EPROM, 64 Bytes of RAM an 8-Bit Timer and 27 I/O pins in 1976.
Thenfollowed the most popular controller 8051 in the year 1980 with 4K bytes of ROM,128 Bytes ofRAM, a serial port, two 16-bit Timers, and 32 I/O pins. The 8051 family has many additionsand improvements over the years and remains a most acclaimed tool for today’s circuitdesigners. INTEL introduced a 16 bit microcontroller 8096 in the year 1982.
Later INTELintroduced 80c196 series of 16-bit Microcontrollers for mainly industrial applications.Microchip, another company has introduced an 8-bit Microcontroller PIC 16C64 in the year1985.The 32-bit microcontrollers have been developed by IBM and Motorola. MPC 505 is a 32-bit RISC controller of Motorola.