Arduino LCD Backlight Fix

24K215

Intro: Arduino LCD Backlight Fix

As it stands many Arduino LCD Shields like this have a rather unfortunate design that prevents Dimming of the backlight. In most applications dimming is not required but if you have constructed a Star tracker and the backlight is at full brightness it ruins your dark vision by closing down your pupils every time you look at it.

The problem is well documented here with two main solutions, one involves using a resistor the other and recommended solution uses a diode. Both require soldering the component "dead bug" style onto exposed circuit track. I have a shield labelled DFROBOT other makers use the same basic design but there is no guarantee that the layout will be exactly same so if yours is a different make do some surfing to see what others are saying.

A few different diodes have been used and I found it quite confusing to decided which one to use, it appears that Germanium diodes are best and will allow the backlight to be fully dimmed using PWM code to control the backlight through pin D10 failing to protect your UNO before doing this mod may burn out the circuits on the processor chip.

Here is some text from the referenced web site

Another issue is that you can't use a typical silicon signal diode like a 1n4148 as the voltage
drop is too high and the backlight will not go all the way off. I used a germanium diode 1n34a which worked perfectly and the AVR no longer gets warm under heavy LCD activity with the backlight on.

As an alternative a 1/8th watt ~510 ohm resistor could be used. Not as power efficient as the diode when d10 is high (wastes about 8ma) but works ok. (backlight will also not be 100% off but so dim that you won't see it)

STEP 1: Modify the Board Ready for the Diode

To test if your shield has the dodgy build you first run this test sketch provided by Bill "bperrybap" who has done so much to help work around this problem ( that only exists if you want to dim the backlight ) read the comments from others before doing it. My shield blinked quickly and displayed "BL Circuit BAD" so because I want to dim the backlight for Astrophotography I will modify mine.

On this LCD shield you have to find the track that requires the modification. What we are aiming to do is cut the track, then bridge the break with the diode.

Image one shows that I started at pin D10 and very carefully exposed the track by scraping the varnish of very gently, following the track till you have exposed enough to complete the task . Step two is to cut a gap in the track, do this with great care not to damage other tracks close by. Diodes that have been said to work are listed below, I don't think its to critical but germanium appear to work best.

1N34A diode

1N5231 diode

BAT43 Schottky

STEP 2: Solder the Diode

I've said it before but the glass case is fragile so bend the leads with care so that they will land on the contact points you are using, Tin the track on the board and the diode leads then carefully solder in place.

STEP 3: Support the Diode

After soldering I decided to use a little epoxy to ensure it would not be strained while handling .

I have downloaded a couple of images from the web to show how others have soldered their diodes.

STEP 4: Re Test Your LCD

by running the test script again I now get a good result, it should now be safe to address pin D10 using PWM in the code to dim the backlight for my astrophotography.

The Sketches attached allow you to run a stand alone Arduino and LCD shield, pressing the buttons will brighten or dim the display.

The star tracker Sketch is for use with the stepper motor and Arduino build but the display is set to very dim and can be set within the sketch for brighter or dimmer to suit your needs, here is the link to my build

https://www.instructables.com/id/Star-Tracker-Using...

line 55 pinMode(10, OUTPUT); //Set pin D10 as an output to control the backlight brightness
line 56 analogWrite(10,5); // Set the brightness of the backlight

Lines 55 and 56 set up the pin, then you can experiment with values to get the brightness you need I have set mine at 10,5 has the backlight hardly visible just as I want, 10,255 would be full brightness.

STEP 5: Additional Information Sent to Me

Mike from HobbyTronics sent me information and images too he used a small surface mount BAT43 Schottky Diode that makes a very neat installation . Thanks Mike

4 Comments

I used the method from the link below. It requires a 2N3904 transistor.
Collector => 5V
Base => 10k resistor => Arduino PWM pin
Emitter => LCD Pin 15

A button or switch can be connected to a different pin on the Arduino, then used to toggle the brightness.

I'm not using a shield, so I cannot speak to the ease of incorporating this.


https://forum.arduino.cc/index.php?topic=207772.ms...
Apologies for the automatic translation.

Thank you very much for your article, it was very useful to me. I bought a shield identical to the one you show, and without your article I could not turn off the backlight. Now I did it from the arduino program itself: I turn on or turn off that light when necessary.

However, I did not do the procedure you described, since I do not have enough skill. What I did is fold the # 10 leg that goes to the arduino so that it remains on the air, without connection. And on that bent leg (without connection to Arduino), I soldered a transistor that connects or disconnects it from the ground. It works perfect!

Thank you.

Disculpas por la traducción automática.

Muchas gracias por tu artículo, me fue de muchísima utilidad. Compré un escudo idéntico al que muestras, y sin tu artículo no hubiese podido apagar la luz de fondo. Ahora lo hice desde el propio programa de arduino: enciendo o apago esa luz cuando es necesario.

No obstante, no lo hice el procedimiento que describiste, dado que no tengo la suficiente habilidad. lo que hice es doblar la pata #10 que va al arduino de forma que quede al aire, sin conexión. Y en esa pata doblada (sin conexión a Arduino), soldé un transistor que lo conecta o desconecta de tierra. Funciona perfecto!

Gracias.

Strange... Schottky diodes haven't any threshold. I thought backlight was controled via a pwm signal, or a constant current generator.

Even a 1/8th watt ~510 ohm resistor could be used to protect the circuitry.

a diode between D10 and the base of the switching transistor so that D10 can
pull the base low but not short out when D10 is HIGH has been generally accepted as the best solution on boards that are designed in this way. I didn't figure out the solution so can't comment on the theory behind it, sorry .

If you have plenty of time read the Information posted here, there are diagrams and more to support the solution. hope that helps :)

http://forum.arduino.cc/index.php?topic=96747.0