Sunday 7 June 2015

7 Segment display Interfacing with 8051

7 Segment Display Interfacing with 8051


A seven-segment display (SSD), or seven-segment indicator, is a form of electronic display device for displaying decimal numerals that is an alternative to the more complex dot matrix displays.
Seven-segment displays are widely used in digital clocks, electronic meters, basic calculators, and other electronic devices that display numerical information.

The seven elements of the display can be lit in different combinations to represent the arabic numerals. Often the seven segments are arranged in an oblique (slanted) arrangement, which aids readability. In most applications, the seven segments are of nearly uniform shape and size (usually elongated hexagons, though trapezoids and rectangles can also be used), though in the case of adding machines, the vertical segments are longer and more oddly shaped at the ends in an effort to further enhance readability.

The numerals 6, 7 and 9 may be represented by two or more different glyphs on seven-segment displays.



The seven segments are arranged as a rectangle of two vertical segments on each side with one horizontal segment on the top, middle, and bottom. Additionally, the seventh segment bisects the rectangle horizontally. There are also fourteen-segment displays and sixteen-segment displays (for full alphanumerics) , however, these have mostly been replaced by dot matrix displays.

The segments of a 7-segment display are referred to by the letters A to G, where the optional DP decimal point (an "eighth segment") is used for the display of non-integer numbers.



Program to interface single seven segment

CODE

#include<reg51.h>
int main()

{
unsigned int a[10]={0X3F,0X06,0X5B,0X4F,0X66,0X6D,0X7D,0X07,0X7F,0X6F},i,j;  // Hex values corresponding to digits 0 to 9

while(1)
{
for(i=0;i<=10;i++)
{
P2=a[i];
for(j=0;j<33000;j++);    // Time delay
}
}
}

PROTEUS DIAGRAM





For more information contact me at chandershh@gmail.com.