View previous topic :: View next topic |
Author |
Message |
stoyanoff
Joined: 20 Jul 2011 Posts: 375
|
Why ccs TCP/IP stack doesn't want to work in MPLAB |
Posted: Sun Sep 30, 2012 1:49 am |
|
|
Hi! I have ccs TCP/IP stack version 30 November 06. My MPLAB is version 8.33 and the ccs complier is 4.065. So when I'm compiling the examples ex7a., ex7b.c and so on everything is OK. I tried to create a project in MPLAB with ccs complier and to compile the same examples, but the complier returns and error: You can not change the device type so far in the code 18F66J60. I'm not setting 66j60 but 67J60 as it must be. I'm not doing any other changes.
What am I doing wrong or just it can't work with MPLAB???
Thanks! |
|
|
Ttelmah
Joined: 11 Mar 2010 Posts: 19513
|
|
Posted: Sun Sep 30, 2012 2:37 am |
|
|
You are almost certainly including files other than the one containing the 'main' into the project.
In MPLAB, only the main file goes into the tab for 'source files'. Everything else can either be ignored, or must go into the 'header files' tab.
Anything in the 'source files' tab it tries to compile, and things like the stack, won't compile on their own, giving a lovely mix of errors.
Best Wishes |
|
|
stoyanoff
Joined: 20 Jul 2011 Posts: 375
|
|
Posted: Sun Sep 30, 2012 6:22 am |
|
|
I think I fixed it but I have another problem. It seem the different vesions of complier works with different stacks. I want to use TCP/IP stack and SD card on one controller so I just tried to load the ex_mdd_common.h to ex7a.c like that:
Code: |
#define ALLOW_GET_DISK_PROPERTIES //used by 'info' command
#include "ccstcpip.h"
#include "ex_mdd_common.h"
|
I removed the #device options from ex_mdd_common.h
Code: |
// #include <18f67j60.h>
// #fuses HS
// #fuses NOXINST
// #fuses NOWDT
|
It returns an error "Can not change device type so far in the code"
I think the problem is here
#include "filesystem\p18cxxx.h" but I`m not sure if it`s going to work on the controller properly without it.
Can you help me here?
How do you do this??
Thanks! |
|
|
|