Our universal character LCD adapter can work with different size of character LCDs: 0801,0802,0804, 1601, 1602, 1604, 2001, 2002, 2004, 4001 and 4002 if the LCD controller is KS0066U/F / HD44780 or compatible chip.
The default set is 1602, if your LCD is other than 1602, you need to use this command: STCR, follow by a byte for column and a byte for row, the rest of 4 bytes is fixed for KS0066U/F / HD44780 LCD controller.
eg.: for 2004 LCD: “STCR\x14\x04\x80\xC0\x94\xD4”.
Arduino lib function: setLCDColRow(c,r);
In the new version of Universal GLCD adapter V2, the firmware can recognize the KS0108, ST7920 and ST7565 (SPI) by itself. It also support ST7565 in parallel mode by using command of “SLCD3” and following 8 bytes of init parameters, that pinout are same with for ST7920.
Because the ST7565 chip used widely in 12864 LCD panels, and it’s very flexible of configuration, you need set at least 8 bytes of init parameters, if the ST7565 (SPI) not working well with this adapter, please use command “SLCD2” following by 8 bytes of init parameters also:
# |
valid value(HEX) |
Function |
Detail description |
---|---|---|---|
1 |
A6 / A7 |
Control the pixel normal or reverse |
A6=Normal(default), A7=Reverse |
2 |
A2 / A3 |
Set LCD bias |
A2=1/9 bias (default), A3=1/7 bias |
3 |
A0 / A1 |
Set the horizontal scan direction |
A0=Normal(default), A1=Reverse |
4 |
C0 /C8 |
Set the vertical scan direction |
C0=Normal(default), C8=Reverse |
5 |
20~27 |
Select internal resistor ratio(Rb/Ra) |
25 (default) |
6,7 |
81+[0~3F] |
Set screen contrast |
81+24 (default) |
8 |
40~7F |
Set RAM start address, 40 start 0, 7F start 3F |
40 (default) |
The default init parameter set is equal to this command string: “SLCD2\xA6\xA2\xA0\xC0\x25\x81\x24\x40”.