Example Initialization Program

/*************************************************************/

/*************************************************************/

void write_command(unsigned char datum)

{

A0=0; /*Instruction register*/

E=1; /*Read inactive*/

bus=datum; /*put data on port 1*/

CSB=0; /*Chip select active*/

RW=0; /*Write active*/

RW=1; /*Write inactive; latch in data*/

CSB=1; /*Chip select inactive*/

}

/*************************************************************/

void write_data(unsigned char datum)

{

A0=1; /*DDRAM data register*/

E=1;

bus=datum;

CSB=0;

RW=0;

RW=1;

CSB=1;

}

/*************************************************************/

void lcd_init(void){

Const unsigned char lcd_rs2[] = {

0xa2,// ICON OFF;

0xae,// Display OFF

0x48,// Set Duty ratio

0x80,// No operation

0xa0,// Set scan direction

0xc8,// SHL select

0x40, 0x00,// Set START LINE

0xab,// OSC on

0x64, 0xff,// 3x

0x65, 0xff,// 4x

0x66, 0xff,// 5x

0x67, 0xff,// 6x

Ra_Rb,// RESISTER SET

0x81,// Set electronic volume register

vopcode,// n=0~3f

0x57,// 1/12bias

0x92,// FRC and pwm

0x2C, 0xff,

0x2E, 0xff,

0x2F, 0xff,

0x92,// frc and pwm

0x38,// external mode

0x75,

/*** start settings for 16‐level grayscale ***/

0x97,// 3frc,45pwm

0x80, 0x00,

0x81, 0x00,

0x82, 0x00,

0x83, 0x00,

0x84, 0x06,

0x85, 0x06,

0x86, 0x06,

0x87, 0x06,

0x88, 0x0b,

0x89, 0x0b,

0x8a, 0x0b,

0x8b, 0x0b,

0x8c, 0x10,

0x8d, 0x10,

0x8e, 0x10,

0x8f, 0x10,

0x90, 0x15,

0x91, 0x15,

0x92, 0x15,

0x93, 0x15,

0x94, 0x1a,

0x95, 0x1a,

0x96, 0x1a,

0x97, 0x1a,

0x98, 0x1e,

0x99, 0x1e,

0x9a, 0x1e,

0x9b, 0x1e,

0x9c, 0x23,

0x9d, 0x23,

0x9e, 0x23,

0x9f, 0x23,

0xa0, 0x27,

0xa1, 0x27,

0xa2, 0x27,

0xa3, 0x27,

0xa4, 0x2b,

0xa5, 0x2b,

0xa6, 0x2b,

0xa7, 0x2b,

0xa8, 0x2f,

0xa9, 0x2f,

0xaa, 0x2f,

0xab, 0x2f,

0xac, 0x32,

0xad, 0x32,

0xae, 0x32,

0xaf, 0x32,

0xb0, 0x35,

0xb1, 0x35,

0xb2, 0x35,

0xb3, 0x35,

0xb4, 0x38,

0xb5, 0x38,

0xb6, 0x38,

0xb7, 0x38,

0xb8, 0x3a,

0xb9, 0x3a,

0xba, 0x3a,

0xbb, 0x3a,

0xbc, 0x3c,

0xbd, 0x3c,

0xbe, 0x3c,

0xbf, 0x3c,

// end settings for 16‐level grayscale

0x38,

0x74,

0xaf,// Display ON

}

/*************************************************************/

/*************************************************************/

1.0 The LCD panel is made by glass. Any mechanical shock (eg. dropping form high place) will damage

the LCD module.

2.0 Do not add excessive force on the surface of the display, which may cause the Display color change

abnormally.

3.0 The polarizer on the LCD is easily get scratched. If possible, do not remove the LCD protective film

until the last step of installation.

4.0 Never attempt to disassemble or rework the LCD module.

5.0 Only Clean the LCD with Isopropyl Alcohol or Ethyl Alcohol. Other solvents (eg. water) may damage

the LCD.

6.0 When mounting the LCD module, make sure that it is free form twisting, warping and distortion.

7.0 Ensure to provide enough space (with cushion) between case and LCD panel to prevent external

force adding on it, or it may cause damage to the LCD or degrade the display result.

8.0 Only hold the LCD module by its side. Never hold LCD module by adds force on the heat seal or TAB.

9.0 Never add force to component of the LCD module. It may cause invisible damage or degrade of the

reliability.

10.0 LCD module could be easily damaged by static electricity. Be careful to maintain an optimum

anti-static work environment to protect the LCD module.

11.0 When peeling off the protective film from LCD, static charge may cause abnormal display pattern. It

is normal and will resume to normal in a short while.

12.0 Take care and prevent get hurt by the LCD panel sharp edge.

13.0 Never operate the LCD module exceed the absolute maximum ratings.

14.0 Keep the signal line as short as possible to prevent noisy signal applying to LCD module.

15.0 Never apply signal to the LCD module without power supply.

16.0 IC chip (eg. TAB or COG) is sensitive to the light. Strong lighting environment could Possibly cause

malfunction. Light sealing structure casing is recommend.

17.0 LCD module reliability may be reduced by temperature shock.

18.0 When storing the LCD module, avoid exposure to the direct sunlight, high humidity, high temperature

or low temperature. They may damage or degrade the LCD module