Hi,
My attached code to test a 16x2 and 20x4 LCD using HD44780 controller has been working well on a PIC16LF84A for a while. It is based on the code from **broken link removed** and simply displays some text strings at various lines on the screen. A digital input at RA3 will select the LCD in use, either 16x2 or 20x4 LCD.
Today I tried to migrate it to PIC16F628A. It compiled with no modifications but does not work properly. With the new PIC, the LCD is initialized properly (screen is cleared, cursor is shown and moves to correct line) but no character is displayed. It seems that the controller does not understand the character ASCII code sent as data via PORTB, yet understand the command code sent via the same port.
Any advice is appreciated. I wasted my whole evening on this. Thanks in advance
My attached code to test a 16x2 and 20x4 LCD using HD44780 controller has been working well on a PIC16LF84A for a while. It is based on the code from **broken link removed** and simply displays some text strings at various lines on the screen. A digital input at RA3 will select the LCD in use, either 16x2 or 20x4 LCD.
Today I tried to migrate it to PIC16F628A. It compiled with no modifications but does not work properly. With the new PIC, the LCD is initialized properly (screen is cleared, cursor is shown and moves to correct line) but no character is displayed. It seems that the controller does not understand the character ASCII code sent as data via PORTB, yet understand the command code sent via the same port.
Any advice is appreciated. I wasted my whole evening on this. Thanks in advance