# include <LiquidCrystal.h>
LiquidCrystal lcd(13,12,11,10,9,8);
int BUTTON_LOW=28;
void setup() {
// put your setup code here, to run once:
pinMode(28,INPUT);
pinMode(23,OUTPUT);
lcd.begin(16,2);
}
void loop() {
// put your main code here, to run repeatedly:
int BUTTON_LOW_READ = digitalRead(BUTTON_LOW);
if (BUTTON_LOW_READ == HIGH);
{
lcd.clear();
lcd.setCursor(0,0);
lcd.print("Switch is pressed");
lcd.setCursor(0,1);
lcd.print("LED is ON");
delay(20);
}
if (BUTTON_LOW_READ == LOW);
{
lcd.clear();
lcd.setCursor (0,0);
lcd.print("Switch not Pressed");
lcd.setCursor (0,1);
lcd.print("LED is OFF");
delay(20);
}
}