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.

Compiler/CC1352R: Flash memory don't reset after reprogramming

Part Number: CC1352R

Tool/software: TI C/C++ Compiler

Dear all,

I am Juan and I am having trouble with the flash memory when loading a binary into a CC1352R after the first time.

The thing is that:

1.- I set every single position of a sector of the flash memory I generated for non-volatile purposes to 0xFF.

2.- Then, I generate the binary file and with a binary program visualizer, I can see and confirm that these positions were correctly set to 0xFF. That means the flash memory sector is being initialized correctly and I am pointing to the correct addresses.

3.- After that, I let the program (which alters the values of the mentioned memory positions and uses this flash sector for data storage) run.

4.- After a while, I check the values of these memory positions with Flash Programmer 2 and I can see that they were correctly modified.

5.- Finally, the point is that when I upload the binary again to the CC1352R, so I reprogram the device, I check these values with Flash Programmer 2 and remain to the same value they had before reprogramming the device instead of 0xFF as the binary indicate should be.

6.- The behaviour should be as follows: when restarting the device, the sector keeps the values in every memory position (this is working), but when reprogramming the device, all the memory positions in the sector should be initialized to 0xFF, not keeping the values as when a restart happens.

This is such a weird behaviour, so if someone knows more about it or already faced a problem like this, I would be glad if he/she could help me.

Thanks so much in advance.

Best regards,

Juan

  • Hi Juan, 

    Which version of the SDK are you using? 

    I haven't heard about binary program visualizer, can you elaborate on which software it is etc? 

    Which settings are you using when reprogramming the device with Flash Programmer 2? Are you using erase, program, and verify? Which settings in each option?

    Are you using a LaunchPad or a custom board? 

    Thanks, 
    Elin

  • Hi Elin,

    thanks so much for your fast response.

    Here are the answers to your questions:

    1.- SDK version: 4.20.01.04.

    2.- Binary program visualizer: Beyond Compare 4 (I also tried with Binary Viewer).

    3.- Flash Programmer 2 settings: see picture below (I also tried without verifying).

    4.- I am using a custom board with the CC1352R MCU, but also I tried with the CC1352R LaunchPad and the same happens.

    If you need anything else, just let me know.

    Best regards,

    Juan

  • Hi Juan, 

    Can you test and erase all unprotected pages? That should reset all fields in memory to 0xFF before reprogramming the device. 

    How many pages is your image? On which page are you making these changes? 

    Thanks,
    Elin

  • Hi Elin,

    I test it with all unprotected pages but it happens still the same as before.

    I am writing these 0xFF from the memory position 0x52000 till 0x53FFF.

    BR,

    Juan

  • Hi Juan, 

    Thanks for sharing your progress. 

    So just to summarize your issue, the second time you program the binary file onto the LaunchPad (or custom board), you don't get the same results as the first time you do it? Which bytes are different? 

    Thanks, 
    Elin