AnsweredAssumed Answered

SWO Trace setup for LPC18xx

Question asked by LPCware Support on Mar 31, 2016

Clock Configuration

 

SWO Trace needs to be configured to match the current MCU clock speed in order to function correctly. Typically the LPCXpresso IDE can automatically detect this from the SystemCoreClock global variable.

 

However some older example code based on the older LPC18xx Peripheral Driver Library (PDL) codebase - for instance the legacy examples for the NGX and Hitex boards found in the "install_dir\lpcxpresso\Examples\NXP\LPC1000\LPC18xx" subdirectory of your LPCXpresso IDE installation - actually set SystemCoreClock incorrectly to 96000000 (96MHz). If you enter this value into the Clock speed setting of the SWO Config view, then you will not see any SWO trace data displayed.

 

For these PDL based examples, the actual setting you need to enter into the Clock speed setting is 72000000 (72MHz).

 

Note : There are no such issues if you are using projects based on LPCOpen - here the value of SystemCoreClock can be used directly.

 


 

For more information:

 

Outcomes