Pages: [1]   Go Down
Author Topic: [SOLVED]Problems with LCD  (Read 573 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 1
Posts: 16
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Greetings and salutations. Some time ago I bought this LCD to play around with on my Arduino. The one I got was this: http://www.ebay.com/itm/1602-HD44780-Character-Display-Module-LCM-blue-blacklight-16x2-C-/370851407739?pt=LH_DefaultDomain_2&hash=item565877677b


After playing around a bit, I understood that I would get into trouble with available ports so I decided to get one of these: http://www.ebay.com/itm/281234403721?ssPageName=STRK:MEWNX:IT&_trksid=p3984.m1439.l2649 to help me out on that.

So, when hooking it all up I get rubbish. I use the correct library (I think), the LiquidCrystal_I2C and I have deleted the old LiquidCrystal library. When uploading the HelloWorld_I2C example, the backlight of the LCD keeps blinking and I can see some sort of stuff appearing on the display, but no readable text.

Has anyone experienced this behaviour?
« Last Edit: January 22, 2014, 02:53:19 pm by luddiluddludde » Logged

NSW Australia
Offline Offline
Faraday Member
**
Karma: 92
Posts: 3655
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

"Rubbish", or a line of solid blocks?

You need to use the "LCDguesser" script to determine the correct descriptor.
Logged

Netherlands
Offline Offline
Jr. Member
**
Karma: 0
Posts: 69
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

hey! I encountered this problem a couple of days ago t. So, i hooked it all up according to this:
gnd - gnd
vcc -5v
sda- A4
sca - A5
After, I uploaded this code = http://arduino-info.wikispaces.com/LCD-Blue-I2C#v1
see if it works, if not give me a message!

kind regards,
-Goldfile
Logged

Need help? Don't hesitate to ask me!

Offline Offline
Faraday Member
**
Karma: 100
Posts: 6044
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Does he need to know about the 4.7k pullups for A4 & A5 or do you think those are built into the lcd bd. ?
Logged

Arduino UNOs, Pro-Minis, ATMega328, ATtiny85, LCDs, MCP4162, keypads,
DS18B20s,74c922,nRF24L01, RS232, SD card, RC fixed wing, quadcopter

Netherlands
Offline Offline
Jr. Member
**
Karma: 0
Posts: 69
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

well, I have the same LCD, only 4line, and the same adapter for the lcd, and it worked fine for me, so they must be built in? What do you think bud?
I just uploaded a new library that came with the seller, and plugged it in, as the link above does (when you scroll up you see it)
and it worked
kind regards,
-Goldfile
« Last Edit: January 22, 2014, 11:08:52 am by Goldfile » Logged

Need help? Don't hesitate to ask me!

Offline Offline
Newbie
*
Karma: 1
Posts: 16
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Seems like I got it working. No idea what made it work, but I think it could have something to do with the wrong library... I used this at first: https://bitbucket.org/fmalpartida/new-liquidcrystal/downloads/LiquidCrystal_V1.2.1.zip and it produced a lot of rubbish. Not solid blocks, but something that looked like sprites of some kind. But no text as the sketch indicates.

Then I read up on the descriptor thing, and replaced something in the sketch code for the HelloWorld_I2C :

I replaced this:
Code:
LiquidCrystal_I2C lcd(0x27);
with this:
Code:
LiquidCrystal_I2C lcd(0x27, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE);
and it worked fine. But then I went back to just using this
Code:
LiquidCrystal_I2C lcd(0x27);
and it still worked...
What I also did before this, was to download the library again and install it... So not really sure what made it work smiley-wink.

But it works, now over to the next couple of steps for my many projects smiley-wink.

Thanks for all the good help smiley-grin.

Update: I played around a bit more, and I have to use this:
Code:
LiquidCrystal_I2C lcd(lcdAddr, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE);
to make it work.
I guess some code was still residing in the arduino, since I got this when trying to upload the new sketch:
Code:
avrdude: stk500_getsync(): not in sync: resp=0x00
« Last Edit: January 22, 2014, 03:11:28 pm by luddiluddludde » Logged

Offline Offline
Faraday Member
**
Karma: 100
Posts: 6044
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Did you ever try the "Guesser" program that Paul suggested ?
Logged

Arduino UNOs, Pro-Minis, ATMega328, ATtiny85, LCDs, MCP4162, keypads,
DS18B20s,74c922,nRF24L01, RS232, SD card, RC fixed wing, quadcopter

Dallas, TX USA
Offline Offline
Faraday Member
**
Karma: 70
Posts: 2740
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

luddiluddludde,
You may have to dig deeper and figure out what is going on.
I can say with 100% certainty that if you are really using fm's library
that if it worked with this constructor
Code:
LiquidCrystal_I2C lcd(0x27, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE);
That it will not work with this constructor:
Code:
LiquidCrystal_I2C lcd(0x27);

fm created the shortened consructor to support the i2c LCD extra i/o board from
his ElectroFun company.
http://www.electrofunltd.com/2011/10/i2c-lcd-extra-io.html
It is short hand for this constructor:
Code:
LiquidCrystal_I2C lcd(i2cADDR, 6,5,4,0,1,2,3);
Not only is the pin wiring different but there is no backlight control specified.
There is no way the hardware you have would work with both of those two consructors.
You have something else going on.

It is almost a certainty that the shortened constructor does not work
on your board as I have not seen any other i2c lcd backpack that uses the same
wiring as the ElectroFun XtraIO board.

Make sure you don't have multiple i2c lcd libraries installed.

--- bill
Logged

Pages: [1]   Go Up
Jump to: