// nazwa salsabila kinanti //
// pts semester 1 //
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
LiquidCrystal_I2C lcd(0x27,16,2);
const int sensorPIN = 13;
void setup() {
pinMode(sensorPIN, INPUT);
lcd.init();
lcd.backlight();
}
void loop(){
int sensorValue = digitalRead(sensorPIN);
if (sensorValue == HIGH){
lcd.clear();
lcd.setCursor(0, 0);
lcd.print("API TERDETEKSI");
}
if (sensorValue == LOW){
lcd.clear();
lcd.setCursor(0, 0);
lcd.print("SENSOR API");
lcd.setCursor(0, 1);
lcd.print("STANDBY");
}
delay(500);
}