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

How can I protect my chip from hex file copy?

  1. There is a check box on nRFgo Studio, Lock entire chip from readback. But a lot of chip can not burn one by one

  2. Can I use AES block encryption to do this?

Parents
  • If you want to avoid anyone being able to read out your firmware over the SWD interface, you have to enable readback protection. This can be done with nRFgo Studio, or any other programmer, as it's really just setting a UICR register to a specific value. See the definition of the RBPCONF register in the nRF51 Reference Manual.

    There is no way you can use the AES module to encrypt your code or anything similar.

    Edit: You can set RBP in multiple ways:

    1. Make code in your main application to enable flash writes, do the write and then disable flash writes.
    2. Include the value in your build, like done in the uicr_example in the SDK. This will cause RBP to be set during regular programming of the hex.
    3. Use a programmer to specifically set this register. This can be done with nrfjprog using the --rbp command line parameter, and most likely in similar ways with other programmers.

    For further tips on production programming, take a look at this question.

Reply
  • If you want to avoid anyone being able to read out your firmware over the SWD interface, you have to enable readback protection. This can be done with nRFgo Studio, or any other programmer, as it's really just setting a UICR register to a specific value. See the definition of the RBPCONF register in the nRF51 Reference Manual.

    There is no way you can use the AES module to encrypt your code or anything similar.

    Edit: You can set RBP in multiple ways:

    1. Make code in your main application to enable flash writes, do the write and then disable flash writes.
    2. Include the value in your build, like done in the uicr_example in the SDK. This will cause RBP to be set during regular programming of the hex.
    3. Use a programmer to specifically set this register. This can be done with nrfjprog using the --rbp command line parameter, and most likely in similar ways with other programmers.

    For further tips on production programming, take a look at this question.

Children
No Data
Related