Enable semihost debug printing

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

Enable semihost debug printing

2,413件の閲覧回数
maleman
Contributor I

MCUXpresso version: 11.4.1
SDK MCU: MKV31F512xxx12
board: frdmkv31f

Project is using freedom_bootloader, when creating the project, semihost is selected for the SDK Debug Console under Project Options.

Have tried creating the project using different library types like Redlib(semihost), NewlibNano(semihost) but the SDK Debug Console is still often not set to semihost, and calls to printf() or debug_printf() do not appear in the console.

Have tried managing the MCU linker script to reselect these same libraries, which results in a MCU linker error regarding the location counter address.

Would appreciate any advice on how to set up the MCU linker for this

0 件の賞賛
返信
2 返答(返信)

2,378件の閲覧回数
maleman
Contributor I

Hi Daniel,

Thanks for your reply. I had SDK_DEBUGCONSOLE=0 in my project settings, but I think the semihosting would not work for me because of active interrupts in the program I was running (https://community.nxp.com/t5/LPCXpresso-IDE-FAQs/What-is-Semihosting/m-p/475390). Got it working with UART instead

0 件の賞賛
返信

2,393件の閲覧回数
danielchen
NXP TechSupport
NXP TechSupport

Hi maleman:

 

Please check the project properties, change the preprocessor macro  from SDK_DEBUGCONSOLE=1  to SDK_DEBUGCONSOLE=0

0 means output to toolchain.

1 means output to SDK version printf

 

danielchen_0-1641436108762.png

 

Regards

Daniel

 

0 件の賞賛
返信