|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
||||
|
||||
|
WEIRD compiler error
I have a project that compiles just fine with older C18 versions, but
when i try to compile it under 2.4 i get the following errors: C:\mcc18\h\p18f8520.h:169:Error [1109] type mismatch in redeclaration of 'PORTBbits' C:\mcc18\h\p18f8520.h:201:Error [1109] type mismatch in redeclaration of 'PORTCbits' My project does not even reference these files anywhere in code. It uses ifi_picdefs.h. Does anybody have any idea whatsoever how to fix this? |
|
#2
|
||||
|
||||
|
Re: WEIRD compiler error
Which version of the default code are you using?
If you're not using version 2.4 (the one with the camera code), that could be your problem. |
|
#3
|
|||||
|
|||||
|
Re: WEIRD compiler error
Quote:
p18f8520.h has to match ifi_picdefs.h, and p18f8520.h has probably changed from the earlier versions of C18. See if there's a difference between the current default code's version of ifi_picdefs.h and the older one you're using. P.S. p18f8520.h gets dragged in by the compiler based on the target PIC model called out by the "-p=18F8520" statement in the compile line. Last edited by Mark McLeod : 02-02-2005 at 20:00. |
|
#4
|
||||
|
||||
|
Re: WEIRD compiler error
Quote:
|
|
#5
|
|||||
|
|||||
|
Re: WEIRD compiler error
Looking more closely I'm not so sure that really is the answer.
I tried removing my p18f8520.h file, then compiling and my project didn't mind a bit that it was gone. Maybe for some reason the old project is dragging that file in, but shouldn't be. |
|
#6
|
||||
|
||||
|
Re: WEIRD compiler error
Quote:
#if defined(BANKED) #error *** Error - Invalid 18f8520 header file! #else #define UNCHANGEABLE_DEFINITION_AREA 1 #endif |
|
#7
|
|||||
|
|||||
|
Re: WEIRD compiler error
Good deal!
Glad it worked out. As you know, it can be really hard to recreate someone else's error sometimes, so sometimes it's just semi-educated guesswork. |
|
#8
|
|||
|
|||
|
Re: WEIRD compiler error
WE just got the exact same problem, how you do you fix it again??
![]() |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| MPLink Error | cloudago | Programming | 2 | 01-02-2005 23:00 |
| IMPORTANT regarding the new C Compiler | dlavery | General Forum | 12 | 14-01-2005 05:05 |
| MPLAB IDE 6.60 Error | mchan1111 | Programming | 8 | 08-11-2004 20:17 |
| Confusing Compiler Error | UrsaMNet | Programming | 2 | 28-10-2004 14:32 |
| PHP and Wiki Error | Venkatesh | Website Design/Showcase | 2 | 24-07-2004 15:51 |