8051 Interface – Servo

A stepper motor is one of the most commonly used motor for precise angular movement. The advantage of using a stepper motor is that the angular position of the motor can be controlled without any feedback mechanism. The stepper motors are widely used in industrial and commercial applications. They are also commonly used as in drive systems such as robots, washing machines etc.

Image Source

Stepper motors can be unipolar or bipolar and here we are using unipolar stepper motor. The unipolar stepper motor consists of six wires out of which four are connected to coil of the motor and two are common wires. Each common wire is connected to a voltage source and remaining wires are connected to the microcontroller.


8051 Interface – Keypad



Image Source

Keypad is a widely used input device with lot of applications such as telephone, computer, ATM, electronic lock etc. A keypad is used to take input from the user for further processing. Here a 4 by 3 matrix keypad consisting of switches arranged in rows and columns is interfaced to the microcontroller. A 16 by 2 LCD is also interfaced for displaying the output. The interfacing concept of keypad is very simple. Every number of keypad is assigned two unique parameters that are row and column (R, C). Hence every time a key is pressed the number is identifying by detecting the row and column numbers of keypad.


8051 Interface – LED

 This tutorial you can learn hello wold LED Blinking project in keil for micro controller. choosed AT89S51 micro controller(You can select any other keil support micro controller) and demonstrated, this is very simple and follow this below steps,
Light Emitting Diodes (LEDs) are simple and most commonly used electronic components to display the digital signal states. The LED emits light when current is passed through it. It could blow up if we pass more current, hence we put a current limiting resistor. Usually, 220, 470 and 1K ohm resistors are commonly used as limiting resistors. You can use any of these depending on the required brightness. Lets, start blinking with LEDs and then generate the different patterns using the available LEDs.
The basic and important feature of any controllers is the number of GPIO’s available for connecting the peripherals. 8051 has 32-gpio’s grouped into 4-Ports namely P0-P3

Required software


Required components and Programmer

  • 1x AT89S51 Controller
  • 1x 4Mhz Crystal
  • 2x 22pf capacitor
  • 1x LED 5v
  • ISP AVR USB programmer


Circuit Diagram

 C code


Assembly Code




8051 Interface – 7 Segment Display

7-Segment Display

Image Source : ArunEworld

A Seven segment display is the most basic electronic display. It consists of eight LED’s which are associated in a sequence manner so as to display digits from 0 to 9 when proper combinations of LED’s are switched on. A 7-segment display uses seven LED’s to display digits from 0 to 9 and the 8th LED is used for dot. A typical seven segment looks likes as shown in figure below. The 7-segment displays are used in a number of systems to display the numeric information. They can display one digit at a time. Thus the number of segments used depends on the number of digits to display. Here the digits 0 to 9 are displayed continuously at a predefined time delay.

Image Source

The 7-segment displays are available in two configurations which are common anode (V+) and common cathode (GND). Here common anode configuration is used because output current of the micro-controller is not sufficient enough to drive the LED’s. The 7-segment display works on negative logic, we have to provide logic 0 to the corresponding pin to make on LED glow. This tutorial you can learn 8051 interface 7 segment display with 8051 controller. I chooses AT89S51 micro controller(You can select any other keil support micro controller) and demonstrated, this is very simple and follow this below.

Image Source


Image Source


if you have any queries call us +918300026060 or WhatsApp Dismiss


Your Cart

%d bloggers like this: