how to debug bus fault error reason in imxrt1170

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

how to debug bus fault error reason in imxrt1170

508 Views
burhanhagi
Contributor III

Hi all,

I coded a GUI with the help of Embedded Wizard software in IMXRT1170. I am using my own custom board. I am displaying PAL camera output on TFT display with ADV7280M decoder. It works well in normal usage scenario. However, when I try to remove camera from its socket while PAL video is outputting video to IMXRT1170, TFT display stays locked and very short time later, IMXRT1170 gives me "BUS FAULT error" in below Screenshot.

 

burhanhagi_0-1717772343059.png

 

I tried to find a way of which line of code exactly causes this to happen. However, since I am randomly removing camera cable from its connector, I could not catch the line where causing it. 

I have a debugger ULINK 2. How can I achieve to debug this kind of errors with debugger?

Is there a way to see previous lines in code just before this error in Screenshot with debugger?

Thanks a lot

0 Kudos
Reply
1 Reply

467 Views
diego_charles
NXP TechSupport
NXP TechSupport

Hi @burhanhagi 

I hope to find you well. 

The simplest way to check instruction calls is to expand the debug window. This may provide a little bit of info to begin.

diego_charles_0-1717792856978.png

But I think that trace could also provide you information. For SWO trace  refer to  AN14071 Trace Implementation on i.MX RT1170 .   Please note that the  ULINK 2 is only supported over the CMSIS DAP in the MCUXpresso IDE and we have not done a specific testing or development for this probe. So, I could only provide general ways to get debug working.

I cannot tell if you are using FreeRTOS. But maybe MCUXpresso IDE FreeRTOS Debug Guide could work with your probe. There is also a debug guide for Zephyr and other for ThreadX RTOS. There is also some general information on the MCUXpresso User Guide Chapter 14. You will find that guide in the installation path of MCUXpresso. Check the below example. 

diego_charles_1-1717794070623.png

I hope this could help you

Diego

 

 

0 Kudos
Reply