Go Down

Topic: LCD limited with space (Read 606 times) previous topic - next topic

zit1343

Hey
I am trying to display 4 things
and I am limited with amount of space
I am using 16 x 2 LCD
0,0 is display voltage of battery ( top line)
1,0 is displaying on & off status of charging process (bottom line)

I want to use bottom line to display 3 thing and I want top one to just display voltage all the time
bottom line I want to first display if charging is on or off for few seconds
than clear that and display frequency for few seconds
than clear that display some name for few second
and repeat the cycle means go back to charging on or off and just repeat tht

please tell me if this can be done
I already have code to display all 4 thing I just need help display them all
1 by 1
thanx

GaryP

I can't understand the problem. If you want to replce something on the second line, why don't you just write over it?

  lcd.setCursor(0,1); //change position to first character on the second row

Cheers,
Kari
The only law for me; Ohms Law: U=R*I       P=U*I
Note to self: "Damn! Why don't you just fix it!!!"

floresta

#2
Mar 26, 2011, 03:04 pm Last Edit: Mar 26, 2011, 03:05 pm by floresta Reason: 1
To program efficiently write the comments first, then add the code.  Here are the comments.

in loop()

Set cursor to beginning of first line
Display voltage

Set cursor to beginning of second line
Display enough spaces to cover up the name (see below)
Display charging information
Delay

Set cursor to beginning of second line
Display enough spaces to cover up the charging information
Set cursor to beginning of second line
Display frequency information
Delay

Set cursor to beginning of second line
Display enough spaces to cover up the frequency information
Set cursor to beginning of second line
Display name
Delay


Don

Go Up