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

EXPORT requires IDE

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



Joined: 25 Oct 2013
Posts: 2

View user's profile Send private message

EXPORT requires IDE
PostPosted: Fri Oct 25, 2013 2:54 pm     Reply with quote

Hi,

I am using Proteus V8.1 VSM to simulate some microcontroller work I'm under contract for. We've purchased the PCH command line compiler and I'm working on a simple simulation for PIC18F4550. I just wanted to make sure the compiler was installed and running correctly so I tried to build just the starter file in the proteus environment:

Code:

/* Main.c file generated by New Project wizard
 *
 * Created:   Fri Oct 25 2013
 * Processor: PIC18F4450
 * Compiler:  CCS for PIC
 */

#include <18F4450.h>

int main (void)
 {
   // Write your code here
   while (1)
      ;
   return 0;
 }   


The command line and error generated is:

ccsc.exe -J +DF +ES -P -Z +O8 +CC +EXPORT +FH "main.c"
make: *** [main.o] Error 1

Error code 2

*** Error 7 "C:\Program Files (x86)\PICC\devices\18F4450.h" Line 36(9,15): Invalid Pre-Processor directive Export requires IDE
1 Errors, 0 Warnings.
Build Failed.

I'm not understanding why this build would fail inside of a device file.
[/code]
temtronic



Joined: 01 Jul 2010
Posts: 9163
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Fri Oct 25, 2013 3:07 pm     Reply with quote

Quick comments...

First you must understand that Proteus is NOT well liked here!! It's full of bugs,errors and faulty DRCs.NOT worth using in my opinion, best to use real PICs and test in the real World.

Second...

return 0;

This line of code makes no sense. Just where would MAIN return 0 to?

Others will know about EXPORT....I've never knowingly used it in the past 15 years.

hth
jay
MarkRHolbrook



Joined: 25 Oct 2013
Posts: 2

View user's profile Send private message

PostPosted: Fri Oct 25, 2013 3:19 pm     Reply with quote

Thanks for the reply temtronic.

Proteus is used for ideas only. I have PICs and demo boards.

As far as the return 0, agreed it is a nonsense statement but a valid one. IE it is legal is most dialects of C to have main return and integer value. But yes in a PIC you are absolutely right... why would it return and to what to...

Also is the observation that while(1); is endless so the return would never be reached.

All that my friend is beside the point. Regardless of whether Proteus is liked or the return 0 exists or does not my paid for and purchased copy of command line PCH seems to fail and I cannot find any documentation on why EXPORT would require the IDE only.

I did try removing it from the command line compile and I get a linker error of some kind.

I started using CCS back in 2001. Had issues then and struggled. I even have PIC code with comments like:

/* Following line gives a compile error */
/* ... some commented out valid piece of code like: c = c + 1; */

It seems 12 years later that CCS is still problematic.

Hopefully someone will give me direction on the command line parms which seem to be ill documented as well.

Thanks for the reply.
dyeatman



Joined: 06 Sep 2003
Posts: 1923
Location: Norman, OK

View user's profile Send private message

PostPosted: Fri Oct 25, 2013 3:46 pm     Reply with quote

Note from CCS Web site:
http://www.ccsinfo.com/faq.php?page=multi_comp_units

Quote:
In order to create a project using multiple compilation units, one of
the following IDE versions of the CCS C Compiler needs to be used: PCW,
PCWH, PCWHD, PCDIDE.


Apparently PCH command line version is not supported for multiple
compilation units. The PCWH (IDE version) is required.
_________________
Google and Forum Search are some of your best tools!!!!
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