What is Microcontroller?
Microcontroller is a chip designed to perform specific task/application. Microcontroller consists of CPU (microprocessor),RAM,ROM,I/O ports,timers,counters etc. Refer Microcontroller tutorial which covers microcontroller architecture, interfacing, timers, interrupts, serial communication and microcontroller kit vendors.
Let us see come of the very useful pins of the microcontroller with their functions.
ALE: As 8051 is based on Harvard architecture. It has separate Program & data memory connected externally. This external memory is access using 16 lines, in which 8 lines are also used as data lines apart from being used as lower order 8 lines of 16 bit external address. In order to make these 8 lines to act as address lines first and then as 8 lines for data we use a 8 bit external latch. The Address Latch Enable output pulse is providing the control signal for latching the low byte of the address during accesses to external memory.
ALE is about 1/6(oscillator frequency), and it is used for external timing/clocking purposes. It also acts as PROG pin for EPROM programming.
PSEN(Program Store Enable): It is the read strobe for interfaced external Program Memory. This signal is activated twice each machine cycle when the device is executing from the external interfaced program memory. It is not activated when the device is executing from the internal Program Memory.
EA/VPP: This pin ia high, CPU of microcontroller executes from internal program memory. When EA is set to low, CPU of microcontroller executes program from external memory. EA pin gets supply voltage during EPROM programming.
XTAL1 & XTAL2 are used to provide external clock frequency within range from 4MHz to 30MHz.
XTAL1 is connected to input to the inverting-oscillator-amplifier.
XTAL2 is connected to output from the inverting-oscillator-amplifier.
There are two ways to provide external clock frequency.
1. Using quartz crystal oscillator
2. Using TTL Oscillator.
As shown in the figure Dallas micro-controller 80c320 has 4 ports i.e. Port 0, Port 1, Port 2 and Port 3.
Port 0: Port 0 is an 8-bit open drain bi-directional port. Port 0 is also the multiplexed low-order address and data bus during accesses to external memory.
Port 1: This port is an 8bit bi-directional I/O port. It has pins that have 1's written to them are pulled high by the internal pull up registers, and in that state can be used as inputs.
Port 2: Port 2 is an 8-bit bi-directional I/O port. Port 2 emits the high-order address byte during accesses to external memory that use 16-bit addresses.
Port 3: Port 3 is an 8-bit bi-directional I/O port. It also serves the functions of various special features of the 80C51 Family.
RST: It is an input pin and is active high (normally low). When high pulse is applied to RST pin, all the registers are reset and all the operations are terminated. The pulse should be high at least for 2 machine cycles for reset to function properly.
There are two methods to reset 80C51.
1. Power - on - reset circuit
2. Power - on - reset with debounce.
VCC: SUPPLY VOLTAGE - +5V
Vss: Circuit ground potential
Refer our Page on microcontroller versus microprocessor which explains similarities and differences between both.
Refer our Page on microcontroller programming using C language including example.
Refer our Page on microcontroller development kit manufacturers.
RS232 interface RS485 interface RS422 interface CAN interface SPI interface interface types and converters DigRF interface
This page explains what is a microcontroller, useful for microcontroller programmers and hardware engineers.