Jump to content
Sign in to follow this  

#warning directive in CCS5?

Recommended Posts

I'm trying to use the ANSI C #warning directive in CCS5.


CCS5 it claims that it's an unrecognized pre-processor directive. :?




I would like to use it to remind myself that I need to take care of something in the code - like a reminder "remember to kill the watchdog".


It then should show up as a yellow flagged Warning in the Problems window.


Anybody else trying/doing this?

If so, how did you get it to work?

Share this post

Link to post
Share on other sites

I must have a bad memory because I thought for sure that my buddy said that it was an ANSI C standard thing.


He must have meant GNU standard thing.



Share this post

Link to post
Share on other sites

you can use the assembler message, warning, and error directives as well.

asm(" .mmsg \"Your Message\"");

which i use to output messages in the build console.

*** MESSAGE! line 225: ___ _ ___ __ __ __ __ ___ ___
*** MESSAGE! line 226: | __| /_\ / __|\ \ / /| \/ |/ __|| _ \
*** MESSAGE! line 227: | _| / _ \ \__ \ \ V / | |\/| |\__ \| _/
*** MESSAGE! line 228: |___|/_/ \_\|___/ |_| |_| |_||___/|_|
*** MESSAGE! line 230: EasyMSP is compiling...
*** MESSAGE! line 231: Using board: LaunchPad
*** MESSAGE! line 232: Device is MSP430G2553
*** MESSAGE! line 233: Series is Value Line

Share this post

Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Create New...