CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to support@ccsinfo.com

CCS Compiler and MPLABX

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
Andreas



Joined: 25 Oct 2004
Posts: 136

View user's profile Send private message

CCS Compiler and MPLABX
PostPosted: Thu Oct 08, 2015 12:41 pm     Reply with quote

Hello Friends

Has anybody an idea how it might be possible to set the Syntax checker of the MPLABX to recognize CCS Labels ?

a sample:

#use rs232(baud=9600,parity=N,xmit=PIN_C6,rcv=PIN_C7,bits=8,stream=Ser1,errors)

The Label "Ser1" is not recognized by the MPLABX IDE !

Any Idea ??

best regards
Andreas
jeremiah



Joined: 20 Jul 2010
Posts: 1337

View user's profile Send private message

PostPosted: Thu Oct 08, 2015 4:04 pm     Reply with quote

Well it doesn't highlight it on my copy of MPLABX just putting that line in, but a suggestion:

Code:

#define DESCRIPTION_STREAM_NAME Ser1
#use rs232(baud=9600,parity=N,xmit=PIN_C6,rcv=PIN_C7,bits=8,stream=DESCRIPTION_STREAM_NAME,errors)


Usually MPLABX is happier if you have predefined the names. Also, it helps later maintenance to have a more readable stream name, something like GPS_STREAM, or DBG_STREAM, etc.
Andreas



Joined: 25 Oct 2004
Posts: 136

View user's profile Send private message

PostPosted: Thu Oct 08, 2015 11:48 pm     Reply with quote

Thanks jeremiah !

Yes, that helps a lot !

I wasnt Aware that MPLABX is much more Syntax sensitive than MPLAB.


best regards
Andreas
Ttelmah



Joined: 11 Mar 2010
Posts: 19447

View user's profile Send private message

PostPosted: Fri Oct 09, 2015 12:48 am     Reply with quote

This was why all the 'bif' definitions got added to the include files. Tells MPLAB-X that these are 'built in functions', and gives it the syntax for the variables. Otherwise just about every line of code gets complaints flagged up.
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group