#include <Wire.h>
#include <LiquidCrystal_I2C.h>

#define I2C_SDA 4
#define I2C_SCL 0

LiquidCrystal_I2C lcd(0x27, 16, 2);

void setup() {
  pinMode(2, INPUT);
  pinMode(18, OUTPUT);
  pinMode(19, OUTPUT);
  Wire.begin(I2C_SDA, I2C_SCL);  
  lcd.init();  
  lcd.backlight();
}

void loop() {
  if (digitalRead(2) == HIGH) {
    digitalWrite(18, HIGH);
    digitalWrite(19, HIGH);
    lcd.print("Chaiwat ");

  } else {
    digitalWrite(18, LOW);
    digitalWrite(19, LOW);
    lcd.clear();
  }
}