Best way to write persistent data in factory

Hi, team.

I am trying to find a way to write some persistent data in factory.

The data is a couple of certificates and should be written differently for each devices.

What is the best way to achieve this?

I am considering to use NVS and zephyr settings libraries to save certificates, but want to know whether the better/recommended way exists.

And also, let me know some guideline how to make suitable format (like .hex, maybe?) for writing to flash with well-known flash writing tools like nrfprog or Programmer.

I tried to make my own CLI interface via UART, etc., but currently, target device is lack of resources, and can't afford for it.

Parents Reply
  • Hi,

     

    choehyunho said:
    Now what should I do? How can I create hex or binaries to write to settings partition?

    We do not have any examples for the PC platform that conforms to the NVS/"settings" format. This is why I proposed a solution for writing your data directly to the nRF flash, by reserving the space you need for writing your data.

     

    If you only read the data from the nRF-side, having it in NVS or any other filesystem-like architecture does not make that much sense.

    Again, it depends on what you need in this scenario, ie. if you're ever going to update these certs from the nRF etc.

     

    Kind regards,

    Håkon

Children
Related