#include<Wire.h> #include<LiquidCrystal_I2C.h>LiquidCrystal_I2Clcd(0x27,16,2);//sometimes the LCD adress is not 0x27. Change to 0x3f if it doesn't work.voidsetup(){lcd.init();//Init the LCDlcd.backlight();//Activate backlight lcd.print("BUTTON");//Intro lcd.setCursor(0,1);lcd.print("CHECK");delay(3000);}voidloop(){lcd.clear();lcd.print("VALUE:");lcd.print(digitalRead(4));//The value of the buttondelay(300);}
Comments
Please log in or sign up to comment.