HD44780 LCD with Arduino Uno

Hello,

I am trying to interface HD44780 LCD with Arduino Uno.

All the connections are done as per https://github.com/RIOT-OS/RIOT/tree/master/tests/driver_hd44780

Below is my code:

The code is compiled successfully but does not work as expected on flashing to Arduino Uno i.e I could not see cursor blinking

//#include “hd44780_params.h”

#include “hd44780.h”

hd44780_t *a;

hd44780_params_t *b;

void setup(void)

{

hd44780_init(a,b);

}

void loop(void)

{

//hd44780_print(a,“hi”);

hd44780_blink(a,HD44780_ON);

delay(100);

}

Best Regards,

Hello,

I noticed that I am using JHD162A LCD display. In one of the RIOT-OS doc, I read that LCM1602C LCD is needed.

Could this be the reason of my unsuccessful Implementation of LCD?

Please help!

Hi Patil. The reason might be wrong pin connections. Are you sure about these two LCD have same pin configurations? Sometimes event Vcc and GNC positions differs

24 Eki 2019 Per 12:21 tarihinde PATIL Sangeeta <Sangeeta.PATIL@3ds.com> şunu yazdı:

Yes ,the pin connections are correct .

To confirm ,I coded in Arduino IDE (keeping the same pin connection) and it works perfectly

Best Regards,

image001.jpg

image003.png

Then, there might be an issue. It is better to open an issue in github.

4 Kas 2019 Pzt 10:34 tarihinde PATIL Sangeeta <Sangeeta.PATIL@3ds.com> şunu yazdı:

image001.jpg

I noticed that I did not include “hd44780_params.h” header file in my sketch. On including it in my sketch, compilation hits error

But in main.c file located in “driver_hd44780 “folder, this header file is included.

Does anyone know about this?

Best Regards,

We are looking into some issues with the hd44780 in PR 12634 [1] and hope to have it solved soon. You could try testing with this PR so see if it fixes your issue.

  • Kevin

[1] https://github.com/RIOT-OS/RIOT/pull/12634

Thanks Kevin!

image001.jpg

image003.png

Hello ,

Finally ,I could make LCD (JHD162A) work with Arduino-Uno through RIOT OS

I removed lcd initialization from setup and added below two lines in main function ….and it worked !

if (hd44780_init(&dev,&hd44780_params[0])!=0)

{

puts(“failed”);

}

But I don’t understand the logic in context of &hd44780_params[0].

I understand that we are checking the successful initialisation of lcd by using if loop but what are we checking when we pass &hd44780_params[0]

Why can’t we just initialize the lcd as I did in my below e-mail?

Thanks in advance for help!

image001.jpg

image003.png