Warning to users of some vendors LCD keypad shields

I read the beginning of the thread, then did some tests with my LCD shield (wow!) and figured out that the absolutely best and fastest way to deal with this small design oversight is to simply clip the D10 from every LCD shield. I am sure at some point a software fix will come back to hunt me, so this way I remember, LCD shield, clip 10th pin. 2sec fix and visible to naked eye if the fix is in.
Other permanent solution if power consumption is really big issue is to hardwire the shield bg led to ground through some resistor and effectively lower the backlight to 50 % or so where it is still visible.

Oscarko:
I am sure at some point a software fix will come back to hunt me,

You can't ever fix this h/w problem in s/w.
You have to fix or alter the h/w to completely eliminate the potential problem.
That said, there were some s/w work arounds proposed that can be used to offer backlight on/off control
(no dimming) without modifying the h/w. However, those s/w work arounds only avoid the problem and so the actual problem still exists and can cause issues when other s/w is used.

--- bill

Thanks, great intel!

hmmm.... i'm not sure but i just had my 16x2 lcd keypad. and i use:

analogWrite(10,0); //to turn OFF the backlight

and even dim the backlight with:
analogWrite(10,50); // 0=OFF; 255=MAX power.

jazreenZIA88:
hmmm.... i'm not sure but i just had my 16x2 lcd keypad. and i use:

analogWrite(10,0); //to turn OFF the backlight

and even dim the backlight with:
analogWrite(10,50); // 0=OFF; 255=MAX power.

Did you run the diagnostic test sketch to check to see if your shield has the h/w issue?

--- bill

no.

maybe they already fixed it. I just had the 16x2 lcd with keypad recently.
lucky me :slight_smile:

jazreenZIA88:
no.

maybe they already fixed it. I just had the 16x2 lcd with keypad recently.
lucky me :slight_smile:

Maybe? I like to deal with certainties.
Unless you visually inspected it, used an ohm meter to verify it, or ran the diagnostic sketch, you can't know if it has been fixed or not.

Using analogWrite() and seeing dimming is no verification that it works as the broken hardware will also appear to work when used that way.

--- bill

my 1602 lcd keypad shield have "D1 ROBOT" markings.
when you say "visually inspecting" it, does it translate to my shield and/or uno board getting fried?

i let it run for more than 30 minutes already using analogWrite and it appears okay to me.
i'm into software and noob in arduino :smiley:

jazreenZIA88:
my 1602 lcd keypad shield have "D1 ROBOT" markings.

Irrelevant. What matters is the circuit design.

when you say "visually inspecting" it, does it translate to my shield and/or uno board getting fried?

I mean: Did you visually look at the board close enough to follow all the traces in the etch in the PCB to verify the circuit does not have the design with the issue.
From your comments so far it sounds like you did not do this.

i let it run for more than 30 minutes already using analogWrite and it appears okay to me.

That means nothing. Like I have said and stressed in the first post of this thread,
the broken h/w will appear to work.
Keep in mind that there is a big difference between something that "appears ok" and actually verifying that it truly does work correctly without issues.

i'm into software and noob in arduino :smiley:

Just run the diagnostic sketch I provided. It will tell if if your h/w has this issue.
You could have downloaded and run the diagnostic sketch in much less than 30 minutes.
Why continue down paths that won't provide the answer you need?

--- bill

Warning arrived a little too late for me. I just plugged in a new DF Robot LCD shield and I'm pretty sure it fried some of the hardware components on my Arduino Uno. I can use some real basic sketches on the Arduino but I suspect it did real damage internally as I can no longer run some of my most current sketches which were fine up until I plugged in the DF Robot LCD.

I'm staying away from this product for sure. It's was a jinx or worse for my Uno.

jazreenZIA88:
my 1602 lcd keypad shield have "D1 ROBOT" markings.
when you say "visually inspecting" it, does it translate to my shield and/or uno board getting fried?

i let it run for more than 30 minutes already using analogWrite and it appears okay to me.
i'm into software and noob in arduino :smiley:

By visually inspecting, I mean following the etch on the PCB to see how it connects to the transistor.
If there is not a resistor in series with the transistor then the backlight circuit is broken and is overloading the AVR.

Just because it appears to be working doesn't mean that it is ok.
It so easy to run the diagnostic sketch, I don't see the reason to not to.
In fact it would have given you the answer in just a couple of seconds whereas even after running your sketch for 30 minutes you still don't know the answer.

For those that are concerned about your lcdkeypad, but would like to use backlight control, you can use my hd44780 library.
It contains API functions to control a backlight circuit.
When the library is configured for backlight control, it will test the backlight circuit and if the backlight circuit is broken, it will automatically use safe methods to control the backlight.
The library has API functions to control the backlight that supports on/off and dimming. However, if you have a broken backlight circuit, the library will automatically protect the AVR by disallowing dimming and will revert to safe on/off control i.e. all pwm values other than 0 will be on, and 0 will be off and the library will never drive the output pin HIGH to turn on the backlight.

The library is called "hd44780" and is available in the IDE library manager.
Here is a link to the git hub page: GitHub - duinoWitchery/hd44780: Extensible hd44780 LCD library

