Saturday, April 13, 2013

LCD Module in 4 bit Mode

In many projects use is manufactured from alphanumeric LCDs that are pushed internally by using Hitachi’s industry-standard HD44780 controller. These displays can additionally be driven either in 4-bit or 8-bit mode. In the primary case only the excessive nibble (D4 to D7) of the display’s knowledge bus is used. The 4 unused connections still deserve some nearer consideration. The information lines can be utilized as either enters or outputs for the show. It is well known that an unloaded output is fine, but that a floating high-impedance enter can result in issues. So what must you do with the four unused knowledge traces when the display is used in 4-bit mode? This question arose when a circuit used to be submitted to us where D0-D3 where tied straight away to GND (the related applies if it was to +5 V) to forestall the problem of floating inputs.

The LCD module used to be driven directly via a microcontroller, which was on a building board for checking out more than a few packages and I/O performs. There was once a switch present for turning off the permit of the display when it was oncen’t being used, however this can be forgotten during some tests. When the R/Wline of the show is permanently tied to GND (data best goes from the microcontroller to the display) then the remaining strains can safely be related to the supply (+ve or GND). In this utility then again, the R/Wline was once additionally managed by the microcontroller. When the show is initialised correctly then no longerhing much will have to go unsuitable. The information sheet for the HD44780 isn't very clear as to what happens with the low nibble all through initialisation.

Circuit diagram :

LCD Module in 4-bit Mode Circuit Diagram

After the power-on reset the display will always be in 8-bit mode. A easy test (see the accompanying circuit) unearths that it is safer to use pull-down resistors to GND for the 4 low knowledge lines. The information strains of the display are configured as outputs on this circuit (R/Wis high) and the ‘enable’ is toggled (which can nonetheless occur, even supposing it's now not the intention to keep in touch with the display). Note that in observe the RS line will even be pushed through an I/O pin, and in our circuit the R/W line as smartly. All knowledge traces become excessive and it’s not certain if (and if that is the case, for the method long) the show can survive with four shorted data strains. The moral of the story is: in 4-bit mode you should always tie D0-D3 by means of resistors to ground or sure.




http://www.ecircuitslab.com