Kode praktikum lcd

mail@pastecode.io avatar
unknown
plain_text
a year ago
1.7 kB
9
Indexable
void main (void)
{
lcd_init(16); // LCD module initialization
while (1)
{
lcd_gotoxy(0,0); // kursor di kolom 0 baris 0
lcd_putchar(0x41); //menampilkan string ‘A’
}
}


void main (void)
{
lcd_init(16); // LCD module initialization
while (1)
{
lcd_gotoxy(0,0); //kursor di kolom 0 baris 0
lcd_putchar(0x41); //menampilkan string ‘A’
delay_ms(1000);
lcd_clear();
lcd_gotoxy(0,1); //kursor di kolom 0 baris 1
lcd_putchar(0x30); //menampilkan string ‘0’
delay_ms(1000);
}
}


void main (void)
{
lcd_init(16); // LCD module initialization
while (1)
{
lcd_gotoxy(0,0); //kursor di baris 0 kolom 0
lcd_putsf("Saya belajar"); //menampilkan string “Saya
Belajar”
}
}


void main (void)
{
lcd_init(16); // LCD module initialization
while (1)
{
lcd_gotoxy(0,1); //menempatkan kursor di kolom 0 baris 1
lcd_putsf("Antarmuka LCD"); //menampilkan string
“Antarmuka LCD”
}
}


void main (void)
{
lcd_init(16); // LCD module initialization
while (1)
{
lcd_gotoxy(0,0); //menempatkan kursor di baris 0 kolom 0
lcd_putsf("Saya belajar"); //menampilkan string “Saya
belajar”
lcd_gotoxy(0,1); //menempatkan kursor di kolom 0 baris 1
lcd_putsf("Antarmuka LCD"); //menampilkan string
“Antarmuka LCD”
}
}


void main (void)
{
lcd_init (16);
while (1)
{
int x,y;
for (x=0;x<=16;x++)
{
y=15-x;
lcd_gotoxy(x,0);
lcd_putsf("NAJWA AFIF NUGRAHA");
lcd_gotoxy(y,10);
lcd_putsf("220536609096");
delay_ms(100);
lcd_clear();}
}
}


void main (void)
{
lcd_init (40);
while (1)
{
int x,y;
for (x=0;x<=16;x++)
{
y=15-x;
lcd_gotoxy(x,0);
lcd_putsf("NAJWA AFIF NUGRAHA");
lcd_gotoxy(y,10);
lcd_putsf("220536609096");
delay_ms(100);
lcd_clear();}
}
}