View previous topic :: View next topic |
Author |
Message |
project2010
Joined: 14 Mar 2010 Posts: 21
|
what mean LCD code "\r" "\b"? |
Posted: Tue Apr 13, 2010 1:00 pm |
|
|
I am using the Flexible LCD driver for 20x4 LCDs.
I have some question on \X
"\f" = flash the LCD
"\n" = nextline
Q1
case '\n':
lcd_gotoxy(1,2); <i know gotoxy function but go (1,2) if used in line3 it will auto go to line 4?why? ( i try it is work ,but i don;t understand how does it work....)
Q2
\b = mean???nth happen?
case '\b':
lcd_send_byte(0,0x10);
break;
Q3
\r mean???nth happen?
Best Wishes |
|
![](templates/subSilver/images/spacer.gif) |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Tue Apr 13, 2010 1:03 pm |
|
|
Quote: | "\f" = flash the LCD |
Don't assume a function, based upon guessing the abbreviation.
The Flex drivers are based on the original CCS drivers. Read the
documentation at the start of the CCS driver files to get an explanation
of the commands. Look in this file:
Quote: | c:\program files\picc\drivers\lcd.c |
|
|
![](templates/subSilver/images/spacer.gif) |
project2010
Joined: 14 Mar 2010 Posts: 21
|
|
Posted: Tue Apr 13, 2010 1:21 pm |
|
|
PCM programmer wrote: | Quote: | "\f" = flash the LCD |
Don't assume a function, based upon guessing the abbreviation.
The Flex drivers are based on the original CCS drivers. Read the
documentation at the start of the CCS driver files to get an explanation
of the commands. Look in this file:
Quote: | c:\program files\picc\drivers\lcd.c |
|
Dear sir, i find that file and read it
\f Clear display
but there are no \r explain??
why \b much be use in \b\b ? |
|
![](templates/subSilver/images/spacer.gif) |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Tue Apr 13, 2010 1:57 pm |
|
|
Quote: | but there are no \r explain?? |
I did a search of the Flex 4x20 post, and there is no '\r' anywhere in
the post. '\r' is not used with the LCD. It's used with printf to a serial
port on the PIC.
Quote: | why \b much be use in \b\b ? |
You're right. That's a mistake. The extra \b is in there because it has a leading space in front of it like this:
Code: | printf(lcd_putc," \b\b"); |
But it doesn't need to have the leading space. It should be like this
with just one backspace:
Code: | printf(lcd_putc,"\b"); |
I'll fix it in the Code library post. |
|
![](templates/subSilver/images/spacer.gif) |
|