6 Replies Latest reply on Oct 5, 2015 5:32 PM by Intel_Peter

    V3.0 Grove LCD Not Displaying Text (JHD1313M2)

    flux2002

      Developing basic "Hello World" example on Edison using JHD1313M2 Grove LCD and release 2.1 Yocto image.  LCD backlight color updates with no issue, but text not displaying at all. 

      • Eclipse and g++ compiles with no errors.
      • Tried on 3 different I2C ports using v2 base shield.
      • Verified LCD is connected to 5V.

      Do I required update header file for JHD1313M2 or is JHD1313M1 adequate?

      • Jhd1313m1(int bus, int lcdAddress = 0x3E, int rgbAddress = 0x62);


      Using the following header files from: C:\Intel\iotdk-ide-win\devkit-x86\sysroots\i586-poky-linux\usr\include\upm, file structure as follows:

      • grove.h, jhd1313m1.h, lcd.h, lcm1602.h, LCDTest.cpp
      • g++ LCDTest.cpp -o output.sh -lupm-i2clcd - lupm-grove -lmraa
      • ./output.sh

       

      LCDTest.cpp code as follows:

      #include "grove.h"

      #include "jhd1313m1.h"

      #include <climits>

      #include <iostream>

      #include <sstream>

      #include <unistd.h>

      int main()

      {

           upm::Jhd1313m1* lcd = new upm::Jhd1313m1(0);

           lcd->setColor(255, 0, 255);             //WORKS

           std::stringstream row_1;

           row_1 << "Hello World";

           lcd->setCursor(0,0);

           lcd->write(row_1.str());                    //DOESN't WORK

          return MRAA_SUCCESS;
      }