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

How do I solve this SoftDevice assert when I use IAR monitor mode debugger ?

I have integrated IAR code into my company system. with the Jlink_monitor.c, jlink_monitor.h , jlink_monitor_ISR_ISR.s and enableMonitorMode.mac.

Step 1: I loaded code to Nordic NRF52 target, set breakpoint. Step 2: once IAR hit breakpoint, then I did single step, then system reboot. with the message on the RTT console: :ERROR:SoftDevice assert PC=0x0001089e <==== ==== === It looks like to me IAR still can not work with Nordic NRF52 in monitor mode.

Do you have solution for this case ( IAR, Monitor mode with Nordic NRF52 softDevice) ?

I use nRF5_SDK_12.0.0_12f24da softDevice library.

  • There are some things to watch out for when using monitor mode debugging, have you looked at this blogpost?

  • George,

    As Ole has pointed out, if you follow the directions and caveats in the blog post that he linked to monitor mode debugging under IAR should be functional.

    1. Are you getting the Monitor Mode missing license prompt to indicate the MMD is being invoked. mmd prompt

    2. Are you using the correct jlink-monitor ISR file for IAR Workbench, namely; JLINK_MONITOR_ISR_IAR.s This file is contained in the JLink_Monitor_Code.zip file within the linked blog post.

    3. Have you tried any of the MMD example projects and managed to get those working under IAR/MMD in your environment?

    Once you have verified the above, post back and we can try to help you further.

    Regards

  • Hi Leonwj:

    1. Are you getting the Monitor Mode missing license prompt to indicate the MMD is being invoked. mmd prompt

    ANSWER:I do get MMD PROMPT, attached is my monitor mode pop-up window . Inline image 1

    1. Are you using the correct jlink-monitor ISR file for IAR Workbench, namely; JLINK_MONITOR_ISR_IAR.s This file is contained in the JLink_Monitor_Code.zip file within the linked blog post. Answer: I used the same JLINK_MONITOR_ISR_IAR.s, see attached file I used:

    2. Have you tried any of the MMD example projects and managed to get those working under IAR/MMD in your environment? Answer: I added those monitor files ( JLINK_MONITOR_ISR_IAR.s,, JLINK_MONITOR.c, JLINK_MONITOR.H and EnableMonitorMode.mac ) to .\nRF5_SDK_12.0.0_12f24da\examples\ble_peripheral\ble_app_hrs. It looks like IAR OK in monitor mode debugger.

      If this is not the MMD example projects you expected..... please let me know which examples I should use ( please pass dir path)?
      
  • Converted into an answer, as in a follow-up post the OP indicated that he had solved his code issue and managed to get MMD working.

    Hi George,

    Given your responses and in particular noting that your amended .\nRF5_SDK_12.0.0_12f24da\examples\ble_peripheral\ble_app_hrs example shows that MMD functions under IAR Workbench in your environment. It looks like you may be hard-faulting in the specific company code base that you mentioned in your original query (thereby causing a system reset).

    If you are not able to provide us with insight into that specific piece of code, then I would suggest setting up a hard-fault handler to determine the state (registers/vector table) of the nRF52 when the hard-fault is triggered. It would also be good for you to confirm the softdevice version in use.

    Let us know whether you need additional guidance once you have that info and/or if you need help getting there.

    Regards,

Related