 |
|
 |
| Parallax Forums > Public Forums > Propeller Chip > Nokia LCD interface anyone | Forum Quick Jump
|
|  ALIBE Registered Member

       Date Joined Mar 2006 Total Posts : 299 | Posted 2/26/2007 10:07 AM (GMT -7) |   | |
I am trying to get a larger LCD screen on my robot and thought this one might be a good one to go w/ for $19 a pop.
Has anyone tried this w/ the Prop? Any pointers would be great.
Are there other similar LCDs that people have tried w/ the Prop in this forum?
Thanks in advance
"any small object, accidentally dropped, goes and hides behind a larger object."
ALIBE - Artificial LIfe BEing. In search of building autonoumous land robot
| | Back to Top | | |
 |  mahjongg Registered Member

       Date Joined Jan 2007 Total Posts : 140 | Posted 2/26/2007 10:55 AM (GMT -7) |   | Elektor recently had an article about interfacing such LCD's to microcontrollers, it should not be too hard to do.
Mahjongg | | Back to Top | | |
  |  mahjongg Registered Member

       Date Joined Jan 2007 Total Posts : 140 | Posted 2/26/2007 7:02 PM (GMT -7) |   | | | |
   |  Paul Baker Registered Member

       Date Joined Jul 2004 Total Posts : 6323 | Posted 3/2/2007 9:25 PM (GMT -7) |   | | Here's the file I promised in the PM, like I said it is really really slow. Switching to an assembly version of the SPI routines would drastically speed things up. It's not well commented because I used Bean's example code from the sparkfun website.
Credit goes to Bean for his code and Martin for his SHIFTOUT routine.
Paul Baker
Propeller Applications Engineer
Parallax, Inc. File Attachment : NokiaLCD.spin 3KB (application/octet-stream) This file has been downloaded 312 time(s). | | Back to Top | | |
       |  Harrison. Registered Member

       Date Joined Jul 2004 Total Posts : 474 | Posted 3/3/2007 1:10 PM (GMT -7) |   | Beau wrote a nice spi library in asm as an example in a sticky in this forum. Go here http://forums.parallax.com/forums/default.aspx?f=25&m=141093 and search for shiftout on that page.
You can also download the object directly at: http://forums.parallax.com/forums/attach.aspx?a=8953 | | Back to Top | | |
 |  paulmac Registered Member

       Date Joined Oct 2006 Total Posts : 51 | Posted 3/4/2007 2:02 AM (GMT -7) |   | | | |
  |  lnielsen Registered Member
        Date Joined Jan 2007 Total Posts : 72 | Posted 3/5/2007 12:13 PM (GMT -7) |   | I am also looking at adding a display with soft buttons for my robot controller. DigiKey has the OSRAM Pictiva displays which are oLED based. I don't know if I need color so I am leading towards the 1" 128x64x4 grayscale for $9. I am thinking I can show images from the PropCam on it once that is available and still have room for the soft buttons. I am also interfacing to a Logitech wireless PS2 controller. I wish I could get the new PS3 controller working with the motion sensing features as well but that will take bluetooth.
I will be ordering the display soon and will try the SPI as well.
Len | | Back to Top | | |
 |  Jello Registered Member
        Date Joined Apr 2007 Total Posts : 9 | Posted 4/4/2007 4:14 PM (GMT -7) |   | |
Hi everyone,
Paul Baker has done the Epson driver for this lcd. Has anyone done a Phillips driver for the (nearly identical) Phillips lcd? The pin outs are the same. Nokia phones are supposed to be smart enough to figure out which driver to use.
I scrounged my lcds from a Nokias 3390 and 6030 (if i remember right), and they still work in the phones when i put them back, but my problem is (according to info in the link below) they're talk Phillips not Epson.
http://www.electricstuff.co.uk/noklcd.html
Anyway, I have tried to convert the Epson driver code to use Phillips commands etc., but not having much success. A pretty blue screen that does nothing.
Oh, and i am using the SparkFun lcd break out board. http://www.sparkfun.com/commerce/product_info.php?products_id=600 using Header 1 (vin, cs, clk, data, reset, gnd) , tried jumpers jumped, unjumped.
If someone has already been thru this for the Phillips, I would really like to here about your experience.
thx
<edit> attached my Philipized version of Pauls code, such as it is. Post Edited (Jello) : 4/4/2007 11:25:02 PM GMT
File Attachment : PaulsNokiaConvertedToPhillipsLCD.spin 4KB (application/octet-stream)This file has been downloaded 168 time(s). | | Back to Top | | |
  |  Jello Registered Member
        Date Joined Apr 2007 Total Posts : 9 | Posted 4/4/2007 4:27 PM (GMT -7) |   | | yeah, I tried the tweeking the contrast WRCNTR (write contrast) from it's min to max settings, but I can't see any difference. | | Back to Top | | |
 |  Jello Registered Member
        Date Joined Apr 2007 Total Posts : 9 | Posted 4/6/2007 1:25 PM (GMT -7) |   | | Hotdog!
