I save some data in flash, it works fine. I'm storing it in array 2 because I think the firmware isn't using this space, but I'm not sure.
How can I avoid a conflict between data storage and firmware?
I'm using a CY8C5888LTI-LP097.
Thank you very much
Solved! Go to Solution.
I believe the em_EEPROM takes care of that. It allocates FLASH space for the emulated EEPROM in pages where the code is not.
If you want more control over where the em_EEPROM is stored there are ways to define where in FLASH to store your data. It requires knowledge of the device you're using, your compiled code size and linker file manipulation.
Since you are using the PSoC5LP, there is 2K bytes of real EEPROM available. Smaller row sizes (16 bytes) and longer endurance (> 1,000,000 erase/write cycles @ 25C).
Maybe thats is an idea, I will look in the em_EEPROM-code and look how they handel that. Thanks
The firmware needs 95000 bytes (36,1%) the bulkdata 50000 bytes of flash.
Can I be sure that firmware is using exclusivly the 95000 bytes from address 0?
I am still open to further suggestions.
I believe the linker's output of the .map file should indicate where in FLASH the em_EEPROM is placed. Knowing the sector size of FLASH (16K) you can confirm that the data area is isolated from the code area.
Note: If your data size was smaller, there is 32K bytes of ECC protected FLASH. This will allow for a single-bit correction and dual-bit corruption detection.
How do you get the 95000 bytes, could you attached your test result screenshot?
I think the Em_EEPROM or the EEPROM is a good idea.
Could you clarify how many bytes you want to store?
"...How do you get the 95000 bytes, could y.."
This is the result from a build-message:
Flash used: 96628 of 262144 bytes (36,9 %).
SRAM used: 17829 of 65536 bytes (27,2 %). Stack: 2048 bytes. Heap: 512 bytes.
I have to store up to 50000 bytes.