This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Any sample for embedding binary or text file to be available as variable in the code?

ESP32 has this in the build system, I was wondering if there is any sample in nrf52 This helps in embedding private key/ certificates easily.

Parents
  • Hi 

    Would it be possible to use something like this to convert the binary file to a C array?

    Then you can easily reference the data from the code. 

    The tool I linked to above will make the array const, which ensures it is put in flash and not in RAM. 

    Another method is to convert the binary to a hex file, and have Segger Embedded Studio load the hex file when you flash the code. 

    Best regards
    Torbjørn

Reply
  • Hi 

    Would it be possible to use something like this to convert the binary file to a C array?

    Then you can easily reference the data from the code. 

    The tool I linked to above will make the array const, which ensures it is put in flash and not in RAM. 

    Another method is to convert the binary to a hex file, and have Segger Embedded Studio load the hex file when you flash the code. 

    Best regards
    Torbjørn

Children
Related