Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <Wire.h>
- #include "LiquidCrystal.h"
- // Connect via i2c, default address #0 (A0-A2 not jumpered)
- LiquidCrystal lcd(0);
- void setup() {
- // set up the LCD's number of rows and columns:
- lcd.begin(16, 2);
- // Print a message to the LCD.
- lcd.print("hello, world!");
- }
- void loop() {
- // set the cursor to column 0, line 1
- // (note: line 1 is the second row, since counting begins with 0):
- lcd.setCursor(0, 1);
- // print the number of seconds since reset:
- lcd.print(millis()/1000);
- lcd.setBacklight(HIGH);
- delay(1000);
- lcd.setBacklight(LOW);
- delay(1000);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement