![](templates/subSilver/images/CCSLogo.jpg) |
![CCS C Software and Maintenance Offers](templates/subSilver/images/forumAd6.jpg) |
View previous topic :: View next topic |
Author |
Message |
Salenko
Joined: 08 Sep 2008 Posts: 84
|
LCD - blink a line ? (solved) |
Posted: Sun Dec 20, 2009 11:33 am |
|
|
Hi there,
is this possible to make an entire line blinking on LCD ?
I use flex_lcd420 driver, what should I add to my code then ?
Code: | lcd_putc(" LINE 1 ") |
thanks.
Last edited by Salenko on Mon Dec 21, 2009 2:38 am; edited 1 time in total |
|
![](templates/subSilver/images/spacer.gif) |
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Sun Dec 20, 2009 2:36 pm |
|
|
There is no "per character" blink attribute. You have to blink it with code.
Try this program. This is for a 16x2 LCD.
Code: |
#include <16F877.H>
#fuses XT, NOWDT, BROWNOUT, PUT, NOLVP
#use delay(clock=4000000)
#use rs232(baud=9600, xmit=PIN_C6, rcv=PIN_C7, ERRORS)
#include "flex_lcd.c"
//======================================
void main()
{
char line1[17] = {"Hello World"};
char line2[17] = {"This is line 2"};
char blank_line[17] = {" "};
lcd_init();
// Displays lines 1 and 2.
printf(lcd_putc, "%s", line1);
lcd_gotoxy(1,2);
printf(lcd_putc, "%s", line2);
while(1)
{
// Display line1 text for 1/2 second.
lcd_gotoxy(1,1);
printf(lcd_putc, "%s", line1);
delay_ms(500);
// Blank line1 for 1/2 second.
lcd_gotoxy(1,1);
printf(lcd_putc, "%s", blank_line);
delay_ms(500);
}
} |
|
|
![](templates/subSilver/images/spacer.gif) |
Salenko
Joined: 08 Sep 2008 Posts: 84
|
|
Posted: Mon Dec 21, 2009 2:37 am |
|
|
Thank you Mr PCM. ![Wink](images/smiles/icon_wink.gif) |
|
![](templates/subSilver/images/spacer.gif) |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|