Disclaimer: This is homework.
I'm taking an Arduino class and for our project we have to implement a simple sketch. The hardware involved is the Arduino Mega ADK board and the Electronic Brick Starter Kit. I have been able to successfully communicate with the Arduino with my sketches; other things (like the push-button, and LED's) seem to work, except for the LCD. I've followed numerous tutorials (including the on sample program for LCD's in my second link), but I can't get anything to work. My LCD consistently shows black boxes in the bottom line. From looking around, I see that black boxes show up when the LCD isn't connected properly. However, this is a starter kit which contains cables that you can hook up to a chassis, which gets rid of the pain involved in soldering individual wires. Is there something wrong with my LCD? Here's a simple sketch that I'm unable to get to work:
#include <LiquidCrystal.h>
LiquidCrystal lcd(10,11,12,13,14,15,16);
void setup()
{
Serial.begin( 9600 );
lcd.begin(16, 2);
lcd.clear();
}
void loop()
{
lcd.setCursor(0,0);
lcd.println( "hello world! ");
delay(1000);
}
The pins correspond to BUS2 and I've properly hooked up my cable from BUS2 to the LCD.