Forum >Replies by rlabatt
userhead rlabatt
Replies (1)
  • You Reply: Thanks Hector

    I am using Ardunio-0022, which is the latest version on the Arduino.cc web site.  The code I am using for this initial hello world project is the DFRobot sample code for the LCD1602.  I have not changed a thing.  Here is the code in its entirety:

    [code]///Arduino Sample Code
    ///www.DFRobot.com
    ///Last modified on 17th September 2010

    #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
     
      // Print a message to the LCD.
      lcd.backlight();
      //lcd.setCursor(0, 1);
      lcd.print("Hello, world!");
    }

    void loop()
    {
      // when characters arrive over the serial port...
      if (Serial.available()) {
        // wait a bit for the entire message to arrive
        delay(100);
        // clear the screen
        lcd.clear();
        // read all the available characters
        while (Serial.available() > 0) {
          // display each character to the LCD
          lcd.write(Serial.read());
        }
      }
    }[/code]

    As you can see, the include line is [font=courier]#include LiquidCrystal_I2C.[/font]h, which I can only assume is specific to the DFRobot 1602 display and driver. 

    Am I off base? 

    Thank you as well for the Syncplicity suggestion.