jmyean

Learning How to Use an LCD

May 10th, 2019
62
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /*
  2.  * Jung Min Yean
  3.  * Learning How to Use a LCD
  4.  * 05/07/19
  5.  */
  6.  
  7. #include <LiquidCrystal.h>
  8. LiquidCrystal lcd(12,11,5,4,3,2);
  9.  
  10.  
  11.  void setup()
  12. {
  13.   lcd.begin(16,2);
  14. }
  15.  
  16. void loop()
  17. {
  18.    lcd.setCursor(5,0);
  19.   lcd.print("HELLO");
  20.   lcd.setCursor(0,1);
  21.   for(int i = 0; i < 16; i++)
  22.   {
  23.     lcd.setCursor(i,1);
  24.     lcd.print("JUNG");
  25.     delay(1000);
  26.     lcd.clear();
  27.     delay(10);
  28.   }
  29. }
Add Comment
Please, Sign In to add comment