Hello, I want to pass a five digit number from a PC to be displayed on a set of 5 7-segment LED's. I have got the driver chip wired to the LED's, and have the PICAXE succesfully displaying numbers on the LED. This code.... (Pin 3 is 'clock' and pin 4 is 'data' for the driver chip)
main:
high 3
pause 1
low 3
pause 1
high 4
high 3
pause 1
low 3
low 4
gosub six
gosub seven
gosub eight
gosub nine
gosub zero
high 3
pause 1
low 3
high 3
pause 1
low 3
pause 1
high 4
high 3
pause 1
low 3
low 4
gosub one
gosub two
gosub three
gosub four
gosub five
high 3
pause 1
low 3
goto main
shows "12345" and "67890" alternately, so I'm driving the driver correctly.
What I can't figure out succesfully is how to get, say, "11975" from the PC and then tell the PICAXE to GOSUB one, GOSUB one, GOSUB nine, GOSUB seven, GOSUB five so as to display the right number.
Can someone point me in the right direction?
Richard
main:
high 3
pause 1
low 3
pause 1
high 4
high 3
pause 1
low 3
low 4
gosub six
gosub seven
gosub eight
gosub nine
gosub zero
high 3
pause 1
low 3
high 3
pause 1
low 3
pause 1
high 4
high 3
pause 1
low 3
low 4
gosub one
gosub two
gosub three
gosub four
gosub five
high 3
pause 1
low 3
goto main
shows "12345" and "67890" alternately, so I'm driving the driver correctly.
What I can't figure out succesfully is how to get, say, "11975" from the PC and then tell the PICAXE to GOSUB one, GOSUB one, GOSUB nine, GOSUB seven, GOSUB five so as to display the right number.
Can someone point me in the right direction?
Richard