Tymoty
New Member
ok. my lcd is atm12864D - datasheet is on the web, but there are mystakes-informations in the table and in description are different. For data I use portB, for others portD (CS1-RD3; CS2-RD2; D/I-RD7; RW-RD6; E-RD5; RESET-RD4) - I use PIC18F4525. I connected leds like you (by the way good work
) and the program doesn't get trouhg init part. I write code for led to init part and it fall down in ClearScreen.
void ClearScreen(void){
unsigned char m,n;
b_GLCD_GCS1=1;Delay();
b_GLCD_GCS2=1;Delay();
Delay10KTCYx(0);
Delay10KTCYx(0);
blinkLed(3);
Delay10KTCYx(0);
Delay10KTCYx(0);
for(m=0;m<8;m++){
GLCD_Write_Cmd(0x40);Delay(); //y=0
GLCD_Write_Cmd(0xb8+m);Delay(); //x=0
for(n=0;n<0x40;n++){
GLCD_Write_Data(0x00);Delay();
}
}
it works to for cycle and than it doesn't work. if I measure it, data=0; RS=0;RW=1;CS1=1;CS2=0 - this I don't understand, before blinkled CS1=CS2=1.
void ClearScreen(void){
unsigned char m,n;
b_GLCD_GCS1=1;Delay();
b_GLCD_GCS2=1;Delay();
Delay10KTCYx(0);
Delay10KTCYx(0);
blinkLed(3);
Delay10KTCYx(0);
Delay10KTCYx(0);
for(m=0;m<8;m++){
GLCD_Write_Cmd(0x40);Delay(); //y=0
GLCD_Write_Cmd(0xb8+m);Delay(); //x=0
for(n=0;n<0x40;n++){
GLCD_Write_Data(0x00);Delay();
}
}
it works to for cycle and than it doesn't work. if I measure it, data=0; RS=0;RW=1;CS1=1;CS2=0 - this I don't understand, before blinkled CS1=CS2=1.