PRINTF has no arguments when SDK_DEBUGCONSOLE is disabled

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

PRINTF has no arguments when SDK_DEBUGCONSOLE is disabled

1,233 次查看
buettgenbach
Contributor I

Hello,

using SDK 2.5.0 in "fsl_debug_console.h" the `PRINTF` macro is defined empty without any arguments when `SDK_DEBUGCONSOLE` is disabled. This leads to compiler warnings. Does anything speak up against defining the macro according to the standard library printf signature to avoid the warnings. like so: `#define PRINTF(fmt, ...)`??? I am currently redefining it like this to bypass the warnings when switching from debug to release build. Maybe this could be taken into account for the next version?!?!?!

Rgds

Markus

0 项奖励
回复
1 回复

1,102 次查看
FelipeGarcia
NXP Employee
NXP Employee

Hi Markus,

You shouldn't get any problems by setting #define PRINTF(fmt, ...). We appreciate your comments.

I recommend you to check the following documents for a better understanding of the debug console.

MCUXpresso IDE and Semihosting

Semihosting with GNU ARM Embedded (Launchpad) and Kinetis Design Studio | MCU on Eclipse

Best regards,

Felipe

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 项奖励
回复