LED Dot matrix.
labsmoke
Posts: 38
Im currently working on a driver for LED Dot matrix displays. Since i got my hands on about·thirty 5x8 led·modules and i felt like wasting some spare time on weekends..
Im about half way, i got methods for printing characters and digits, extracting character data from·dat block and streaming it into an strobe engine since you need the display to be scanning all the time to present any advanced patterns.
i hooked up just one module to start with. shown on the pic.
and im going nuts trying to figure out why the·character on the display 'drags' about i dot to the right. you can see it on the pic. anyone got i clue? heres my routine for the strobing:
________________________________
pub out(char) | offset, index, temp·
encode(char)
··
repeat
·offset:=1
·index:=indexstart
·repeat 5
· pause(5)
· col(offset++)
· temp:=letters[noparse][[/noparse]index++]
· row(temp)
_________________________________
What happens is that i repeat the nested loop 5 times since i want 5 individual scans where i push the row·data and i also extract extract 5 different bytes from·the·'dat' block.
and for some reason it drags whatever letter i print about one dot to the right.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Sometimes you have to rest your persuit of happiness and just be happy.
Im about half way, i got methods for printing characters and digits, extracting character data from·dat block and streaming it into an strobe engine since you need the display to be scanning all the time to present any advanced patterns.
i hooked up just one module to start with. shown on the pic.
and im going nuts trying to figure out why the·character on the display 'drags' about i dot to the right. you can see it on the pic. anyone got i clue? heres my routine for the strobing:
________________________________
pub out(char) | offset, index, temp·
encode(char)
··
repeat
·offset:=1
·index:=indexstart
·repeat 5
· pause(5)
· col(offset++)
· temp:=letters[noparse][[/noparse]index++]
· row(temp)
_________________________________
What happens is that i repeat the nested loop 5 times since i want 5 individual scans where i push the row·data and i also extract extract 5 different bytes from·the·'dat' block.
and for some reason it drags whatever letter i print about one dot to the right.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Sometimes you have to rest your persuit of happiness and just be happy.
Comments
from that part of your sourcecode i do not understand how the WHOLE thing works
could you please post your COMPLETE sourcecode or attach it to a posting
as you did not see the error inside this piece of code the possability that it is somewhere else
get bigger
regards
Stefan
and a dat block with the character data.
the routine i posted is the only thing accociated with the 'scanning'
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Sometimes you have to rest your persuit of happiness and just be happy.
the scan is executed about 1 khz.. and the ghosting gets worse if i up the scan freq.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Sometimes you have to rest your persuit of happiness and just be happy.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Sometimes you have to rest your persuit of happiness and just be happy.
As far as i got you can push in a string i of text and the display automaticly scrolls if text is larger than the hooked up led matrix.
easy expandable dat block for characters, highly modifiable. Everything written in Spin.
next step is being able to push in decimal values, but my gut tells me it will just take a coffey brake for that.
if anyones interested that is. I did this just to waste time over the holiday anyway so..
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Sometimes you have to rest your persuit of happiness and just be happy.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
I am 1010, so be surprised!
but go ahead..its a lot of fun..especially to get the strobe engine running...adding character data to the DAT block is a real pain thought...about 180 bytes to edit manually.. 360 if you want support for both large an small letters...
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Sometimes you have to rest your persuit of happiness and just be happy.
Post Edited (labsmoke) : 3/23/2008 7:46:28 PM GMT
Thanks, Richard
Oh, and the completed source code?
Yeah, i was planning to do so if someone was interested. But it will be posted when i feel that it is ready. I will not haste with stuff i dont get payed for =P
i need to see over the programming some more, get decimal output to work. redraw the algorithm i little bit so you can stop the strobing externally and so on.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Sometimes you have to rest your persuit of happiness and just be happy.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
PLEASE CONSIDER the following:
Do you want a quickly operational black box solution or the knowledge included therein?······
what do you mean? the code works now. if your refering to the ghosting problem.
The only time the code counts a static number of times is when its extracting character data from register and thats a nested repeat loop that repeats 6 times, one time for each byte of the character. and the reason for using 6 bytes for each character is to get a one-dot space between characters.
During strobing and displaying of text it is scanning not just every column of the matrix but also every row-byte of the character ram even if that particular byte is not shown at the moment. Its like an onscreen Ram and an offscreen Ram. Just like many other alphanumerical displays.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Sometimes you have to rest your persuit of happiness and just be happy.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
PLEASE CONSIDER the following:
Do you want a quickly operational black box solution or the knowledge included therein?······
i know what the problem is thought, its lazy programming. i must narrow the character ram and then have a secondary ram.
its just so much programming time....and so little real time...
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Sometimes you have to rest your persuit of happiness and just be happy.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Sometimes you have to rest your persuit of happiness and just be happy.