
-----------------------------------
victor15
Fri Jan 11, 2008 9:19 am

7-segment decoder display interfacing
-----------------------------------
On my breadboard I have a CD4055 chip connected to a single 7-segment decoder display. How do I interface it on the computer so whenever I press a number in turing, the number comes up on the 7-segment display? Thanks!

-----------------------------------
Tony
Fri Jan 11, 2008 10:30 am

RE:7-segment decoder display interfacing
-----------------------------------
in Turing, a common hardware interface is done through a parallel port, using parallelput command (I think). You should read the documentation in the Help files, it could be confusing. You can then send a signal to the hardware.

You would have to either tweak the hardware to interpret your signal, or figure out what kind of input the hardware is expecting.

-----------------------------------
victor15
Fri Jan 11, 2008 3:54 pm

Re: 7-segment decoder display interfacing
-----------------------------------
I have tried to use the parallelput command but whenever I do this:

Parallelput (255)

the entire 7-segment decoder lights up. However, if I put any other value for parallelput, then the entire 7-segment still lights up but gets dimmer. I couldent get the value 1 or anthing to appear on the 7-segment using turing. Any suggestions?

-----------------------------------
Tony
Fri Jan 11, 2008 4:03 pm

RE:7-segment decoder display interfacing
-----------------------------------
find documentation for the 7-segment decoder. Or ask someone who knows more about this particular device. This might be a problem outside of Turing.

-----------------------------------
octopi
Fri Jan 11, 2008 7:35 pm

Re: 7-segment decoder display interfacing
-----------------------------------
You've tried every other value?

If you haven't then I'd make a simple loop (with a delay) that will increment from 1 to 255 and write the number to the port, then let it run and watch it, and see for sure.

But, yes, if you can find a pdf for it, it will make things alot easier.

Also the reason your seeing it get brighter and fainter, is that its probably being powered from the parallel port. The parallel port works by setting the data pins high, or low.
High means it is raised to a higher voltage, and low means nothing is there.

When you send it 255 as the value, that means that all 8 pins are being set high (so it will have a lot more power), if you send it a value of 0 that means that no pins will be set high.

It could be that each segment corresponds to a bit, this would explain that when you set it to 255 all the lights light up.

The loop would be your best bet.
Keep in mind your going to probably have to set individual bits


                \1/
                 _
 might be 32 -> |_|    |_|   