Difference between revisions of "Controlling a seven segment display"
EricNickel (talk | contribs) |
EricNickel (talk | contribs) |
||
Line 17: | Line 17: | ||
There are three primary elements required for a circuit involving a 7-segment display. |
There are three primary elements required for a circuit involving a 7-segment display. |
||
The elements are: |
The elements are: |
||
1) the 7-segment display |
1) the 7-segment display |
||
⚫ | |||
⚫ | |||
⚫ | |||
⚫ | |||
The 7-segment display used in this demonstration is the [http://media.digikey.com/pdf/Data%20Sheets/Lite-On%20PDFs/LTD-4708JS.pdf LTD-4708JS] which can display 2 digits with trailing decimal points. The controller is the PIC 18F4520. The decoder used is the [http://www.standardics.nxp.com/products/hef/datasheet/hef4543b.pdf HEF 4543B] which takes one 4-bit binary input and converts it to the appropriate 7 logic outputs to drive the 7-segment display. |
The 7-segment display used in this demonstration is the [http://media.digikey.com/pdf/Data%20Sheets/Lite-On%20PDFs/LTD-4708JS.pdf LTD-4708JS] which can display 2 digits with trailing decimal points. The controller is the PIC 18F4520. The decoder used is the [http://www.standardics.nxp.com/products/hef/datasheet/hef4543b.pdf HEF 4543B] which takes one 4-bit binary input and converts it to the appropriate 7 logic outputs to drive the 7-segment display. |
Revision as of 12:05, 5 February 2008
Original Assignment
In this project you will use your PIC to display numbers on a seven-segment display.
Overview
In this example, we will be using PIC 18F4520 to control a double digit 7-segment display LTD-4708JS. A few notes about using this display is that it is only designed to display one unit at a time, so when trying to use both digits, you have to use an ISR to switch between the two digits to create the illusion that both are on simultaneously.
Now, since there are 7 segments, one would assume that you would need 7 outputs from the PIC to display 1 digit. But it is very wasteful to use outputs from the PIC for just displaying like this, so we will be using a chip (HEF 4543B) that will take 4-bits and convert it to the 7-bit output for the 7-segment display.
If you want to display a decimal, this particular 7-segment display will allow you to do so. However, it will take up another output from your PIC.
Finally, if you are planning on displaying more than one digit, you will need an extra bit for every digit that you want to display.
Circuit
There are three primary elements required for a circuit involving a 7-segment display. The elements are:
1) the 7-segment display
2) the controller (in this case the PIC)
3) the decoder
The 7-segment display used in this demonstration is the LTD-4708JS which can display 2 digits with trailing decimal points. The controller is the PIC 18F4520. The decoder used is the HEF 4543B which takes one 4-bit binary input and converts it to the appropriate 7 logic outputs to drive the 7-segment display.
More to come . . .