|
cpu为 arm7 LPC2214FBD144
公司使用spansion公司的flash S29GL064M芯片,现我做他的读写程序,但始终无法正确写入高手分析下:
写命令如下
Write to Buffer 3AAA AA 555 55 SA 25 SA BC PA PD WBL PD
测量不到cs ce we引脚波形,
void byte_write(void)
{
unsigned char *p;
p = (unsigned char *)( 0x81000000); //得芯片地址
*(p + 0xAAA) = 0xAA;
delay(100);
*(p + 0x555) = 0x55;
delay(100);
p = (unsigned char*)(0x81050000);
*p = 0x25;
delay(100);
*p = 1; //要写数据个数
p= (unsigned char *)(0x81050002); //得数据地址
delay(100);
*p=15;
p= (unsigned char *)(0x81050002); //得数据地址
delay(100);
*p=15;
}
这是个简单的写命令,但写不进去。着急啊
|
|