I'm having some issues with the cc2530 flash memory. HalFlashWrite works fine, but when i write zeros and then try to write something else it doesnt work. In general i can overwrite the old values with new ones, but if the old values are zeros then i cannot write new values. Can anyone help or give a hint :)? Thanks in advance
This is how flash works (on all products from all manufacturers). You can change a one to a zero, but not a zero to a one, except by erasing a page. When you erase a page, all the bits in that page is set to 1.
You should read Chapter 6 of the CC253x User Guide to learn more about the flash controller. Note also the limitations on re-writing in a flash page without erasing (Section 6.2.2) and the maximum number of erase cycles in the chip's life time, which is 20000 (cf. Section 2.2.3).
All content and materials on this site are provided "as is". TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with regard to these materials, including but not limited to all implied warranties and conditions of merchantability, fitness for a particular purpose, title and non-infringement of any third party intellectual property right. TI and its respective suppliers and providers of content make no representations about the suitability of these materials for any purpose and disclaim all warranties and conditions with respect to these materials. No license, either express or implied, by estoppel or otherwise, is granted by TI. Use of the information on this site may require a license from a third party, or a license from TI.
TI is a global semiconductor design and manufacturing company. Innovate with 100,000+ analog ICs andembedded processors, along with software, tools and the industry’s largest sales/support staff.