View previous topic :: View next topic |
Author |
Message |
dish_moose
Joined: 06 Oct 2006 Posts: 13
|
Problem Compiling |
Posted: Mon Jan 19, 2015 1:42 pm |
|
|
Problem Compiling for 16F1718 using V 5.036
*** Error 28 "C:\Program Files (x86)\PICC\Devices\16F1718.h" Line 360(34,35): Expecting an identifier Bad SFR name
*** Error 48 "C:\Program Files (x86)\PICC\Devices\16F1718.h" Line 361(2,5): Expecting a (
*** Error 48 "C:\Program Files (x86)\PICC\Devices\16F1718.h" Line 361(6,13): Expecting a (
*** Error 43 "C:\Program Files (x86)\PICC\Devices\16F1718.h" Line 361(34,36): Expecting a declaration
*** Error 43 "C:\Program Files (x86)\PICC\Devices\16F1718.h" Line 361(35,36): Expecting a declaration
8 Errors, 0 Warnings.
Build Failed.
Just trying to get the LED blink to work first.
Code: | #include <NCO.h>
void main()
{
//Example blinking LED program
while(true)
{
output_low(LED);
delay_ms(DELAY);
output_high(LED);
delay_ms(DELAY);
}
} |
|
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19506
|
|
Posted: Mon Jan 19, 2015 1:50 pm |
|
|
Since the fault is in nco.h (as this is what loads the include file), post this. |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Mon Jan 19, 2015 1:54 pm |
|
|
Edit the 16F1718.h file and comment out these lines:
Code: |
// #bit PWM1OUT=getenv("BIT:PWM1OUT")
// #bit PWM2OUT=getenv("BIT:PWM2OUT")
// #bit PWM3OUT=getenv("BIT:PWM3OUT")
// #bit PWM4OUT=getenv("BIT:PWM4OUT")
|
Then it will compile OK. |
|
|
dish_moose
Joined: 06 Oct 2006 Posts: 13
|
|
Posted: Mon Jan 19, 2015 2:34 pm |
|
|
Here it is:
Code: | //////////// Standard Header file for the PIC16F1718 device ////////////////
#device PIC16F1718
|
+++++++++++++++++++++++++
Header file code removed.
Reason: Forum rule #10.
10. Don't post the CCS example code or drivers. This includes header files for devices (example 18f452.h).
http://www.ccsinfo.com/forum/viewtopic.php?t=26245
- Forum Moderator
+++++++++++++++++++++++++
|
|
|
dish_moose
Joined: 06 Oct 2006 Posts: 13
|
|
Posted: Mon Jan 19, 2015 2:47 pm |
|
|
As soon as I get permission to change the file - I'll give it a try.
Win 8.1....
-Thanks, Bruce |
|
|
ckielstra
Joined: 18 Mar 2004 Posts: 3680 Location: The Netherlands
|
|
Posted: Mon Jan 19, 2015 5:03 pm |
|
|
dish_moose wrote: | //// (C) Copyright 1996, 2014 Custom Computer Services ////
//// This source code may only be used by licensed users of the CCS C ////
//// compiler. This source code may only be distributed to other ////
//// licensed users of the CCS C compiler. No other use, reproduction ////
//// or distribution is permitted without written permission. ////
[/code] | Why is it that never anyone reads this part and behaves accordingly?
All users on this forum already have this file, so there is no reason at all to post it. |
|
|
dish_moose
Joined: 06 Oct 2006 Posts: 13
|
|
Posted: Tue Jan 20, 2015 2:26 pm |
|
|
Sorry - I was in a hurry - thought I was posting nco.h not 1718 .h
I was told the error was in nco.h and to post it but the error is in 1718.h
If Official support had answered me back in a timely fashion I would not have been in this situation.
One more thing, commenting out info in a header file worked yet I have no idea why. Can anybody explain why? Does this mean when I go to use the nco function or PWM output they will not function properly?
-Bruce |
|
|
PCM programmer
Joined: 06 Sep 2003 Posts: 21708
|
|
Posted: Tue Jan 20, 2015 2:33 pm |
|
|
It likely means that CCS forgot to define those bit names in the device
database file. That should have no effect on pwm function. However,
it does allow the possibility that the pwm functions may have other bugs
for that PIC with that compiler verison. |
|
|
|