Reply
Highlighted
Posts: 28
Registered: ‎12-28-2013

SWO Terminal doesn't work after updating the Simplicity Studio

[ Edited ]

Hi,

 

The updated Simplicity Studio has separate icon for SWO Terminal (before is embedded in eA Commander).

The printf message can't display to SWO Terminal anymore after this update, what is the problem?

And it will have "Fatal Error - Connection with device lost..." if the reset key of STK is pressed. It doesn't have such problem on previous SWO Terminal software.

 

Akml

 

 

Posts: 487
Registered: ‎02-04-2013

Re: SWO Terminal doesn't work after updating the Simplicity Studio

Hi,

 

I couldn't get this to work either.  I'll check with the software team.

 

In the meantime, you can install the old eA Commander tool by adding the optional legacy package.  See the following KB article for more information:

http://community.silabs.com/t5/Silicon-Labs-Knowledge-Base/Installing-legacy-eA-Commander-and-eA-Pro...

 

Best regards,

ChrisM

Posts: 487
Registered: ‎02-04-2013

Re: SWO Terminal doesn't work after updating the Simplicity Studio

I reported the fatal error when resetting the MCU to our software team (reference: MCUAB-1722).

 

I was able to get the SWO terminal and debug console window to output ascii characters when using the recommended instructions (displayed when you first launch SWO Terminal):

 

*** This is a Serial Wire Output based console.***
To use it you must do two things:
1. Set up the Serial Wire Output in your application.
You can use the function below for this.
NOTE: This funtion is different than the one used
in the profiler!
2. To print a single character use the CMSIS function
ITM_SendChar(char c).

void setupSWOForPrint(void)
{
/* Enable GPIO clock. */
CMU->HFPERCLKEN0 |= CMU_HFPERCLKEN0_GPIO;

/* Enable Serial wire output pin */
GPIO->ROUTE |= GPIO_ROUTE_SWOPEN;

#if defined(_EFM32_GIANT_FAMILY) || defined(_EFM32_LEOPARD_FAMILY) || defined(_EFM32_WONDER_FAMILY)
/* Set location 0 */
GPIO->ROUTE = (GPIO->ROUTE & ~(_GPIO_ROUTE_SWLOCATION_MASK)) | GPIO_ROUTE_SWLOCATION_LOC0;

/* Enable output on pin - GPIO Port F, Pin 2 */
GPIO->P[5].MODEL &= ~(_GPIO_P_MODEL_MODE2_MASK);
GPIO->P[5].MODEL |= GPIO_P_MODEL_MODE2_PUSHPULL;
#else
/* Set location 1 */
GPIO->ROUTE = (GPIO->ROUTE & ~(_GPIO_ROUTE_SWLOCATION_MASK)) |GPIO_ROUTE_SWLOCATION_LOC1;
/* Enable output on pin */
GPIO->P[2].MODEH &= ~(_GPIO_P_MODEH_MODE15_MASK);
GPIO->P[2].MODEH |= GPIO_P_MODEH_MODE15_PUSHPULL;
#endif

/* Enable debug clock AUXHFRCO */
CMU->OSCENCMD = CMU_OSCENCMD_AUXHFRCOEN;

/* Wait until clock is ready */
while (!(CMU->STATUS & CMU_STATUS_AUXHFRCORDY));

/* Enable trace in core debug */
CoreDebug->DEMCR |= CoreDebug_DEMCR_TRCENA_Msk;
ITM->LAR = 0xC5ACCE55;
ITM->TER = 0x0;
ITM->TCR = 0x0;
TPI->SPPR = 2;
TPI->ACPR = 0xf;
ITM->TPR = 0x0;
DWT->CTRL = 0x400003FE;
ITM->TCR = 0x0001000D;
TPI->FFCR = 0x00000100;
ITM->TER = 0x1;
}

 

Best regards,

ChrisM