skip navigational linksPJRC
Shopping Cart Checkout Shipping Cost Download Website
Home MP3 Player 8051 Tools All Projects PJRC Store Site Map
You are here: Teensy Teensyduino Libraries DogLcd

PJRC Store
Teensy 3.6, $29.25
Teensy 3.5, $24.25
Teensy 3.2, $19.80
Teensy LC, $11.65
Teensy 2.0, $16.00
Teensy++ 2.0, $24.00
Main Page
Getting Started
How-To Tips
Code Library

DogLCD Library

DogLCD lets you use the DOG-M LCDs from Electronic Assembly. Only 4 pins are used.

Download: (version 1.0.0)

LiquidCrystal works perfectly with Teensy 2.0 and Teensy++ 2.0 and Teensy 3.0.

Hardware Requirements

The EADOGM081, EADOGM162, and EADOGM163 are supported. This photo shows a EADOGM162S-A with EALED55x31-A backlight.

DogLcd works on Teensy 2.0 and Teensy++ 2.0 and Teensy 3.0. The DogM displays are able to receive 3.3 volt signals, even when running at 5 volts.

Basic Usage

LiquidCrystal lcd(SI, CLK, RS, CSB)

Create the DogLcd object and specify the 4 pins where the LCD is connected. You can connect more than one LCD and create separate DogLcd objects for each.


Initialize the display. Type should be DOG_LCD_M081, DOG_LCD_M162, or DOG_LCD_M163.


Print a number or text. This works the same as Serial.print(), but prints to the LCD.

lcd.setCursor(x, y);

Move the cursor to position (x, y). These are zero-based coordinates.

Many other functions are available. See below for links to more details.

Example Program

This example can be loaded with File > Examples > DogLcd > HelloWorld.
  DogLcd Library - Hello World
  Demonstrates the basic use of a DOGM text LCD display.
 This sketch prints "Hello World!" to the LCD
 and shows the time.
 See the online-documention for wiring instuctions
 We assume  the following pins are connected:
 * LCD SI pin to digital pin 2
 * LCD CLK pin to digital pin 3
 * LCD RS pin to digital pin 4
 * LCD CSB pin to digital pin 5
 * LCD RESET pin is not used
 * LCD Backlight pin is not used

// include the library code:
#include <DogLcd.h>

// initialize the library with the numbers of the interface pins
DogLcd lcd(2, 3, 4, 5);

void setup() {
  // set up the LCD type and the contrast setting for the display 
  // Print a message to the LCD.
  lcd.print("hello, world!");

void loop() {
  // set the cursor to column 0, line 1
  // (note: line 1 is the second row, since counting begins with 0):
  lcd.setCursor(0, 1);
  // print the number of seconds since reset:

Teensy 3.0 Usage

For use with Teensy 3.0, the DogM LCD can be run at 5 volts. It is able to accept the 3.3 volt signals from Teensy 3.0. Because all 4 signals are unidirectional from Teensy 3.0 to the LCD, there is no issue with 5 volt signals driving 3.3 volt only inputs.


For more details, please refer to the official DogLcd library page and the DOG-M LCD page.

The display and backlight shown in the photo were purchased from Mouser Electronics.