ByVac 4618 I2C LCD/keypad controller


I bought Byvacs new LCD and keypad I2C conbtroller .

I wired it all up (4x20 LCD + 4x4 keypad) and loaded their example code and it all works (if I use int pin 9 as interrupt), but doesn’t without int pin, although in userguide says it should (but the proc and i2c bus will be more though loaded, which I don’t mind). Any ideas about that?

Though the working example code I would like to print some more stuff on LCD…for example time from RTC.

I tried the following code:

  di.puts("Hour Test"); //Prints line on LCD
  int hour;
  hour = RTC.get(DS1307_HR,true);
  Serial.print(hour); //for test

It prints “Hour Tets” on LCD, and nothing else. On serial monitor I get the correct hour time.
I guess it has something to do with statement in Userguide about “puts” function, that says: "
Sends a string to the i2c bus. The string must be a string, i.e. null

I guess, I should somehow convert “hour” to text. Any ideas, how to do that?

This library is a bit hard to read for me… I saw nicely writen lib for Byvac 4218, but have no idea, how to correct it to work with my controller.

Thank you for help in advance.


got it (at least for the puts part).

You can convert integer to a string with itoa command.

For my example, here is a working code:

int hour;
hour = RTC.get(DS1307_HR,true);
char hour_str[4]; // Define as a string (4 bytes)
itoa (hour, hour_str, 10); //convert integer to string
di.puts(hour_str); //print string on LCD

It can be also used like this:

int hour;
hour = RTC.get(DS1307_HR,true);
char hour_str[4]; // Define as a string (4 bytes)
di.puts(itoa (hour, hour_str, 10)); //convert integer to string and print string on LCD

I'm still scratching my head bout using keypad without interupt pin.
Any help is appreciated

Guess what?
It's working without a int pin :slight_smile:
I didn't wire it up using 2 pull up resistors.
With them it works :slight_smile: