7 Segment LED display with PIC controller and Flowcode V5
First of all, if you have any questions, feel free to comment! I’d be more than happy to answer your question as good as possible!!
Materials used :
– PIC 18F452 Microcontroller ( any PIC microcontroller with enough pins will do )
– 7 Segment common anode LED display
– 24 Mhz Crystal
– A couple resistors
– Shitloads of jumper wire
Step 1: Making the connections
For this, you will have to check the datasheet of your display,
This is the datasheet of the display i used :
As you can see, pin 8 and 3 connect to +Vdd
and all the other pins have to go to -Vcc
You could use a resistor on every individual led, but to save time and space i used a single resistor on the common anode or cathode pin.( I used a 220R resistor but it varies )
Now, the real connections
I will list which LED segment should connect to which port :
Segment A -> PORT B0
Segment B -> PORT B1
Segment C -> PORT B2
Segment D -> PORT B3
Segment E -> PORT B4
Segment F -> PORT B5
Segment G -> PORT B6
Segment DT (if you have a dot segment ) -> PORT B7
And your common pin should go to -> PORT A3
Step 2: On to flowcode
When you created a flowcode project
The first thing you should do is add a 7 segment display module
You can do that by going to ‘Outputs’ and adding a 7seg1 module.
When you added that, check if all the connections are right by right clicking the module and choosing ‘connections’
It should look like it does on the picture.
Step 3: Thank you
Thank you for reading my instructables, i really appreciate it.
I hope you learned something from this and make alot cooler stuff with it than i did in this tutorial
An example for the non creative people out there would be a digital clock :p
Have a nice day but most of all
Have fun creating!
For more detail: 7 Segment LED display with PIC controller and Flowcode V5
Current Project / Post can also be found using:
- pic16f877 project flowcode PDF
- write a program to display temperature on seven segment display using flowcode