This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Reset CPU lockup error when using USB CDC ACM as backend on Matter Template example (SDK v1.9.99)

Hello, I was trying to run the Matter template example on board nRF5340 DK.

By default, console and shell outputs used for this example, come via UART0 of the board. I'm using the prj.conf file. The example works as expected. In fact, using the CHIP-TOOL as Matter controller on Raspberry PI, I'm able to add my device (running the Matter template) to my Thread network. 

However, when I want to use USB CDC ACM as backend for console and shell, instead of UART0, after commissioning, my device resets in a loop. To use USB CDC ACM I added 2 overlay files to the original project Matter template :

- an overlay file containing extra Kconfig options to enable USB CDC ACM

- an overlay device tree file to active USB CDC ACM node and to link it to console and shell

Here, you can see the output of my Matter template example which uses USB CDC ACM as backend for console and shell. My program starts resetting at line 944 after getting Thread network credentials (PAN Id, channel, mesh prefix, etc)

I added as well to the main application the function  called hwinfo_get_reset_cause(uint32_t *cause) to get the type of error that causes this reset. When I print the value 'cause', I got 256 which means that the error is a RESET_CPU_LOCKUP error https://docs.zephyrproject.org/apidoc/latest/group__hwinfo__interface.html#gad6721dc841941ccdca349999ce655e83.

Could you give some ideas to understand why I get this kind of behavior please?  Why replacing UART0 by USB CDC ACM can lead to this kind of error?

Parents
  • Hi,

    Is there any specific reason you are running the latest dev tag and not the latest official release of nRF Connect SDK (v1.9.1)? Have you checked if you get the same error with v1.9.1?

    Not sure what could cause a CPU lockup. This could be triggered by a hardfault in the hardfault handler, but that would indicate something very wrong in the application.

    Can you read out the RESETREAS register directly from code (NRF_RESET->RESETREAS), or using a debugger, to verify that the bit on LOCKUP is set, or if LLOCKUP bit is set? Both can cause the RESET_CPU_LOCKUP return from hwinfo_get_reset_cause().

    Best regards,
    Jørgen

  • I'm using the version 1.9.99-dev because I know that it is compatible with the CHIP Tool controller. I read on Nordic website https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/ug_matter_configuring_controller.html#configuring-matter-controller that CHIP Tool is the recommended Matter controller.

    I didn't want to use the Python CHIP controller because I thought that later when the SDK version v1.9.99 will be released I should migrate from Python CHIP controller to CHIP Tool controller. That's why I decided to start working with the CHIP Tool controller and SDK v1.9.99-dev.

    I tried to run the Matter example template (SDK v1.9.1) with CHIP Tool controller but it does not work.

    I don't know if it is a good idea to work with Matter example template (SDK v1.9.1) and the Python CHIP controller.

    I will try to read out the RESETREAS register. Thanks for your help

    Do you know when the latest dev tag v1.9.99-dev will be released ?

Reply
  • I'm using the version 1.9.99-dev because I know that it is compatible with the CHIP Tool controller. I read on Nordic website https://developer.nordicsemi.com/nRF_Connect_SDK/doc/latest/nrf/ug_matter_configuring_controller.html#configuring-matter-controller that CHIP Tool is the recommended Matter controller.

    I didn't want to use the Python CHIP controller because I thought that later when the SDK version v1.9.99 will be released I should migrate from Python CHIP controller to CHIP Tool controller. That's why I decided to start working with the CHIP Tool controller and SDK v1.9.99-dev.

    I tried to run the Matter example template (SDK v1.9.1) with CHIP Tool controller but it does not work.

    I don't know if it is a good idea to work with Matter example template (SDK v1.9.1) and the Python CHIP controller.

    I will try to read out the RESETREAS register. Thanks for your help

    Do you know when the latest dev tag v1.9.99-dev will be released ?

Children
No Data
Related