GLCD Library
A C Library for Embedded Applications
 All Data Structures Files Functions Variables Enumerations Enumerator Macros Groups Pages
GLCD Library Documentation


Welcome to GLCD, an open source graphic LCD library written by Andy Gock.

Author's web site:

GitHub repository:

This library has been written cleanly, to allow easy modification for use with different microcontroller devices and controller chipsets. Logic relating to devices and controllers are palced in seperate files and specific implementations can be chosen by the use of special defined symbols.

It is suitable for monochrome (black and white) LCDs with page by page data and command write style data transfer protocol. It is not suitable for color graphic LCDs.

Supported LCD Chipsets

Current supported LCD controllers / chipsets:

  • PCD8544 based LCDs, e.g Nokia 3110 and 5110 LCDs
  • ST7565R serial interface (used in Newhaven Display NHD-C12864WC-FSW-FBW-3V3-M)
  • NT75451 parallel interface (used on NGX BlueBoards)

Supported Microcontrollers

Current supported devices / microcontrollers:

  • Atmel AVR 8-bit
  • NXP LPC111x ARM Cortex
  • NXP LPC11Uxx ARM Cortex
  • ST STM32F0XX Arm Cortex

Compiler Setup

The following symbols need to be set for the compiler used:

Pick microcontroller type (pick one only):


Pick LCD controller type (pick one only):


If using a parallel interface LCD (e.g NT75451 on NGX BlueBoard):


When using SPI controllers:


Note the SPI symbol isn't checked by the compiler, and it is fine if it is not used. It is for forward compatibility only.

These symbols above need to be set in the configuration options of your IDE, usually in the "defined symbols" section, or they can be defined in a makefile as -D options.


Also, we need to set the width and height of the LCD in glcd.h

Custom Fonts

Custom fonts can be generated using the free MikroElektronika GLCD Font Creator tool. The standard 5x7 tiny text font is included together with also a few extra custom fonts to get you started.

There is a tutorial on my web site on how to use this software.

I also have been in the progress of working on a dedicated piece of software for generating fonts and bitmaps called glcd-utils. This is not very active at the moment, and is written in Qt Creator. This is set up specifically for glcd and works a lot better. However it is not documented and not really fit for public distribution at the moment.