ricepotato2006
Newbie level 4
Hi All,
I am trying to read and write to external memory.
and I want to read data from flash memory and output to P0
now I have a few questions.
1. do I need to set the ALE, EA, RD, and WR bits?
2. Following is my code, and it seem not to do anything, something wrong?
main()
{
xdata char xdata *a_Ptr=0x8000;
char myX;
while(1)
{
myX=*a_Ptr;
P0=myX;
}
}
Thank you in advance
I am trying to read and write to external memory.
and I want to read data from flash memory and output to P0
now I have a few questions.
1. do I need to set the ALE, EA, RD, and WR bits?
2. Following is my code, and it seem not to do anything, something wrong?
main()
{
xdata char xdata *a_Ptr=0x8000;
char myX;
while(1)
{
myX=*a_Ptr;
P0=myX;
}
}
Thank you in advance