1 2 Previous Next 17 Replies Latest reply on Feb 2, 2016 2:10 AM by MihneaAM

    I2C + LCD LCM1602 Problems

    mcabral

      Hi there,

       

      I have an intermittent problem with an i2c LCD connected to the my Edison. Running this simple program (see below) produces different results:

       

      + Sometimes "Hello World!" gets printed;

      + Sometimes I get a row with all "pixels" completely lit;

       

      As I said I can't replicate it - running the program below from the command line produces the two above results randomly.

       

      #include "lcm1602.h"
      #include <unistd.h>
      
      int
      main(int argc, char **argv)
      {
          upm::Lcm1602* lcd = new upm::Lcm1602(6, 0x27);
          lcd->setCursor(0,0);
          lcd->write("Hello World!");
          lcd->close();
          return 0;
      
      }
      

       

      Any hints on how to debug this are greatly appreciated

       

      Thanks!

        1 2 Previous Next