8051 is an 8-bit family of microcontroller developed by Intel in the year 1981. This is one of the most popular family of microcontroller being used all across the world. This microcontroller was also referred as “System on a Chip” because it has 128 bytes of RAM, 4Kbytes of ROM, 2 Timers, 1 Serial port, and four ports on a single chip. The CPU can work for only 8bits of data at a time because 8051 is an 8-bit processor. In case the data is larger than 8 bits then it has to be broken into parts so that the CPU can process conveniently. Most manufacturers have put 4Kbytes of ROM even though the quantity of ROM can be exceeded up to 64 K bytes.
For describing pin diagram and pin configuration of 8051, we are taking into consideration a 40 pin DIP (Dual inline package). Now lets go through pin configuration in detail.
Pin-40 : Named as Vcc is the main power source. Usually its +5V DC.
You may note some pins are designated with two signals (shown in brackets).
Pins 32-39: Known as Port 0 (P0.0 to P0.7) – In addition to serving as I/O port, lower order address and data bus signals are multiplexed with this port (to serve the purpose of external memory interfacing). This is a bi directional I/O port (the only one in 8051) and external pull up resistors are required to function this port as I/O.
Pin-31:- EA/ External Access input is used to enable or disallow external memory interfacing. If there is no external memory requirement, this pin is pulled high by connecting it to Vcc.
Pin-30:- ALE aka Address Latch Enable is used to demultiplex the address-data signal of port 0 (for external memory interfacing.) 2 ALE pulses are available for each machine cycle.
Pin- 29:- PSEN or Program Store Enable is used to read signal from external program memory.
Pins- 21-28:- Known as Port 2 (P 2.0 to P 2.7) – in addition to serving as I/O port, higher order address bus signals are multiplexed with this quasi bi directional port.
Pin 20:- Named as Vss – it represents ground (0 V) connection.
Pins 18 and 19:- Used for interfacing an external crystal to provide system clock.
Pins 10 – 17:- 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 9:- As explained before RESET pin is used to set the 8051 microcontroller to its initial values, while the microcontroller is working or at the initial start of application. The RESET pin must be set high for 2 machine cycles.
Pins 1 – 8:- Known as Port 1. Unlike other ports, this port does not serve any other functions. Port 1 is an internally pulled up, quasi bi directional I/O port.
If we will go back to history the 8051 microcontroller was first invented in the year 1980 by the microprocessor giant Intel and gradually it has been accepted worldwide and with the every coming days the importance of the 8051 microcontroller is escalating. When it was invented by the Intel, it was developed by means of NMOS technology, but as NMOS technology but it was not very effective.
In order to increase the effectiveness and the productivity the Intel has remodeled it by implementing the technology of CMOS technology and a new edition came into existence with a letter ‘C’ in the title name so that it can meet the demand and can perform up to the mark. The new edition of the 8051 micro controller has two buses and out of which one for the program and other for data so that it can perform well.
When it comes to the basic of the microcontroller, we must be aware about the various components of microcontroller and the components are : central processing unit(CPU), random access memory (RAM), read only memory(ROM), input/output ports timers, counters interrupt controls, analog to digital converters, digital analog converters, serial interfacing ports and oscillatory circuits.
CPU: it is called as the brain and the main function is to fetch and decode instructions so that the other functions can be carried out smoothly.
Memory: When it comes to the memory of the microcontroller the microprocessor comes to picture and the various memories installed inside the microcontroller are RAM and ROM (EEPROM, EPROM, etc) or flash memories for storing program source codes.
Parallel Output and Input Ports: The main objective of these ports inside the microcontroller is to drive the various interfaces between the connected devices.
Serial ports: These are also an important part of the microcontroller.
Timer and counters: The number of timers and the counters inside a microcontroller vary and mainly they are used for the purpose of lock functions, modulations, pulse generations, frequency measuring and making oscillations so that the task can be performed with the stipulated time interval.
Analog to Digital Converter & Digital to Analog Converter: These are the convertor used inside the microcontroller in order to convert the signal from analog to digital and vice versa.
Interrupt control: The name itself is self explanatory and it helps to perform the program without any interruption.
Special Functioning Block: These are the extra and special addition to the microcontroller to perform certain special task.
Even with the development of many advanced and superior Microcontrollers, 8051 Microcontroller is still being used in many embedded system and applications.
Some of the applications of 8051 Microcontroller are mentioned below: