A 16x2 LCD display is very basic module and is very commonly used in various devices and circuits. A 16x2 LCD means it can display 16 characters per line and there are 2 such lines. In this LCD each character is displayed in 5x7 pixel matrix.
CIRCUIT DIAGRAM
CODE
//import LiquidCrystal library
#include<LiquidCrystal.h>
//create instance, pass pin numbers
//RS, EN, D4,D5,D6,D7
LiquidCrystal lcd(13, 12, 11, 10, 9, 8);
void setup()
{
//Serial.begin(9600);
//use begin function to activate LCD
//arguments: columns, rows of LCD
lcd.begin(16, 2);
}
void loop()
{
lcd.setCursor(5,0); //col:5,row:0
lcd.print("JAMES");//6 (total:16)
lcd.setCursor(3,1); //col:3,row:1
lcd.print("BOND MOVIE");
}
Comentarios