Main Site Documentation

Nokia 3510i LCD 9bit SPI running as 8bit


#1

I found one of these cheap LCDs on ebay and thought I would get one to see how well I could get 9bit running as 8bit. It’s cheap enough I could just toss if I didn’t think it was worth the trouble. It’s also ugly enough that I don’t think I would use it for anything anyway.

To use up all the bits I created 9byte command sets. The command set transfers to a larger 7k command queue that is able to write the entire screen in less than 5ms. At the most it would only waste around 7bits out of 7k which is why it can update so fast.

Now I just have to find the best way to merge draw data into the command buffer and not update full commands every time.
http://www.youtube.com/watch?v=2w6MpelHJNE


#2

Does it work different than the one we have?


#3

It looks like a different controller but identical functions. The key thing is that any incomplete commands are ignored when the CS is pulled. It would probably even use the identical code with just the Commands enum and Init changed.

This is the code I have worked out so far.
http://dl.dropbox.com/u/3647376/Nokia3510.zip

The buffer is scalable and only has to be large enough to hold all the commands to draw the current address frame. It still works if it’s smaller but the update isn’t as smooth. The small buffer is 54 bytes because the speed increase seems inverse square to the number of stages so it doesn’t really matter that much after 3.


#4

@ Savitch: I’m glad you’re on this forum

Out of the box thinking and not afraid to call a hammer a spanner!!!

I think you are a big asset to netmf… Keep going thats all I’ll say

Cheers Ian


#5

Thanks, I always like to get something to work well in a way it’s not supposed to work.

This is a speed test of a sprite draw method. It has some flicker because of the display scan rate so I don’t think this method is that useful over 9x9.
http://www.youtube.com/watch?v=1333hpEzCGQ


#6

not bad speed. How much was the display?


#7

i got one for 6100 lying around. They use the same lcd screen for 3510i. I got it from someone that doesn’t need the phone anymore :smiley:


#8

That one was less than $9 on ebay. It works well in bright light but the back light is no good with just the 2 LEDs at the bottom. It comes off the board and is just sitting on some pads.


#9

I uploaded the final which is able to get some reasonable vector draw speeds and smooth refresh.
(link removed)


#10

Where did you get the “Nokia 3510i LCD” ?

How much?

-Eric


#11

I got it from here for less than $9.
http://cgi.ebay.com/Nokia-3510I-Color-STN-CSTN-LCD-Module-Display-51-MCU-/200452329046?pt=LH_DefaultDomain_0&hash=item2eabe3ce56#ht_4521wt_905


#12

Here’s another test running a little platform game engine. The tiles draw at startup and get saved to the back buffer so only moving sprites need drawn each frame.
http://www.youtube.com/watch?v=Rip12tuQESw


#13

Very cool. What is next? A fez game engine?


#14

That’s a possibility because this was just cut and paste from what I had running on the 128x64 lcd. Now if I can just get a smooth side scroll without taking much more ram.


#15

This is very cool! Do you have a link to the game engine?


#16

This is the single frame version used for the test.
http://dl.dropbox.com/u/3647376/Nokia3510platformTest.zip

The only specific LCD control it needs is the SetDot(x,y) method for the sprite draw, and a way to save/load the current frame to a back buffer in the Level init and draw. It’s setup for 3 frame animation and will load tiles and sprites from standard 1bit BMP from SD.

It was adapted from the XNA platformer example which just needed a few adjustments to make it more efficient and I added bar and ladder mechanics. The ladder still needs some work for the up/down control but the rest seems to work.


#17

Will this work for the Nokia LCD shield also?


#18

It would work the same way but needs adjusted for the different command set and init.


#19

Thanks for the answer, I’ll give it a try and tell you how it goes