/* Program : LED Demo7
BY : Phudit Simtaong No.13 M.5/1
*/
#include <LiquidCrystal_I2C.h> //ชุดคำสั่งที่ถูกรวบรวมไว้ให้แล้ว include=รวมกัน
LiquidCrystal_I2C lcd(0x27, 16, 2); //0x27=adress
int myCount=98;
void setup() {
lcd.init(); //ติด่อ
lcd.backlight(); //**อย่าลืมกำหนด**
lcd.setCursor(1, 0); //กำหนดการปรากฏ
lcd.print("Hello, Winny!!");
delay(2000);
}
void loop() {
lcd.clear();
lcd.setCursor(2, 0);
lcd.print(myCount);
myCount=myCount-2;
if(myCount<2){
myCount=98;
}
delay(200);
}