View Full Version : My led matrix Hello World
05-05-2008, 05:56 PM
Recieved my Prop demo board and a $13 16 x 32 led matrix from Futurelec about the same time, so I decided to see if I could figure them both out over the weekend....
Pleased to report success...· Even got my first parallel app going with program control in one cog and another dedicated to refreshing the display :)
Spin seems pretty easy to use, though not quite as fast as I thought it'd be considering an 80mhz clock, which I guess explains why so many of the demo apps are written in assembly.· I've been spoiled with high level languages for so long...
The led matrix board used 5V pullups onboard, so I used a 74HC244 as a level converter.· I looked through the Prop datasheet, but I'm not certain if the IO is 5V tolerant... any know?· Or what is the common method for dealing with 5V logic?
I've got a couple of Spin questions, I'll try to search around first.
Still - I see great things coming ;)
Post Edited (Agent420) : 5/6/2008 1:48:14 PM GMT
That looks really neat http://forums.parallax.com/images/smilies/wink.gif, now that you have graphics... it can fly !
The IOs of the propeller are not 5V tolerant, but they can withstand 5V as inputs IF and ONLY IF you put a series resistor, around 1 kohm works well. As output you get something like 3 V, so a level shifter is needed to reise to 5V. I used some ACT logic (VCC at 5V for logic), that worked well. Your 244 is a good option also. Do not forget that there are specilized level shifters, like the SN74LVC8T245 and similars. There are extensive discussions here about level shifting.
Have fun, but you are already having lots of it http://forums.parallax.com/images/smilies/smile.gif
Post Edited (Ale) : 5/5/2008 11:10:22 AM GMT
05-05-2008, 06:04 PM
Cool. They have some really nice prices for stuff over at Futurlec. That's a great price for your display!
05-05-2008, 06:08 PM
You trade price for shipping time ;) I've never had a problem ordering from them, but average shipping has got to be about a month. On the plus side, you get some cool stamps from Thailand on the box (the Futurelec webpage infers NYC, but in reality all items are shipped from asia).
And yeah, had to have a Prop as my first graphic ;)
05-05-2008, 08:27 PM
The "miniboards" on futurlec (SD breakout, mp3, RTC) look like really good deals...
about 1/2 the cost for Sparkfun's stuff.· A month does seem like a long time to wait though...
05-05-2008, 10:42 PM
I've got the schematics and board info (not just the chip datasheets) for the entire mini-board series on the cd supplied by Futurlec with my last order (got me a couple $6 DS1307 RTC boards - with battery)...··· If you're curious about a board, or would like to see the schematic just let me know and I'll post it.
As an example, this last order was submitted on·4/5, recieved on 5/1.· It's usually closer to the 3 week period, but i feels like forever when you're waiting on goodies ;)
05-05-2008, 10:51 PM
Nice work on the display. I bought one of those a few months back and did some work on the Basic Stamp 2 and SX-28. Here are the links:
Here is the BS2 link (last post at the bottom):
Here is the SX28 link:
You might also want to look at:
05-05-2008, 11:45 PM
Yes - I saw some of your posts and was going to comment, but I forgot my source code which I was going to refer to...
Fwiw, I initially had some erratic display, and eventually tracked it down to the timing of the Strobe signal.· After some trial & error, I dscovered that I could simply leave the Strobe signal low (enabled) and it worked fine - stable as a rock; it does not need to alternate levels along with the clock or latch signals.·· I look at it now more as a global on/off signal than anything else.
There's also no real reason needing to have the clock signal symetrical... I don't bother with timing, as the Spin code doesn't go fast enough to exceed the chip's maximum rate of 5mhz.· I just get a set of 16bit data for the row, col_left and col_right then clock it over by back to back pin-set / pin-clr statements (data is shifted on the rising edge of clock high).· When all 16 bits are shifted, I do a back to back latch signal toggle to set the data.· No waits, timers, counters, nothing; just two 0 to 15 loops.· The only prerequisite is a latch toggle before things get going to set a known reference point for the 16 bit sycle.
So provided you do not need to turn the display on and off via code, you can save an io pin by hardwiring it low.
Also, with the Propeller anyway (or an equivalent ISR in another architecture), I have no troubles modifying the display ram - which I have set as a·16 element ·long (32bit) variable array - while the display operations run in the background.· So to manipulate the display, I just modify the variables.· Scrolling and other fx·are programming things like bit shifting or copying one array element to another.
Post Edited (Agent420) : 5/5/2008 5:38:00 PM GMT