Let's Make Robots!


I have looked over CtCs post regarding similar issues with his LCD, but still can get mine to budge. I was hoping to get some guidance on my issue. The issue being I can't get the LCD to work or interface with my PICAXE. Like Ctc, I am using the serial backpack from SparkFun. Here is my code:

pause 1000
setfreq m8

pause 2000                        
serout 1,T9600_8,(124, 4) 'Sets 20 char (3)    |
pause 200                        
serout 1,T9600_8,(124, 6) 'Sets 4 line (5)    |

pause 1000
serout 1,T9600_8,(0x7c, 128)    'Sets backlight full on (128-157 '128 is full on

pause 1000
serout 1,T9600_8,(254, $01) 'Clear Screen


    pause 200
    serout 1,T9600_8,(254, 128)    'Sets line 1 position 1
    pause 200
    serout 1,T9600_8,("line 1")
    pause 200
    serout 1,T9600_8,(254, 192)    'Sets line 2 position 1
    pause 200
    serout 1,T9600_8,("line 2")

goto main


If I turn the 10k trim pot on the back to adjust the contrast, for a moment I see "blocks", but not text. Any clues?

photo.jpg142.85 KB

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Yes. Same result.

When you send the command to change the backlight is that working?  If so then we know at least that you are setup correctly for serial.  I'm working this straight from the SparkFun and PicAxe datasheets as I don't have a PicAxe to test out.  Sorry if I'm not being much help to you.

Don't let yourself get frustrated.  As soon as we figure out all the stuff that doesn't work all that is left are those that do work.

Yes the backlight works and as I mentioned, I can flash it in a loop. I was assuming that meant baud rates were correct, etc. Just not sure though.
Pin 7 is the serial pin. Leg 7, which I am using, is out 7.
Shouldn't you be using the serial pin for the serial communications? Or, can you set up any I/O pin as a serial pin?  Check CTC's code in the post you referenced above; he is using the serial pin 7.  Also, did you test the last bit of code I posted?
Yep, you can send serial data out of any pin. I did try the last chunk of code, no go, but thanks.

The LCD was trash. I got a new LCD and LCD backback today, used the original code and everything works fine.

Thanks to all for your assistance.