Monday, September 23, 2024

LCD I2C Module Test

/*

 Sunil_Singh_STEM

*/


#include <Wire.h>

#include <LiquidCrystal_I2C.h>


LiquidCrystal_I2C lcd(0x27, 16, 2); // set the LCD address to 0x27 for a 16 chars and 2 line display


void setup() {

  lcd.init();         // initialize the lcd

  lcd.backlight();    // Turn on the LCD screen backlight

}


void loop() {

  lcd.setCursor(2, 0);

  lcd.print("Hello World.! ");

  delay(3000);

  lcd.clear();


  lcd.setCursor(2, 0);

  lcd.print("This is Sunil ");

  lcd.setCursor(2, 1);

  lcd.print("Screen Test");

  delay(3000);

  lcd.clear();

}


No comments:

Post a Comment

MUD Three Mode operation Manual Automatic GPS

 Code for three mode operation: /*   3-Mode Headlight Controller   - Manual mode (driver uses a toggle to pick high/low)   - Auto mode (LDR...