How should I do it? The following "test"-program does not work and I don't know why?
Only the last "Valmis!!" is printed to LCD. Before that - nothing.
Code: Select all
void main()
{
int a;
char *abc;
TRISB = 0; // PORTB asetetaan lähdöksi
Lcd_Init(&PORTB); // Alustetaan LCD
Lcd_Cmd(Lcd_CURSOR_OFF); // Kursori pois
while (1==1)
{
Lcd_Cmd(Lcd_CLEAR); // Tyhjennetään näyttö
for (a = 0; a<9; a++)
{
IntToStr(a, abc);
Lcd_Out(1, 2, abc); // Tulostetaan näyttöön, 1. rivi, 1. sarake
Delay_ms(200);
}
Lcd_Out(1, 3, "Valmis!!"); // Tulostetaan näyttöön, 1. rivi, 1. sarake
Delay_ms(1000);
}
}