/********************
RAM6264的地址为0000~1FFF,共8K
CS1接P2.7
CS2接VCC
WE接WR
OE接RD
A8~A12接P2。0~P2.3
********************/
#include
#include
unsigned char xdata *point=0x0000;
unsigned char dat[32];
void delay1s(void)
{
unsigned char a,b,c;
for(c=167;c>0;c–)
for(b=171;b>0;b–)
for(a=16;a>0;a–);
}
void main()
{unsigned inti,j;
for(i=0;i<32;i++)
*(point+i)=i;
for( j=0;j<32;j++)
{
P1=*(point+j);
delay1s();
}
while(1);
}