cancel
Showing results for 
Search instead for 
Did you mean: 

Cortex M0 Non Volatile Memory Storage

markjohnson9
Associate II
Posted on February 26, 2016 at 15:19

Is anyone aware of a method or even the feasibility to transfer captured data from the ADC module, transferred to SRAM, then stored to non volatile memory (flash) section of the Cortex M0 Arm core without having to externally store the data to another device?

Example: An application requires to count people walking through a doorway. This data can be easily acquired and stored in Cortex M0 SRAM. However if the system lost power or reset, the data is lost. The application would required to update the data every time a count occurred.

The data captured in SRAM would then need to be transferred to a non volatile (flash) area of the internal memory of the device.

#memory #cortex-m0
4 REPLIES 4
Uwe Bonnes
Principal III
Posted on February 26, 2016 at 16:48

Think about battery buffering the RTC and using the RTC general purpose registers for non-volatile storag. Or think about using an L0 with EEPROM. Otherwise writing to flash will stall flash based code during write  and erase and will easily wear out the flash.

Posted on February 26, 2016 at 17:12

+1 for BKPRAM

The L0 is designed to run from a battery, shouldn't be hard to construct an external supply + battery arrangement that would do this quite effectively.

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
AvaTar
Lead
Posted on February 27, 2016 at 10:23

Perhaps a MCU system with FRAM memory would serve you better.

FRAM has a practically unlimited number of R/W cycles, much faster access times, and simple byte/half-word/word access.

Well, but not yet from ST ...

Zt Liu
Senior III
Posted on June 01, 2017 at 03:12

Hi, Mark!

1. For writing data to eeprom or flash, you may check hal libraries api functions in stm32f0xx_hal_flash.h or stm32f0xx_hal_flash_ex.h. Examples are in STM32Cube_FW_F0_Vx.x.x\Projects\STM32F070RB-Nucleo\Examples\FLASH. (if you are using F070)

2. For backup power design, I found this application note quite helpful for me.

(How to design a VBAT system based on STM32L0/L1 series (with external components)

http://www.st.com/content/ccc/resource/technical/document/application_note/0d/1d/ae/7f/f9/e8/41/65/DM00206898.pdf/files/DM00206898.pdf/jcr:content/translations/en.DM00206898.pdf

 

Good luck!