TomaszK
Posts: 8
Joined: Mon Jan 01, 2018 9:25 pm

Lcd voltage

Wed Jan 24, 2018 12:48 pm

Can I directly connect raspberry pi with a 2x16 LCD with a converter?

https://botland.com.pl/konwertery-pozos ... esults=686

Will the 5v voltage be reduced and will not be a problem? Did someone something like that? Have you maybe good python script?

tpylkko
Posts: 409
Joined: Tue Oct 14, 2014 5:21 pm

Re: Lcd voltage

Wed Jan 24, 2018 9:03 pm

If you are using a 5V LCD (these are more common than 3.3V which also exist) then this is what I believe will happen: then communication over I2C will likely work although the voltage is wrong. I have done this many times with micro-controllers and never had a problem with that. The LCD is not going to send any data back to the pi, so it is a bit different than many other devices that use the bus to transfer data in bothdirections.

The LCD will probably require something like 4 V for it to be able to turn the backlight on at a high enough power for you to be able to see anything. This is what I have seen from experience buy you can check it in the data sheet if you have it. So most likely, it will be so dim that you will barely be able to see anything. You can resolve this problem by attaching the communication pins to the Pi and feeding the display 5V from some other source (for example the same 5V source that you are giving the pi) and either grounding it back there or onto the Pi pin. Then there is also the problem that if you send the ground to the pi, then the ground pin on the pi will have to take the current/voltage that comes out of the LCD. However, I would guess that the LCD itself with the backpack chip will have enough "internal resistance" to bring it to safe levels.

But while this could be done, a much more "proper" way to do this is to use a cheap logic level shifter chip. You can get many of them for one dollar, so they are not expensive. This is a chip has pins on both sides and when you connect 3.3V to one side, the equivalent pins on the other side will repeat the same signals at 5V. So send all the 4 pins that you want to go to the i2c back pack to the logic level shifter and from there to the LCD.

User avatar
FTrevorGowen
Forum Moderator
Forum Moderator
Posts: 5618
Joined: Mon Mar 04, 2013 6:12 pm
Location: Bristol, U.K.
Contact: Website

Re: Lcd voltage

Wed Jan 24, 2018 10:05 pm

FWIW, you may find my test of an equivalent, reduced voltage, setup of a "5V" LCD + similar I2C interface, pre-built, module + display of interest:
http://www.cpmspectrepi.uk/raspberry_pi ... iPlus.html
NB: the module will not reduce the (LCD supply) voltage for you - you have to do that yourself (I used a diode in series with the 5V from the Pi to both the i.c./module and the LCD display). Note also some software timings had to be "tweaked" for the "external" module:
http://www.cpmspectrepi.uk/raspberry_pi ... gData.html
Trev.
Still running Raspbian Jessie or Stretch on some older Pi's (an A, B1, 2xB2, B+, P2B, 3xP0, P0W, 2xP3A+, P3B+, P3B, B+, and a A+) but Buster on the P4B's. See: https://www.cpmspectrepi.uk/raspberry_pi/raspiidx.htm

Return to “General discussion”