Color LCD Shield

From Wiki

Jump to: navigation, search



This shield base on Sparkfun design, we upgraded and modified the blacklight to PWM(D10) control and button to 4 direction Joystick w/ Switch(A0-A4),more key and easy to operate. This shield just uses the Philips PCF8833 controller, base on a good display Nokia 6100 LCD Panel.

The Color LCD Shield,provides an easy method of connecting the popular Nokia 6100 LCD to your Arduino. The board comes as shown with the 128x128 mini color LCD, as well as a backlight driver circuit (boosts to 7V) control by PWM.

The Nokia 6100 LCD is controlled through a 9-bit SPI interface. The control pins of the LCD are connected to the hardware SPI pins of the Arduino (D13 -SCK, D11 - DIO), the CS pin is tied to D9 and the reset pin is connected to D8. Voltage from the '5V' pin of the Arduino is boosted to 7V to power the LCD backlight.

Arduino Shield ColorLCD 02.jpgArduino Shield ColorLCD 03.jpg

Model: SHD-CLS



1. If you use our library , you can not modified anything. If you use the Sparkfun library, you just need change



pinMode(10, OUTPUT);
analogWrite(10, 1023);   // For PWM control

For the PHILLIPS controller and PWM control.

2. If there are mirror X/Y or bottom to top , swapped direction etc , you just need modified the PHILLIPS Register MADCTL in ColorLCDShield.cpp.

add such as :

LCDCommand(MADCTL);   // Memory Access Control(PHILLIPS) 

More detail ,please reference the datasheet of PHILLIPS-Datasheet on Page 43.



Arduino Shield ColorLCD 07.jpg

What it does:

Looking at the Shield, it may seem like it's got a lot going on, but it's really a pretty simple board. There's the LCD, a knock off Nokia 6100 screen. Below and to the left of the LCD are an IC and some passive components whose sole purpose in life is boosting 5V to about 7V, which is required to illuminate the LCD's backlight. Finally, to the right of the boost circuit are a few momentary push-buttons for use as...buttons.

To communicate with the LCD, the Arduino uses a three-wire serial interface, as well as a fourth pin to control the LCD's reset functionality.

Arduino Shield ColorLCD 12.jpg

If you're using the Color LCD Shield with other shields or components, be wary of sharing these pins. You should be safe if you want to set up an SPI bus, using the DIO and SCK pins, but the other two pins should not be shared with any other devices. Also, be aware that the buttons are connected to pins 3, 4, and 5.

When you first receive the Shield, the LCD should be covered with a protective sticker. Don't toss this in the garbage bin just yet, and put on your detective hat. You see, one of the more irritating things about this display is we don't always initially know what makes it tick. Embedded into each display is a driver, which is really what controls these LCDs. The driver turns a simple 3-wire serial signal -- something we can easily send with an Arduino -- into a HUGE set of outputs (upwards of 500 pins). Our displays come with two possible driver options: an Epson S1D15G00 or a Philips PCF8833. If you've got a red tab on your protective sticker, it's most likely an Epson, a blue tab is usually indicative of the Phillips driver. File which display you have into the back of your mind because we'll need it again. There are some minor differences between the drivers, but in the end they'll both display the same thing.

How to Use It:

1. Download the library.

2. Uncompress the packages to Arduino-1.0.1 program: ..\Arduino-1.0.1\libraries

3. Run the arduino program compile and upload the sketch as below:

Arduino Shield ColorLCD 11.jpg

Now, try clearing the screen to other colors., or adjusting the contrast. The predefined colors are (don't forget all caps): BLACK, NAVY, BLUE, TEAL, EMERALD, GREEN, CYAN, SLATE, INDIGO, TURQUOISE, OLIVE, MAROON, PURPLE, GRAY, SKYBLUE, BROWN, CRIMSON, ORCHID, RED, MAGENTA, ORANGE, PINK, CORAL, SALMON, ORANGE, GOLD, YELLOW, WHITE, PALEROYALCORNFLOWERBLUE. OK, maybe not that last one. I had some fun making colors...

However, don't let those defined colors limit your color spectrum, the LCD uses 12-bit RGB values to define colors, which means there are 4096 possible colors. Rather than sending one of the predefined color values, try putting a 12-bit value into the clear function; pick three hex digits (0-F), and arrange them as 0x123 (replacing 1, 2, and 3). The first value is the amount of red you want, the middle value is green, and the last value is blue.

LCD Display Orientation

The Nokia 6100 display has 132 x 132 pixels; each one with 12-bit color (4 bits RED, 4 bits GREEN and 4 bits BLUE). Practically speaking, you cannot see the first and last row and columns. The normal orientation is as follows:

Arduino Shield ColorLCD 14.jpg

That, of course, is upside-down on the Olimex SAM7-EX256 board if the silk-screen lettering is used as the up/down reference. So I set the “mirror x” and “mirror y” command to rotate the display 180 degrees, as shown below. This will be the orientation used in this tutorial (it is so easy to change back, if you desire).

Arduino Shield ColorLCD 15.jpg

You can modified the PHILLIPS Register MADCTL in ColorLCDShield.cpp.

More detail ,please reference the datasheet of PHILLIPS-Datasheet on Page 43.

Version Tracker

Revision Descriptions Release
v1.2 Initial public release date

Additional Idea

The Additional Idea is the place to write your project ideas about this product, or other usages you've found. Or you can write them on Projects page.


How to buy

Click here to buy:

See Also

Other related products and resources.


This documentation is licensed under the Creative Commons Attribution-ShareAlike License 3.0 Source code and libraries are

licensed under GPL/LGPL, see source code files for details.

External Links

Links to external webpages which provide more application ideas, documents/datasheet or software libraries

Personal tools