The good news is: the lcd was not seated properly in the board! hooray! (shame on me for not looking closer)
The other good news is my version of the Philips driver even works! hazaa! yippee!
But.. like stated in an earlier post, it's really, really slow.. but it's better than nothing :)
So, I took some advice (also in an earlier post) and refactored to use the faster SPI Engine.spin assembly spi code.
The bad news is, the spi engine does not seem to work.
Attached is the updated Philips driver if anyone gets a hankering to look at the spi engine calls.
Seems like it should work. hmm.
thx!
<edit> to update attachment Post Edited (Jello) : 4/7/2007 1:47:23 AM GMT File Attachment : NokiaLCDPhillips.spin 4KB (application/octet-stream) This file has been downloaded 176 time(s). | | Back to Top | | |
 |  Jello Registered Member
        Date Joined Apr 2007 Total Posts : 9 | Posted 4/6/2007 8:28 PM (GMT -7) |   | Actually, only the sendData works with the assembly shiftout. The controller takes 9 bit commands/data Cmd = 0 + 8bits of data Data = 1 + 8bits of data
PUB SendCommand(cmd) SHIFTOUT(SData, SClock, cmd, MSBFIRST, 9) ' spin version 'SPI.SHIFTOUT(SData, SClock, MSBFIRST, 9, cmd) ' assembly version not working here PUB SendData(data) ' SHIFTOUT(SData, SClock, data | $100, MSBFIRST, 9) ' spin version SPI.SHIFTOUT(SData, SClock, data | $100, MSBFIRST, 9) 'assembly version DOES work here
It's got to be something simple. I am just not seeing it yet.
J | | Back to Top | | |
 |  jkroylance Registered Member
        Date Joined Dec 2006 Total Posts : 12 | Posted 4/8/2007 1:11 AM (GMT -7) |   | I've been playing with this LCD and code for it, and I tried myself to merge the SPI routines into it and use them instead of the Spin ones. After driving myself nuts for several hours trying to figure out why the LCD works with the Spin code and not with SPI, I stumbled across something: If you issue the very first command to the LCD using the Spin shiftout code (even if it's not a valid command), then start using the faster SPI code, the LCD works fine, and is much faster. Only problem is I can't stand wasting that amount of space on code that's used just once. Attached is an archive of the version I got to work... This is my first attempt at working with propeller programming, so please excuse the sloppiness of the code. I commented alot & tweaked a bunch of stuff trying to figure out why it wouldn't work.
Nokia Test.spin (top object file) NokiaLCD.spin SPIEngine.spin
The part I was messing with is in NokiaLCD.spin toward the bottom of the file in InitLCD, there's a SendSpcCommand() call which calls the Spin shiftout routines to send a $00 to the LCD, then everything's SPI after that. My LCD works fine like this, but if you change SendSpcCommand() to SendCommand() (or even just comment out the whole line), the LCD is unresponsive.
Hopefully someone can figure this one out, it's got me stumped!
File Attachment : Nokia LCD - SPI (sorta) works!.zip 6KB (application/x-zip-compressed)This file has been downloaded 203 time(s). | | Back to Top | | |
| Forum Information | Currently it is Thursday, July 29, 2010 5:18 PM (GMT -7) There are a total of 462,440 posts in 62,066 threads. In the last 3 days there were 90 new threads and 803 reply posts. View Active Threads
| | Who's Online | This forum has 20143 registered members. Please welcome our newest member, ME01. 61 Guest(s), 13 Registered Member(s) are currently online. Details John Abshier, Rayman, Kevin Wood, BradC, Julian800, prof_braino, Harley, Sapieha, Gene Bonin, wiresalot, laser-vector, localroger, Nick McClick |
Forum powered by dotNetBB v2.42EC SP2.02 dotNetBB © 2000-2010 |
|
|