Other Parts Discussed in Thread: CC2540
Hello
I am currently studying on the TI CC2540 flash section of
the problem
There are several questions to ask:
1、 In the "CC253X-CC254X User Guide" P.25 mentioned, as I would like to store the data into the flash space. Need to use the 0x8000 ~ 0xFFFF section of the XDATA memory , total of 32K Bytes can be used. And CC2540 Provides Non-Volatile Memory, and Simple Non-Volatile Memory. There are three blocks counted, so the data I stored can reach the range of about 96KB, is that right?
2、 why engineer’s recommend is to use the snv memory in the following article, but the OSAL API document still exists the introduction of sn memory ? CC2540 whether there Non-Volatile memory space?
http://e2e.ti.com/support/low_power_rf/f/538/t/120842.aspx
3、I have tried to write some Flash-code, on the part of the read/write, reading is OK, but writing has something problematic. I have set an array written, observed the written address value in memory window under IAR Workbench Debug mode, and the value I wrote can’t be successfully recorded that I expect, but there are changes in the appointed address, the Code is provided below for reference I wrote:
=======================================================================================
uint8 temp[4] = {0x61,0x62,0x63,0x64};
while(FCTL&0x80); // make sure that erase operation is completed
EA = 0;
HalFlashWrite(0x2A80,temp ,1);//0xAA00
EA = 1;
=======================================================================================
Using the above code, Memory window is displayed as {61 40 02 00}, do not know how the kind of problem?
I 'm not quite sure if this change is correct. Thanks!
Best Regard
Wen-Chia Chao