Chipkit UNO and Arduino LCD shield example

In this example we connected an Arduino LCD shield to our Chipkit UNO and displayed some basic text.

here is a typical example of this shield, its a low cost 16 x 2 LCD and is good for many projects, from the picture you can see it also has five buttons which can also be useful for navigating through menus

arduino lcd keyboard shield
arduino lcd keyboard shield


This basic example will simply display hello world and do some counting

#include <LiquidCrystal.h>
// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(8, 9, 4, 5, 6, 7);
void setup() 
  // set up the LCD's number of columns and rows: 
  lcd.begin(16, 2);
  // Print a message to the LCD.
  lcd.print("hello world!");
void loop() {
  // set the cursor to column 0, line 1
  lcd.setCursor(0, 1);
  // print the number of seconds