Permanent data storage in ble nano...........?



i need to permanently store some data like central address permanently . so i understand that ble nano does not have eeprom. and i can’t use EEPROM.H library. and ble nano can store data permanently in its flash memory . But i don’t know how to do that programatically. and i didn’t see any example code anywhere . so i request you to provide necessary details regarding my problem.

thank you


This is just a suggestion instead of the correct answer for you. You can check the SDK example in the SDK folder below. This example is not in Arduino environment. You may need to try which is the right library e.g. nRF51822_API.h or BLE_API.h when you port the code to Arduino IDE.
Flash write documentation



i am programming using arduino IDE. i am using BLE_API.h to program. I have gone through the SDK but i have not seen any solution.can u give me any example sketch showing flash memory handling…?

thank You.


I am in the same exact situation. Example for Arduino would be of great help.



please give me a solution. this is an important requirement of my project.


i have gone through nRF5_SDK_12.1.0_0d23e2a\examples\peripheral\flashwrite
but which shows an alert says


Hi, Has there been any success with this? I need to write some states to flash memory on the BLE Nano1



which is not possible to write a data into flash memory while programming with arduino IDE. currently i am working with mbed compiler and it is possible to handle the flash in mbed.


Hi Iqbal,
Thank you for your response…
Is there a special library in mbed that you use?
Would it be possible to get a code example for me to try make it work in Arduino IDE?


please take look here and here


Hey iqbal,
I need to store some data permanentaly using blenano, but working with i2c.h and eeprom.h its not possible. Were you able to store your data? If yes, Can you provide me a sample sketch?
This is for my thesis. Please help


hai jay

are you working with arduino IDE. are you ever tried MBED compiler…?


yes i am working with mbed compiler. Did you fugure it out with mbed compiler how to save persistant data


hai jay

i have already provided two links. please take a look at the previous comments.


Yes I understand I am little new to code could you provide me with a sample sketch to save an int value permanently in flash and read it as and when required.

Thank you


1 year has passed… Does anyone know if flashing on nrf51822 using arduino ide, is now possible?

I tried fstorage, pstorage, fds but no one seems to work :frowning:

Thanks you


giowild i’m looking for the exact same thing and i was searching the exact same answer as you. would appreciate some update. also thanks for all the info i found so far!