I tried to look at most of the post about connecting an LCD 1602 to an UNO and I did not found the answer to the question that I’m coming to post here. If I miss something, please accept my excuses.
Ok, I connected an Winstar LCD 1602B (text display, 2 rows, 16 columns) to an Arduino UNO board and I’m using the LiquidCrystal library. Everything works perfectly well, but I’d like to be able to turn off the LCD at certain moments. I found on this forum a trick to avoid the variable resistor (using a diode from LCD pin VO to ground) and I’m using it.
I started with a bad idea that, of course, didn’t work: I tried to cut the LCD Vdd pin with an SPST NO relay. When the relay was closed the LCD works normally, but when the relay is open the LCD Vdd pin floats and this causes the a strange behavior and does not turn out the LCD.
I thought in using an SPDT relay, but since I had none, decided to try with a transistor working as a switch. I read on this forum that some people succeed in turning off the LCD using a transistor (I could make the Vce of a BC448 come very close to 0.3 V about Vcesat). I had no problem in controlling the LCD A pin from the UNO and turn off the back light, but this doesn’t turn off the LCD.
With the SPDT relay (HK4100F-DC5V-SHG) connecting LCD pins Vdd and A to 5V or to ground (see the attacked image) everything seams to work well, so I decided to mesure the current consume of all the system. I found that when running with the LCD on, the whole system consumes about 64 mA, but with the LCD off the consume is more the 180 mA!
The one to blame is, of course, the LCD. The consume of the LCD Vdd + A (with the resistors tha I used - see the attached image) is 2.4 mA with the LCD on but it is -63.3 mA (reverse current) with the LCD off! Without back light the LCD consumes 0.8 mA on and -63.3 mA off. By off, I mean with the LCD Vdd connected to ground (through the relay).
I also try to use the LiquidCrystal noDisplay() function, but with very little impact.
My question is: any good idea on how to turn off the LCD without all this super consume? Ok, one good idea is to use another relay and also cut the LCD ground pin, but are there any more suggestions?
I wish you all a happy New Year!