Hi Robert, A few comments after looking at your code: 1. What is the speed the PICmicro is running at? I'm asking this for the time delays. It's not obvious in your code as to how it works. 2. How did you wire up the PICmicro to the LCD? I have an idea based on your code, but I wanted to understand from you how you did it. What are you using for a shift register? From your code, it looks like the serial data is latched on the falling edge of the clock. 3. The big problem that I see in your code is that in your variable declarations, you declare the memory location "MSG". Your "Main" code is: > Main: > movlw HelloWorld > movwf MSG > call SendPSTR > movlw 0x00AA > call SendINS > > LSleep: ;sleep > ;goto LSleep > goto $ Which looks okay... But when I look at "SendPSTR", you are calling "MSG": > SendPSTR: ;sends a 0 delimited str to LCD from prog memory > clrf FSR ;Start of msg at MSG, uses FSR for offset > SendPSTRLoop: > call MSG > movwf LCDTemp > movf LCDTemp,w > btfsc STATUS,Z > return > call SendCHAR > incf FSR,f > goto SendPSTRLoop which is a BIG problem - and probably the one that you are having. I think in your code, the "call MSG" instruction should actually be "call HelloWorld" and after "Main", you can delete the " movlw HelloWorld"/"movwf MSG" instructions from the code. Let me know if this gets you any closer, myke ----- Original Message ----- From: "Robert Sochon" To: Sent: Thursday, April 12, 2001 2:46 PM Subject: [pic]: LCD mystery > I have some code for 4 bit data transfer from Myke > predko - its good code - ive got the delays right ( i > think) but every time i turn the circuit on the > display shows a different set of characters everry > time.... nothing logical either just a set of junk! > > Any ideas? > > its menat to say hello world and occassionally shows > the right number of characters.... but not always! - > no bust jumpers either > > > Does anyone have a truly bullet proff complete 4 bit > routine? that doesnt use the busy flag...! > > THanks for all the help already - im slowly gettiong > there - uphil struggle :) > > Cheers > > robert > > ps attached is asm file if anyone wants a look! > > ____________________________________________________________ > Do You Yahoo!? > Get your free @yahoo.co.uk address at http://mail.yahoo.co.uk > or your free @yahoo.ie address at http://mail.yahoo.ie -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads