i.MX RT - How to use SWO trace

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

i.MX RT - How to use SWO trace

Jump to solution
3,728 Views
kenji
Contributor IV

HI All

Is it possible to use SWO trace on this development environment conditions?

[condition]

  • MIMXRT1060-EVK
  • Debug using LinkServer proves

Checking the SWO trace status, it seems not working?
Do I need to configure something on the MCU?

kenji_3-1627975677394.png

 

kenji_2-1627975636121.png

 

kenji_1-1627975559145.png

 

kenji_0-1627975534376.png

 

Tags (2)
0 Kudos
1 Solution
3,633 Views
kenji
Contributor IV

Hi @jingpan -san

I thought it was a SWO pin, but it's not right?
Ok, thanks.

kenji_0-1628848222099.png

 

View solution in original post

0 Kudos
9 Replies
3,581 Views
peter_fenn
Contributor V

1) Does MCUXpresso support SWO trace from an RT1176?
RT1170_BriefOverview_v110.pdf states the following:
While the MCU does support SWO, this feature is not available at the time of writing in the MCUXpresso IDE v11.3.1 + SDK tools.
It is expected that a later version of the tools will add support for SWO trace.


2) Does MCU-LINK debug probe support SWO trace? (from an RT1176) 
MCU-LINK is not one of the listed debug probes in MCUXpresso IDE SWO Trace User Guide (Rev 11.4.0 — 15 July, 2021)
This lists SWO support from the following debug probes: 

  • LinkServer LPC-Link2 (stand alone or built-in on many LPCXpresso dev boards and some iMX RT EVK boards)
  • SEGGER J-Link (all stand alone versions, refer to SEGGER website for details)
  • PEmicro (Multilink Universal RevD / Universal FX Rev C / ACP Rev B)
3,567 Views
brendonslade
NXP TechSupport
NXP TechSupport

Hi Peter,

 

SWO is supported by MCU-Link - looks like we just missed that in the User Guide. We'll get it corrected in the 11.4.1 release coming in September.

Thanks for reporting this.

3,717 Views
jingpan
NXP TechSupport
NXP TechSupport

Hi @kenji ,

Here is a RT1060 SWO demo. Please take a look. 

 

Regards,

Jing

0 Kudos
3,709 Views
kenji
Contributor IV

Hi @jingpan -san

Thank you for the sample code.
But not works.

I get the same message with own project.
This is the message when press "resume data display" button.

kenji_0-1628147405900.png

kenji_1-1628147419695.png

 

Your code doesn't seem to have any special settings, right?

I'm using  LinkServer proves for debug. Can SWO be used with Link Server proves?

 

0 Kudos
3,699 Views
lpcxpresso_supp
NXP Employee
NXP Employee

Please take a look at the following article: https://community.nxp.com/t5/MCUXpresso-Community-Articles/Overview-of-using-the-MIMXRT1060-4-EVK-wi...

SWO is supported only by LPC-Link2 firmware, not by DAP-Link.

Greetings,
MCUXpresso IDE Support

 

0 Kudos
3,680 Views
brendonslade
NXP TechSupport
NXP TechSupport

There is a more up to date (simplified) version of how to update the firmware on the i.MX RT1060 EVK in this application note:

https://www.nxp.com/docs/en/application-note/AN13206.pdf

(This is posted on the i.MX RT1060 product page)

You might find this article from Erich Styger's blog useful (note that this was written before the information on how to switch the on-board debug probe firmware to the LPC-Link2 firmware was published, so he used an external LPC-Link2):

https://mcuoneclipse.com/2019/06/03/swo-with-nxp-i-mx-rt1064-evk-board/

 

0 Kudos
3,654 Views
kenji
Contributor IV

Hi @brendonslade -san

Thanks to you I could ran SWO.

However, port for SWO trace, has use same port for PWM in my application.

So I try to use "IOMUXC_GPIO_B0_13_ARM_TRACE_SWO" port instead of "IOMUXC_GPIO_AD_B0_10_ARM_TRACE_SWO" port, but not works.

Do you know how to use "IOMUXC_GPIO_B0_13_ARM_TRACE_SWO" port for SWO?
Or is it unusable?

0 Kudos
3,638 Views
jingpan
NXP TechSupport
NXP TechSupport

Hi,

Have you set GPIO_B0_13 pin mux to swo? GPIO_B0_13 is a boot config pin. On RT1060 EVK, it is connected to VDD or GND.

 

Regards,

Jing

0 Kudos
3,634 Views
kenji
Contributor IV

Hi @jingpan -san

I thought it was a SWO pin, but it's not right?
Ok, thanks.

kenji_0-1628848222099.png

 

0 Kudos