HELP!! arduino uno +, 74hc595n +20x4 LCD

Dear friends,

today i have spent my day connecting a 20X4 LCD to the arduino by using a 74hc595n shift register, i have tried to find some examples however i couldn't find any with a 20x4 LCD, (everybody is using a 16x2). In all the examples i saw, they were using only 4 bit data sending to the chip.

If there is anyone who has some experience on this please help me, i dont know where to connect my Enable, RS and RW pins on the LCD when i connect all the 8 Digital output pins of the LCD to the shift register.

You can use the information provided in any 16x2 example for your 20x4. The controller chip is absolutely identical and in fact there is no way for the controller to determine which type of display it is driving.

Either the 4-bit mode or the 8-bit mode can be used to drive any of the displays. There is no difference in what you can do and only marginal difference in performance. The 4-bit programming is more complex but the library software insulates you from that problem.

Don

Thanks for your reply! so i guess i need to use LiquidCrystal_I2C library then, so you mean i can still drive my 20x4 LCD with only connecting its 4 DB wires. hmm. how do i declare this in the code?

so one more question; what does that SDA and SCL pins do? cause in some of the examples they never use them, they just use the usual digital output pins. but in the wire.h library it indicates that we have to use them.

... so i guess i need to use LiquidCrystal_I2C library ...

You really can't talk about the LiquidCrystal_I2C library since there are so many of them, all with the same name.

The current recommendation is to use the 'New LiquidCrystal' library by fmalpartida.

This is a replacement for the LiquidCrystal library that comes with the IDE and it can handle parallel along with all sorts of serial implementations including I2C and shift register.

so one more question ...

It all depends on the library. Some libraries are limited to certain pins so you have to use the ones specified. Others allow you a choice of pins so you have to tell the library which ones you are using, generally with a statement called the constructor.

Don

Thanks for your clear answers, i have checked out the new library but i think it is not compatible with 74hc595n register. Although Im very new to coding so i might have misunderstood. what do you think?

It looks like there is a 74595 implementation on this page: https://bitbucket.org/fmalpartida/new-liquidcrystal/wiki/schematics?_escaped_fragment_=shiftregister-connection#!shiftregister-connection

Don

i did exactly the same connections however still not working, i dont even understand why he connected the contrast pin onto the controller:/. it should have been connected to the middle leg of the potentiometer i thought. the code and the schematic is not for each other i guess.

how hard can it be to connect lcd with a shift register :/ im not made for this thing apparently

i dont even understand why he connected the contrast pin onto the controller...

He didn't.

... it should have been connected to the middle leg of the potentiometer

It is.

Are you looking at the diagram called "SR LCD Backpack Interface"?

Don

hmm i was looking at the one beneath it. lets try this one , Thanks