The i/o class is called hd44780_pinIO
While not a direct drop in replacement for the LiquidCrystal library, it is API function compatible.
It includes an example sketch to test the keypad backlight circuit ( LCDKeypadCheck ) if you want to test or verify if your keypad has the backlight circuit issue.
hd44780_pinIO also quite a bit faster than the stock LiquidCrystal library and supports some additional capabilities.
See the github page for a list of the supported API functions.

--- bill

I used the sketch of bill "bperrybap" and it detects the BL circuit as BAD.
I soldered a 10k smd resistor according to the new schematic in and the sketch gave me a GOOD.
Backlight at full brightness - no change visible.

Thanks

DrBockel

The DF Robot shield I got from Deal Extreme in October 2015 also has the excess current problem so I did a bit of investigating.

I unsoldered the LCD to see what was underneath. In my case R7 is 1k ohm and the transistor is marked J3Y which according to the data sheet is a S8050 NPN rated at 0.5A with Hfe of 120-350.

To turn the transistor fully on, and supply the backlight with the 18.5mA it needs:
I(base) = I(collector)/Hfe = 18.5/120 = 0.15mA flowing into the base of the transistor.

To achieve a base current of 0.15mA the base resistor needed is:
Vcc-Vbe/Ibase = (5V-0.7V)/0.15mA = 29k ohm. I had only had a 10k resisotor so used that.

I reused the 1k ohm resistor to connect from the PWM pin 10, to the 29k (10k) base resistor. The combination limits the base current to 5mA.

As a side note, I used pin 3 for PWM as pin 10 conflicts with the Chip Select line on my data logger shield. I tried pin 9 but it made the backlight flicker instead of dimming. The other PWM pins had no effect. I have no idea why.

While I had the LCD off the board I made some measurements with the arduino, the sheild with and without LCD screen and the backlight on it's own.

Backlight        Arduino,       Arduino,         Arduino,                 LCD only                Arduino, 
brightness       LCD shield,    LCD sheild       No LCD shield            No Arduino,             Modified shied
                 LCD            No LCD           No LCD                   No LCD sheild           LCD
Full             79mA           58mA             -                        -                       67mA           
Minimum          56mA           55.1mA           -                        -                       55mA
Off              55mA           55mA             50mA                     18.5mA                  55mA

So the current draw for the components are:
over 125mA Unmodified shield with backlight full brightness, LCD and Arduino Uno R3
18.5mA Backlight only, no LCD screen.
0.1mA LCD screen, no backlight
5mA LCD shield only, no LCD screen, including modified resistor and power LED, backlight off
8mA LCD shield only, no LCD screen, including modified resistor and power LED, full brightness
50mA Arduino Uno R3 only

It amazing how many of these companies producing products don't have anyone with the technical expertise to know how to properly control a transistor. That seems like some pretty basic EE 101 knowledge.
Even worse, doing it correctly does not affect the product's manufacturing costs.

--- bill

bperrybap:
It amazing how many of these companies producing products don't have anyone with the technical expertise to know how to properly control a transistor. That seems like some pretty basic EE 101 knowledge.
Even worse, doing it correctly does not affect the product's manufacturing costs.

To be fair mine has been sitting unused for a few years so it could be part of the original batch. I imagine a gazillion of these were made and will continue to surface until stocks are gone or people like me finally notice.

regardless of the age of a given shield, this issue never should have existed because it is broken by design.
I always wondered if the original design used an FET instead of a transistor which would not have the issue. But then somebody decided to save a few pennies and substituted the part with a transistor and that is what broke things. - i.e. management, or the dumb people that cloned/stole the design, broke the engineers working original design. But that is just a wild a guess.
But it could be as simple as a dumb "engineer" actually designed it that way.
However it happened, many vendors were simply zeroxing this design to make their shields and not one of them bothered to look at the schematic to notice that the transistor was not wired up correctly.

--- bill

Hi all, I too have one of those cheap chinese clone LCD Shields, ran the test sketch and sure enough it needs fixing. As I'll be using my LCD shield on top of an Ethernet shield and I have already added one row of stackable headers to accomodate the large ethernet socket I thought I could put a 1N5818 diode in between those two headers at d10 (just pluck the pin from the stackable header) and avoid cutting traces etc. (see attached pic). Will this be enough or do I absolutely have to place this diode up and cut that trace? Also, please confirm I'm using the correct polarity on the diode (anode to LCD shield on top, cathode to ethernet shield/arduino below). THanks

1N5818_LCD_Shield.png

I have a brand new (March 2017) SainSmart with this issue and a brand new SODIAL 1602 without the issue. I guess this is a vote in favor of the I2C displays, going forward.

masbass, mrred128,
Again, you don't have to do anything if your code doesn't ever use pin 10.
The backlight will be on all the time.
If you still want to have backlight control, simply use my hd44780 library with the hd44780_pinIO class like I mentioned in the very first post.
It will auto detect the issue and automatically work around it in s/w.
So not only do you get backlight control (which the standard LiquidCrystal library doesn't give you) but hd44780 will do the backlight control in a safe way that works even on the shields with broken hardware.
With broken h/w you won't get dimming but still get on/off control.
Also, hd44780 is quite a bit faster than the bundled LiquidCrystal library.

That said, I do prefer using the I2C backpacks and the hd44780 library package makes using them very easy since it can auto detect everything.

--- bill