Hi,
Where should one start debugging a GLCD?
I am using a pic18f4455, and I have basically copied the code from post #231, in that I have copied the 'library' .c and .h files into a project, and copied the inital part of the main.c into my project, and pretty much commented out the rest of it.
The problem I have, is that the LCD is labelled QY-12864BG, (and made in china), and nothing else. A google search shows only 1 result, and that page isn't helping much.
In the file glcd.h, I have changed GLCD_DATA to PORTD, and GLCD_TRIS_DATA to TRISD, as I want to use ICD, which is ports RB6 and 7 on the 18f4455
After the TRIS and LAT statements I have the following two lines:
glcd_Init();
glcd_PutMessage((rom char*) "\x16\x24\x08 Blueroom\x16\x20\x10 Electronics\n Title:\n Author:\n Date:\n Hardware:");
After those two lines, I have a routine which pulses RB1, which is attached to the LED backlight. This is how I know whether the two lines above have finished.
So, without any knowledge of which lines are inverted, I went through the defines, enabling and disabling them to the pattern below. There were only 3 which got as far as turning on the LED, but none of them resulted in data being displayed. Could someone give a hint as to where to look? I have un-wired and re-wired the circuit twice, using the silkscreen on the back of the LCD for directions, but I will shortly draw out a schematic from what I have wired and work backwards. I do not have Vout (-ve I think), connected, but the schematic I see doesn't have this connected. I have a pot between VDD and VSS of 4.7k, the center connected to V0.
I know it is a long-shot, but can anyone guess as to what I should look at now?
//00000
//00001
//00010
//00011
//00100 - finishes init. no screen
//00101
//00110 - finishes init. no screen
//00111
//01000
//01001
//01010
//01011
//01100
//01101
//01110
//01111
//10000
//10001
//10010
//10011
//10100
//10101 - init. no screen
//10110
//10111
//11000
//11001
//11010
//11011
//11100
//11101
//11110
//11111
// EN bit is complemented on the LCD side
//#define GLCD_CFG_EN_COMPLEMENTED
// DI bit is complemented on the LCD side
// By default, D is active high and I is active low
// Uncomment this line if your LCD has different pinout configuration
//#define GLCD_CFG_DI_COMPLEMENTED
// CSx bits are complemented on the LCD side
#define GLCD_CFG_CS_COMPLEMENTED
// RS bit is complemented on the LCD side
#define GLCD_CFG_RS_COMPLEMENTED
// RW bit is complemented on the LCD side
// By default, R is active high and W is active low
// Uncomment this line if your LCD has different pinout configuration
//#define GLCD_CFG_RW_COMPLEMENTED