This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CC1352R: Confused which CCFG defines for production to choose

Part Number: CC1352R
Other Parts Discussed in Thread: SEGGER

Hi TI and other CC1352R enthusiasts,

We have an issue regarding locking the CC1352R1F3 during our (mass-)production. We want that the chip will be not-readable, not writeable, and also not able to debug. But a chip erase via (c)JTAG must be possible in all cases! This is so we can re-program units from the 'field' and for debugging purposes.

I'm struggling to find the right defines to make this happen. If I set the this:
SET_CCFG_CCFG_TAP_DAP_0_PWRPROF_TAP_ENABLE    (0)
SET_CCFG_CCFG_TAP_DAP_0_CPU_DAP_ENABLE              (0)

, then our CC1352R gets bricked and then I can never use the chip erase again!

Can you help us to find the correct defines to have a locked CC1352R, but always chip erase-able?

The only option for us to connect to the CC1352R is via (c)JTAG.

What I've come up until so far:

// The valid image starts at address 0
#define SET_CCFG_IMAGE_VALID_CONF_IMAGE_VALID (0)
// Always allow a full chip erase
#define SET_CCFG_ERASE_CONF_CHIP_ERASE_DIS_N 0x1

// Access enabled if also enabled in FCFG
#define SET_CCFG_CCFG_TAP_DAP_0_CPU_DAP_ENABLE 0x0

// Access enabled if also enabled in FCFG
#define SET_CCFG_CCFG_TAP_DAP_0_PWRPROF_TAP_ENABLE 0x0

Thank you!

  • Hi Eric, 

    If you program your image using SmartRF Flash Programmer 2, you can use the "Lock Debug Interface" to make the device non-readable, non-writeable and non-debuggable. 

    Thanks, 
    Elin

  • I cannot do anything with the given answer since I use the J-Link with J-Flash. Anyway, I've came up with a solution and I hope I can help other who have this issue.

    The CC1352R was not bricked after all. 
    The defines SET_CCFG_CCFG_TAP_DAP_0_CPU_DAP_ENABLE (0) and SET_CCFG_CCFG_TAP_DAP_0_PWRPROF_TAP_ENABLE  (0) did not brick the chip. I use a J-Link with J-Flash and J-Flash did not erase before a connect upon a locked device, therefore I thought the chip was bricked.

    Upon a connect action on a locked CC1352R J-Flash came up with a question to erase before connect and I clicked on "remember this setting" and then on "No", as I wanted to do the erase action myself. Unfortunately every erase action resulted in an error that no connection could be made.

    I solved this 'error' by removing key AutoUnlockCC2538 from Computer\HKEY_USERS\SOME_NUMBER\SOFTWARE\SEGGER\J-Link. This setting was responsible for remembering the "No" button. Now every connect on a locked device results in a mass-erase, and therefore a repurposeable device.

    Using the following I managed to have a non-readable and non-writeable and non-debuggable device:
    #define SET_CCFG_CCFG_TAP_DAP_0_PWRPROF_TAP_ENABLE  (0)
    #define SET_CCFG_CCFG_TAP_DAP_0_CPU_DAP_ENABLE            (0)
    #define SET_CCFG_ERASE_CONF_CHIP_ERASE_DIS_N                  0x1
    #define SET_CCFG_ERASE_CONF_BANK_ERASE_DIS_N                 0x1