display works
parent
c1fda6bfdb
commit
1b39cb59e5
@ -0,0 +1,30 @@
|
||||
#include <Arduino.h>
|
||||
#include <LiquidCrystal_I2C.h>
|
||||
#include <ESP8266WiFi.h>
|
||||
#include <PubSubClient.h>
|
||||
|
||||
const char *ssid = "PET Aflytningsvogn #43";
|
||||
const char *password = "zwr33htm";
|
||||
|
||||
const char *mqtt_server = "192.168.24.215";
|
||||
|
||||
// set the LCD number of columns and rows
|
||||
int lcdColumns = 16;
|
||||
int lcdRows = 2;
|
||||
|
||||
// set LCD address, number of columns and rows
|
||||
LiquidCrystal_I2C lcd(0x3f, lcdColumns, lcdRows);
|
||||
|
||||
void setup(){
|
||||
lcd.init();
|
||||
lcd.backlight();
|
||||
}
|
||||
|
||||
void loop(){
|
||||
// set cursor to first column, first row
|
||||
lcd.setCursor(0, 0);
|
||||
// print message
|
||||
lcd.print("Piss off, ghosts!");
|
||||
// clears the display to print new message
|
||||
lcd.clear();
|
||||
}
|
||||
Loading…
Reference in New Issue