This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Only JLink connection makes nrf5340 work

Hi!

We are working with the nrf5340 (custom board-revision QKAAAB) and we are facing an issue when resetting the application. If we add some functionalities to a bluetooth application it magically cannot boot again when we perform a pin-reset, but as soon as we click on "Connect J-Link" button in Segger Embedded Studio it starts performing perfectly. We had this issue before and removed anything related to RTT, semihosting, serial... But now we are stuck on it again and cannot make it work so we would like to understand, what does JLink do internally to connect to the target that makes the board behave differently from a pin-reset boot? Does it even reset the board? How does it wake it up? This issue is difficult to debug, because just as we connect the debugger the error is gone, so maybe a bit of theory on JLink behaviour could help us...

Thank you so much for your help!

UPDATE: if we configure a button to perform NVIC_SystemReset() instead of a pin-reset it resets also ok and all functionalities work. We have checked the erratas from "New and inherited anomalies" (https://infocenter.nordicsemi.com/index.jsp?topic=%2Ferrata_nRF5340_EngA%2FERR%2FnRF5340%2FEngineeringA%2Flatest%2Ferr_340_new.html) and doubt about these two: 49 and 55, but the registers seem ok. Where should we include the code that it is mentioned in the erratas?

Related