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.

CC2640R2F: SysCtrlSystemReset() issue

Part Number: CC2640R2F
Other Parts Discussed in Thread: CC2640

Hi,

I am having some issues with resetting the cc2640r2flp from the software. I am using the software UART (sensor controller) to receive some commands from the PC. One of the commands is to perform a system reset.

The issue: I start the debugger and run the code. After running the code, I terminate the debugger. After this, I send the command to cc2640r2flp to perform a system reset which executes the function SysCtrlSystemReset(). But the cc2640r2flp does not reset and boot back up again.

However, after the above scenario, I reset the device manually by pressing the onboard reset switch, here on whenever I send the command to the cc2640, it resets properly and boots back up again. Any insights on why this is happening?

SDK: 2.40

Project: Multi-role

Vinay

  • Hi Vinay,

    Have you run the software in debug mode and verified that SysCtrlSystemReset get called properly?

  • Yes I have. In debug mode, as soon as the  SysCtrlSystemReset( ) is called, the debugger gets disconnected in the midst of debug mode which I believe is due to the device trying to invoking a reset. But problem is, when not in debug mode, the reset may be happening but for some reason, it does not boot up or start advertising as normally it does.

    I was able able to solve the above problem by using the RESET pin of the cc2640. But I am still curious to know why SysCtrlSystemReset( ) fails until the board is power cycled via the reset button. I am using another small controller to perform OTA on the cc2640 using the serial bootloader library. Would be good to have the SysCtrlSystemReset( ) work well as it can save a gpio on the other one to use for something else.

    Any more pointers to figuring out why this may be happening?

  • Vinay Divakar said:
    does not boot up or start advertising as normally it does.

    Is it setup to start advertise on boot up?

    In the OAD example I see that this API is used instead:

          // Reset the system
          HAL_SYSTEM_RESET();

    Have you tried that?

  • Yes, it starts connectable advertising as soon as it boots up.

    Just tested with the HAL_SYSTEM_RESET() and still the same issue as that of SysCtrlSystemReset( ).

  • Hello Vinay,

    Are you running a BIM in you project?

    If yes, could there be a issue with the BIM when you initiate debug mode directly from the application vs. boot normally through BIM?