As it is shown above there are many types of LED displays, some very common are shown above.
By functionality point of view and keeping in view our tutorial on led display, we can easily classified these in two:
Common anode type and Common Cathode type displays.
The box that the 7 segment is in represents the common. There are two types of 7 segment displays, common cathode and common anode. In my projects, I use common cathode displays. As you can see, to control any of the segments, a +ve signal is required, as they all share the same earth. So these are common cathode type displays.
Interface of one seven segment display with microcontroller PIC16f84.
LED Seven Segment display common cathode type (one)
Microcontroller PIC16f84 (one)
Resistors: 220Ohm (seven)
Crystal : 4 MHz (One)
Capacitors: 33pf (two)
Power supply: % volt Dc regulated power supply (One)
FIG (interface of one digit with microcontroller)
The program for display is written in Proton Basic language.
The code listing is as follows. The whole code is commented well, to describe the reasoning of each line.
The following example shows how to decode a value between 0-9 into 7 segment data and display it.
Xtal = 4
Dim N As Byte
PORTB_PULLUPS = False ‘internal pull up are switched off.
dim number  as byte ‘ this declaration of an array of 10 bytes with name number. Dim is reserved word for proton compiler, and number is the name of the array you can use your own name whatever you like but it should not be from the reserved word of compiler.
number  = 111111 ‘ here we do the initialization of the element of the array with known numbers so that a meaning full display comes on the digit. This number depends on the hardware connection very much.
number  = 000110
number  = %01011011
number  = %01001111
number  = %01100110
number  = %01101101
number  = %01111100
number  = 000111
number  = %01111111
number  = %01100111 ‘ the index of the array is the number to be display on the digit. And each element is filled with the binary code of that number.
TRISB = 000000 ' Make PORTB all outputs
N = 0 initially the counter is zero
Repeat ' Create a loop
PORTB = number [N] ' Convert to segment data and display it
DelaymS 500 ' Small delay to slow down counting
Inc N ' Increment the Number register
Until N = 10 ' Loop until number = 10, then reset
GoTo Main ' Loop forever
led light dice suppliers,plastic led dice manufacturers,plastic led dice suppliers,plastic led dice light,LED DICE (with Slow Down) Circuit,Roll and Tap Activated Digital LED Dice ,Dice LED decoder,7 Segment LED,Interfacing to 7-Segment Displays,7-segment display : DIGITAL INTEGRATED CIRCUITS,Seven-Segment LED,Alphanumeric hexadecimal 15-segment LED display ,Seven Segment LED Display, LED Display, 16 Segment LED Display