Getting Error

I am developing a custom application that was started from 1 of the bluetooth examples for a customer and though I have been using the same custom PCB for 7 months, I am now, for the past few weeks, getting this error any time I run in debug mode. My application will run for a varying amount of time sometimes a second sometimes a minute then it throws the error. 

<error> app: ERROR 3735928559 [Unknown error code] at C:/nRF5_SDK_17.1.0_ddde560/modules/nrfx/hal/nrf_gpio.h:492
PC at: 0x00038B67
<error> app: End of error report

I was told to check out my call stack for further information and perhaps a clue as to which pin is causing this issue but the hex for the pin is changing every instance, I am attaching 2 screen captures as examples.

Any help is greatly appreciated.

Thank you

Matt

Parents Reply
  • Could you check if the «id» in this[id].stepper_step_pin is correct too? I am wondering if there is a chance it may have become out of bounds.

    Regarding the sd assert, the most common reason for it to occur is if you continue execution after having hit a breakpoint (it detects when its timing requirements have not been met, hence the assert). Could that be the explanation in this case maybe?

Children
  • You were 100% correct, the ID was being set to STEPPER_ID_MAX, which for us is wrong it should only be STEPPER_ID_LIFTER or_CAROUSEL. The interrupt for the motor stop was being executed at teh wrong time. That seems to have cleared up the nrf_gpio.h line 492.

    But I am still seeing SD Assert. After I pause execution in debug mode, are you saying that that is normal and not an error? If so is there anything I can do or not do to try and avoid causing that? I only ask because setting breaks and pausing to inspect variables is going to be essential to trouble shoot an application issue I am investigating that got this whole ball rolling

  • I am still getting <error> app: SOFTDEVICE: ASSERTION FAILED on every breakpoint or pause in debug mode

  • Thanks for confirming that it worked.

    mjconnor57 said:
    But I am still seeing SD Assert. After I pause execution in debug mode, are you saying that that is normal and not an error?

    Yes, it is a limitation when working with the Softdevice, and it can take some getting used to, unfortunately. You can mitigate the problem by enabling Monitor mode debugging (it enables you to hit breakpoints in lower priority interrupts context without halting the CPU). But in my experience, it's often easier to adapt the debug approach a bit instead. E.g. rely more on logging, always reset after hitting a breakpoint, etc.

    Also, as you might know, variables added to the "watch list" can be read periodically without halting the CPU:

Related