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.

CC2642R: How to debug NVS issue?

Part Number: CC2642R

Tool/software:

Hi,

[sdk version][simplelink_cc13xx_cc26xx_sdk_7_10_01_24]

We have an issue that cc2642 couldn't get GAP_DEVICE_INIT_DONE_EVENT when bootup.

We found that if we erease the NVS area, then it could get GAP_DEVICE_INIT_DONE_EVENT after bootup.

Is there any parameters will the ble stack check from the NVS area when bootup? The parameters may be modified by accident. 

Thanks & Regards,

Kenny

  • Hi Kenny,

    Is this occurring in an example project or in a custom project? If it is in a custom project, then can you clarify if the NVS address has been modified or the region has been changed from the original?

    Best Regards,

    Jan

  • Hi Jan,

    We use a custom project (based on simple_peripheral_oad_offchip_CC26X2R1_LAUNCHXL_tirtos7_ticlang example project). 

    And we modified the region base to 0x3E000, region size to 0x8000. (original region base is 0x48000, region size is 0x4000.)

    We performed an erase to the whole flash when downloading image of the modified project at the first time.

    Thanks & Regards,

    Kenny

  • Hi Kenny,

    To confirm, if you revert the addresses to the original (0x4800 and 0x4000) does the issue disappear? If so, then I would suggest ensuring the addresses are also updated in the linker file.

    Best Regards,

    Jan

  • Hi Jan,

    The issue with the BLE stack failing to start does not always occur; it happens with low probability.

    However, once it fails to start, the only way to resolve it is by erasing the NVS to allow normal startup.

    Could you please help to confirm the following questions:

    1. Can the NVS size be set to 0x8000?
    2. The NVS might be unintentionally modified, what data within the NVS could affect the startup of the BLE protocol stack?

    Thanks & Regards,

    Kenny

  • Hi Kenny,

    Can the NVS size be set to 0x8000?

    As long as the size does not cause the NVS region to overlap with another allocated region it should be fine. If the size is being set to 0x8000, then make sure this is reflected in the linker file as this will help find if there are any conflicts.

    The NVS might be unintentionally modified, what data within the NVS could affect the startup of the BLE protocol stack?

    If the area used by the bond manager is modified unexpectedly then this may cause issues during bonding and re-pairing, but I do not expect it to cause the BLE Stack to not boot.

    Best Regards,

    Jan

  • Hi Jan,

    "If the size is being set to 0x8000, then make sure this is reflected in the linker file as this will help find if there are any conflicts."

    -- Which variables should I check in the linker file?

    I've read out the NVS area when this issue occurs, is there any method to analyze these NVS data?

    Thanks & Regards,

    Kenny

     

  • Hi Kenny,

    I took a look at the .cmd file and it seems no change should be needed there to accommodate fora  reduced size NV region. Can you try reducing that region to the minimum amount and testing to see if the example works as expected?

    Best Regards,

    Jan