7 segment display help

saluja

New Member
i want to connect a seven segment display in my project.i am using key switch,buzzer and seven segment display with picaxe 18 .so please help build the project by telling me the program of how to connect seven segment display.
 

ylp88

Senior Member
The program will be a matter of setting the right ouput pins high. The problem arises that not all displays have the same pinouts and thus you may have to experiment with your display.

One way is to make a lookup table:
LOOKUP digit,(one,two,three,four,five,six,seven,eight,nine,zero), display

let pins = display

The data stored in the lookup table will have to be set so that it will turn the correct segments on. This whould most likely be in binary form where a 1 will represent a segment which is on and a 0 will be a segment wich is off. Thus, the number 1 with two digits on will have two "1"s and six "0"s. And 8 will have seven "1"s and one "0".

Take a look at an old post:
http://www.rev-ed.co.uk/picaxe/forum/Topic.asp?topic_id=1055&forum_id=9&Topic_Title=Help%2Bwith%2B7%2Bsegment%2Bdisplay%2Bprogram&forum_title=No+new+posts+please%21+4

ylp88
 

RickAlty

Senior Member
Do you need to drive only one digit? If so, you can do that directly from the PICAXE - just each output pin to one pin of the LED, and make the pin high when you want to light up that pins segment.

If you need to use more than one digit, then you're going to need to use the PICAXE to send data to a driver chip which will then operate the LED's
 
Top