incognito_prince
Newbie level 1
Hi..
I'm using ATMega8535 to control my 2x16 LCD. My problem is when I use sprintf to convert the number to be displayed on LCD the LCD repeat the character after the desired character that I want to display. Anyone can help me? Thanks before..
here is the code:
char buff[33];
......
while(1)
{
//lcd_gotoxy(2,0);
//lcd_putsf("Actual Time");
lcd_gotoxy(0,0);
sprintf(buff,"%02d:%02d:%02d",hour,minute,second);
lcd_puts(buff);
detect_key();
if(dtkey==0xC)
{
jump=1;
menu();
}
}
.......
I'm using ATMega8535 to control my 2x16 LCD. My problem is when I use sprintf to convert the number to be displayed on LCD the LCD repeat the character after the desired character that I want to display. Anyone can help me? Thanks before..
here is the code:
char buff[33];
......
while(1)
{
//lcd_gotoxy(2,0);
//lcd_putsf("Actual Time");
lcd_gotoxy(0,0);
sprintf(buff,"%02d:%02d:%02d",hour,minute,second);
lcd_puts(buff);
detect_key();
if(dtkey==0xC)
{
jump=1;
menu();
}
}
.......