hd44780 custom characters limit

Hello,

I want to show some custom characters on my LCD display (i2c 162 and 204) controlled by the hd44780.
I know that the hd44780 has a limitation of maximum 8 custom characters - from code 0x00 to 0x07.

Is there any way to define new custom characters when running the code on the arduino? I know how to create a custom character, but is it possible to "swap" these in runtime so i can use more than the limited 8 characters?

Thanks in advance :slight_smile:

You can change the custom characters whenever you want. However you only get 8 on the screen at any one time.

Ahh okay - so i can do this inside the loop to assign a different custom character to the address?

lcd.createChar(0, myChar1);

and this will remove the "old" custom character assigned to 0x00? Or do i need to do something else to clear the assigned custom character first?

and this will remove the "old" custom character assigned to 0x00?

Yes.

Or do i need to do something else to clear the assigned custom character first?

No.

Thank you! :smiley:

Just to add to this. Once one of the definable character codes is displayed on the lcd, if you change the bitmap definition it will also change on the display with no further action required.

You can see this happening here: LCD Module Pushwheel Animation – Arduino++

If you install the hd44780 library it includes a custom character example, LCDcustomChars, that shows and explains how to do this.
If you have a hd44780 display with a PCF8574 based backpack, you will use the hd44780_I2Cexp i/o class.

After you install the hd44780 library (available in the IDE library manager) you can access and read all the documentation by using the Documentation sketch.
The first thin you will want to do is run the included diagnostic sketch, I2CexpDiag, to verify that everything is working as expected.

--- bill