Go Down

Topic: SainSmart 20 x 4 LCD wanting to use I2C from Arduino Uno (Read 18 times) previous topic - next topic

AWOL

Quote
how do I "open the serial monitor"

On the Arduino's IDE, the right-most button just above the code pane.
"Pete, it's a fool looks for logic in the chambers of the human heart." Ulysses Everett McGill.
Do not send technical questions via personal messaging - they will be ignored.

Aaron_dyer

Ok I found the serial monitor thing....I have an I2C device at 0x3F  which is cool now I'm getting somewhere...

But I upload my simple code here:   and the LCD backlight just blinks...no characters still....what am I missing??

#include <Wire.h>
#include <LiquidCrystal_I2C.h>

LiquidCrystal_I2C lcd(0x3F,20,4);

void setup()
{
 

lcd.init();
lcd.backlight();
lcd.setCursor(0, 0);
lcd.print("Hello");
lcd.setCursor(0, 1);
lcd.print("World ");

}


void loop()
{

}

fm


This is a dumb question, I know...but how do I "open the serial monitor"  I uploaded the code for the I2C scanner and it compiled fine...but now what?

I did try the new liquid crystal library but which version are you referring to? There are like 10 downloads on that bitbucket page.....

so confusing....and is this for 1.0 or 1.0.1?

I saw some posts of some sainsmarts getting to work, but dammit I want mine to

Get the latest version.

As it says in the wiki:
Quote

To install the library:
* Download the most recent version of the library.
...


version and compatibility:
Quote

== Version ==
Current New LiquidCrystal is the latest zip file in the download section.

The New LiquidCrystal library has been tested and is compatible with Arduino SDK 1.0.1, 1.0 and Arduino SDK 0022.
   

Aaron_dyer

Downloaded......installed in place of old library......still doesn't work.....The address my I2C is communicating on is 0x3F.

I upload the code and the LCD just turns off its backlight and flashes from time to time.

Does anyone know some GOOD -verified working test code for the LCD just to say ANYTHING using an I2C connection?

Aaron_dyer

I am so close I feel it...I just need some new tips....

here is my code:


#include <Wire.h>
#include <LiquidCrystal_I2C.h>




LiquidCrystal_I2C lcd(0x3F, 20, 4);


void setup()
{

  lcd.init();
  Wire.begin(0x3F);
  lcd.print("Hello"); 
  lcd.setCursor ( 0, 1 );       
  lcd.print (" World!"); 
  Wire.endTransmission(); 
}

void loop()
{

}



pins 4 and 5 from arduino Uno plugged into I2C board on 20 x 4 LCD...along with ground and power.....just white pixels on LCD still and the LED backlight flashes from time to time.....

Go Up