Programming Examples
Arduino program to run a counter and display in LCD
Write a Arduino program to print the Counter value in LCD 16 x 2
#include
int seconds = 0;
Adafruit_LiquidCrystal lcd(0);
void setup()
{
lcd.begin(16,2);
lcd.print("Start");
}
void loop()
{
lcd.setCursor(0, 1);
lcd.print(seconds);
lcd.setBacklight(1);
delay(500); // Wait for 500 millisecond(s)
lcd.setBacklight(0);
delay(500); // Wait for 500 millisecond(s)
seconds += 1;
}
Output