In this tutorial we'll see, how to interface 128*64 GLCD with PIC16F877A Starter board. We will using KS0108 controller based JHD12864E display. There are many displays out there based on KS0108 or compatible display controller. They all work the same way, but make sure to check the datasheet for the pin diagram before doing the connection.


Please check this tutorial for detailed explanation on GLCD.


Below table shows the GLCD pins connection.

RS RW EN CS1 CS2 D0 D1 D2 D3 D4 D5 D6 D7
PD_0 PD_1 PD_2 PD_3 PD_4 PB_0 PB_1 PB_2 PB_3 PB_4 PB_5 PB_6 PB_7

Displaying Strings

0Glcd iterfacing with PIC16f877a.png

Displaying Numbers

Glcd DisplayNumber.png

Displaying Bar Graphs

Glcd HorizontalGraph.png

Glcd VerticalGraph.png


Download the complete project folder from the below link:

Have a opinion, suggestion , question or feedback about the article let it out here!