Go To Position command on an 821

LK/ELK/VK/PK/OK/MX/GLK/EGLK/GVK/GLT Series

Moderators: Henry, Mods

Post Reply
eddywright
LCD?
Posts: 2
Joined: Fri May 10, 2002 6:00 pm
Location: Chicago, IL USA
Contact:

Post by eddywright »

Hi, I have one of the 821 LCD displays and it's working great! I'm using I2C to connect it to an Atmel AVR 2313 MCU. I've built a handheld serial terminal.
My only problem is using the Go To Position command. I can't seem to get this to work... I can clear the screen, turn of the cursor, go to upper left, etc. But I just can't get it to accept the go to command.

I'm using Bascom to program the MCU. Here is the code that I'm using:

Sub Line1 'Move cursor to start of line 1
'Device is at address &H5C
I2csend &H5C , 254 'Control Code
I2csend &H5C , 71 'Go To command
I2csend &H5C , 1 'Column 1
I2csend &H5C , 1 'Row 1
Waitms 25
End Sub

Sub Line2 'Move cursor to start of line 2
I2csend &H5C , 254
I2csend &H5C , 71
I2csend &H5C , 1
I2csend &H5C , 2 'Row 2
Waitms 25
End Sub
Cheese
Bit-Tech.net
Bit-Tech.net
Posts: 337
Joined: Thu Dec 06, 2001 4:00 pm
Location: Cambridge, UK
Contact:

Post by Cheese »

Isn't the top left 0,0 not 1,1?

Might be the problem...

r.
thrust
LCD?
Posts: 7
Joined: Sat Mar 09, 2002 4:00 pm

Post by thrust »

Hi!

Top left for positioning the cursor is at 1,1. So that is probably not your problem.

I think it is a funny inconcistency that all graphic commands have it's orgin at 0,0 (On the graphic displays that is)...

/Oskar Sj
eddywright
LCD?
Posts: 2
Joined: Fri May 10, 2002 6:00 pm
Location: Chicago, IL USA
Contact:

Post by eddywright »

I thought about the 1 vs 0, but it didn't make any difference... Besides, it would have at least done something when I issued the col 1, row 1 command.

Strange...

Eddy
Post Reply