8051 is a 40 Pin microcontroller consisting 4 ports each port
consists 8 pin i.e. a total of 4X8=32 pins. These pins are used to
input/output operation some Pins have dual functions like timer
interrupts etc. Among these 32 pins two pins are for power supply
and ground (pin 40 and 20) two pins to connect crystal oscillator
(pin 18 19) 3 pins to connect external memory (pin 29 30 31) and
one pin for Reset function (Pin 9). It has two types of memory RAM
and Flash memory (EEPROM) they have different sizes depending on
the microcontroller you choose.