I am using at89c51re2 mcu with LH52256-70 32k XRAM in system with graphical lCD 128x64. I have problem to initialize LCD. This is part of code where I config pins and select memory location for lcd bus in XRAM
unsigned char xdata lcd_bus _at_ 0x0000; sbit RS=P0^0; sbit E=P0^5; sbit CS1=P0^1; sbit CS2=P0^2;
Then in main.c I call function Init()
void Init() { CS1=1; CS2=1; SdCmd(0x3f); //postavljanje y adrese na 63 SdCmd(0xc0); //postavljanje x adrese na 0 CleanScreen(); delay(255); }
But there is no reaction of LCD. Should I config AUXR register or something else?
Thanks in advance Mark
I should tell that I am using a program which was working on board without external RAM. All functions were tested before. In previous version I used declaration
#define lcd_bus P1
and all other was the same.
void Init() { CS1=1; CS2=1;
wrong place.
You need to do this in setup.a51.
There is much going on (also involving XDATA) before you reach main()
Erik
This is the first time that I am using external RAM. Can You provide me more detailed information or some piece of code which is correct.
Thanks
Can You provide me more detailed information what more do you need
some piece of code which is correct can't it's chip specific I do not use Arghmel chips