In modern terminology, it is similar to, but less sophisticated than, a system on a chip SoC ; a SoC may include a microcontroller as one of its components. Microcontrollers are designed for embedded applications, in contrast to the microprocessors used in personal computers or other general purpose applications consisting of various discrete chips. Microcontrollers are used in automatically controlled products and devices, such as automobile engine control systems, implantable medical devices, remote controls, office machines, appliances, power tools, toys and other embedded systems. Mixed signal microcontrollers are common, integrating analog components needed to control non-digital electronic systems. In the context of the internet of things , microcontrollers are an economical and popular means of data collection , sensing and actuating the physical world as edge devices.
|Published (Last):||16 January 2009|
|PDF File Size:||12.4 Mb|
|ePub File Size:||19.75 Mb|
|Price:||Free* [*Free Regsitration Required]|
Unlike a microprocessor ex: Intel , a microcontroller does not require any external interfacing of support devices. Intel is the most popular microcontroller ever produced in the world market.
Now lets talk about microcontroller in detail. Before going further, it will be interesting for you to understand the difference between a Microprocessor and Microcontroller.
We have a detailed article which describes the basic difference between both. Microprocessor vs Microcontroller. Here is a Quick Access to various sections of this article Intel first produced a microcontroller in under the name MCS , which was an 8 bit microcontroller.
Later in they released a further improved version which is also 8 bit , under the name MCS The most popular microcontroller belongs to the MCS family of microcontrollers by Intel. Following the success of , many other semiconductor manufacturers released microcontrollers under their own brand name but using the MCS core.
Global companies and giants in semiconductor industry like Microchip, Zilog, Atmel, Philips, Siemens released products under their brand name. Intel then released its first 16 bit microcontroller in , under name MCS There is no need of explaining what each package means, you already know it. So I will skim through mainly used packaging for See, availability of various packages change from device to device.
Its possible to explain microcontroller architecture to a great detail, but we are limiting scope of this article to internal architecture, pin configuration, program memory and data memory organization. The basic architecture remains same for the MCS family. The general schematic diagram of microcontroller is shown above. We can see 3 system inputs, 3 control signals and 4 ports for external interfacing. A Vcc power supply and ground is also shown. Now lets explain and go through each in detail.
System inputs are necessary to make the micro controller functional. Without proper power supply, no electronic system would work. Take a look at the schematic diagram below a functional microcontroller. As mentioned above, control signals are used for external memory interfacing. You can also see a 0. For describing pin diagram and pin configuration of , we are taking into consideration a 40 pin DIP Dual inline package.
Now lets go through pin configuration in detail. Pin : Named as Vcc is the main power source. You may note some pins are designated with two signals shown in brackets. Pins Known as Port 0 P0. If there is no external memory requirement, this pin is pulled high by connecting it to Vcc. Pins- Known as Port 2 P 2. Pin Named as Vss — it represents ground 0 V connection.
Pins 18 and Used for interfacing an external crystal to provide system clock. Pins 10 — Known as Port 3. This port also serves some other functions like interrupts, timer input, control signals for external memory interfacing RD and WR , serial communication signals RxD and TxD etc. This is a quasi bi directional port with internal pull up. Pin As explained before RESET pin is used to set the microcontroller to its initial values, while the microcontroller is working or at the initial start of application.
Pins 1 — Known as Port 1. Unlike other ports, this port does not serve any other functions. Just look at the diagram above and you observer it carefully. The system bus connects all the support devices with the central processing unit. From the figure you can understand that all other devices like program memory, ports, data memory, serial interface, interrupt control, timers, and the central processing unit are all interfaced together through the system bus.
RxD and TxD serial port input and output are interfaced with port 3. Before going deep into the memory architecture of , lets talk a little bit about two variations available for the same. They are Princeton architecture and Harvard architecture. Example:- micro controller is based on Harvard architecture and micro processor is based on Princeton architecture.
Thus has two memories :- Program memory and Data memory. Now lets dive into the program memory organization 0f It has an internal program of 4K size and if needed an external memory can be added by interfacing of size 60K maximum. By default, the External Access EA pin should be connected Vcc so that instructions are fetched from internal memory initially.
When the limit of internal memory 4K is crossed, control will automatically move to external memory to fetch remaining instructions. If the programmer wants to fetch instruction from external memory only bypassing the internal memory , then he must connect External Access EA pin to ground GND. You may already know that has a special feature of locking the program memory internal and hence protecting against software piracy.
This feature is enable by program lock bits. Once these bits are programmed, contents of internal memory can not be accessed using an external circuitry.
How ever locking the software is not possible if external memory is also used to store the software code. Only internal memory can be locked and protected. Once locked, these bits can be unlocked only by a memory-erase operation, which in turn will erase the programs in internal memory too. Pipelining makes a processor capable of fetching the next instruction while executing previous instruction. Its some thing like multi tasking, doing more than one operation at a time. In the MCS family, has bytes of internal data memory and it allows interfacing external data memory of maximum size up to 64K.
Observe the diagram carefully to get more understanding. Register banks form the lowest 32 bytes on internal memory and there are 4 register banks designated bank 0, 1, 2 and 3. Each bank has 8 registers which are designated as R0,R1…R7.
At a time only one register bank is selected for operations and the registers inside the selected bank are accessed using mnemonics R Other registers can be accessed simultaneously only by direct addressing. Registers are used to store data or operands during executions. By default register bank 0 is selected after a system reset. The bit addressable ares of is usually used to store bit variables. The bit addressable area is formed by the 16 bytes next to register banks.
They are designated from address 20H to 2FH total bits. We need only a bit to store this status and using a complete byte addressable area for storing this is really bad programming practice, since it results in wastage of memory.
The scratch pad area is the upper 80 bytes which is used for general purpose storage. An clock circuit is shown above. In general cases, a quartz crystal is used to make the clock circuit. In some cases external clock sources are used and you can see the various connections above.
Clock frequency limits maximum and minimum may change from device to device. Standard practice is to use 12MHz frequency. If serial communications are involved then its best to use Okay, take a look at the above machine cycle waveform. One complete oscillation of the clock source is called a pulse. Two pulses forms a state and six states forms one machine cycle. Also note that, two pulses of ALE are available for 1 machine cycle.
For reset to happen, the reset input pin pin 9 must be active high for atleast 2 machine cycles. During a reset operation :- Program counter is cleared and it starts from 00H, register bank 0 is selected as default, Stack pointer is initialized to 07H, all ports are written with FFH. There is four port but port o and port 2 not understand please explain these two port , what purpose of this output or input.
And where will be get right output. It is a very nice explaination for understanding the Hi guys, i am student, and i am doing final year project. I wish to know what is the minimum voltage that you can give at the input port of the , and the ideal voltage, so the can read it as a high 1 input. Joseph — it depends! You read the manufacturers datasheet to know about that. It varies with manufacturer. I also build a solar tracker.. Superab explanation.. Bus is a place where every block in the is interconnected.
8051 Microcontroller Architecture
The Microcontroller was designed in the s by Intel. Its foundation was on Harvard Architecture and was developed principally for bringing into play in Embedded Systems. These most modern Microcontrollers need the fewer amount of power to function in comparison to their forerunners. There are two buses in Microcontroller one for the program and another for data. As a result, it has two storage rooms for both program and data of 64K by 8 sizes.
Embedded Systems/8051 Microcontroller
This article is about the Microcontroller Introduction and some of its basic features. The Microcontroller is one of the most popular and most commonly used microcontrollers in various fields like embedded systems, consumer electronics, automobiles, etc. Even though Microcontroller might seem a little bit out of fashion, we feel that it is one of the best platforms to get started with Microcontrollers, Embedded Systems and Programming both C and Assembly. But before going in to the Introduction and Basics of Microcontroller, we need to a little bit about what a Microcontroller is and Difference between Microprocessor and Microcontroller.
8051 Microcontroller Tutorial and Architecture with Applications
Unlike a microprocessor ex: Intel , a microcontroller does not require any external interfacing of support devices. Intel is the most popular microcontroller ever produced in the world market. Now lets talk about microcontroller in detail. Before going further, it will be interesting for you to understand the difference between a Microprocessor and Microcontroller. We have a detailed article which describes the basic difference between both. Microprocessor vs Microcontroller.