Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Problems with MPLAB (http://www.chiefdelphi.com/forums/showthread.php?t=25978)

Charley 24-02-2004 19:01

Problems with MPLAB
 
I got the following error when trying to build:

C:\Documents and Settings\donnyb\Desktop\FIRST\Frc\Rev 03\ifi_aliases.h:18: malformed #include directive
error 1 spawning c:\mcc18\bin\cpp18

MPLAB has not been used on this computer yet, but all the files have built correctly on our other computer. So... is it a software problem?

Thanks,
Char.

WCS V 24-02-2004 19:35

Re: Problems with MPLAB
 
I think that the problem is that the path is too long. MPLAB has a problem with paths that are more than 32 characters. Try a shorter path.

Mark McLeod 24-02-2004 19:36

Re: Problems with MPLAB
 
Quote:

Originally Posted by Charley
I got the following error when trying to build:

C:\Documents and Settings\donnyb\Desktop\FIRST\Frc\Rev 03\ifi_aliases.h:18: malformed #include directive
error 1 spawning c:\mcc18\bin\cpp18

MPLAB has not been used on this computer yet, but all the files have built correctly on our other computer. So... is it a software problem?

Thanks,
Char.

One problem is your project is too far down in the directory tree. Move FIRST to the top level of your C drive, e.g., "C:\FIRST\Frc\Rev 03"

Charley 24-02-2004 19:47

Re: Problems with MPLAB
 
I just fixed that, now the same error occurs with the new directory

Greg Ross 24-02-2004 20:43

Re: Problems with MPLAB
 
Quote:

Originally Posted by Charley
I just fixed that, now the same error occurs with the new directory

New message, please? Have you tried reinstalling MPLAB? Did you install from the CD included with your Edu Robot/controller? Did you follow the FIRST specific installation instructions? Did you miss installing the C18 compiler?

Paradox1350 24-02-2004 21:11

Re: Problems with MPLAB
 
I'm on Charley's team. We have not tried reinstalling. We lost the disc that came with the EDU bot kit and transfered the files from one computer to the laptop that we have. The program works on the original computer, but not the laptop. I have no idea whether or not we are missing the C18 compiler.

Mark McLeod 24-02-2004 21:14

Re: Problems with MPLAB
 
Quote:

Originally Posted by Paradox1350
I'm on Charley's team. We have not tried reinstalling. We lost the disc that came with the EDU bot kit and transfered the files from one computer to the laptop that we have. The program works on the original computer, but not the laptop. I have no idea whether or not we are missing the C18 compiler.

Do you have a "c:\mcc18" directory? That's the compiler.

The error you are getting occurs the first time you try to access a file in the mcc18 directory called adc.h

This can occur if it is missing, but also if your MPLAB project is not set-up correctly. You can check under Project->Build Options...->Project to see everything's set properly.

Include Path c:\mcc18\h
Library Path c:\mcc18\lib

and for good measure under the MPLAB C18 tab is _FRC_BOARD listed under Macro Definitions?

Paradox1350 24-02-2004 21:32

Re: Problems with MPLAB
 
We do have a "c:\mcc18" directory.

Message: "error 1 spawning C:\mcc18\bin\cpp18" after I verified the build options were set properly. I have no idea what this means!

deltacoder1020 24-02-2004 21:36

Re: Problems with MPLAB
 
i'm willing to guess it just means that mcc18 didn't like something you sent it, hence the "malformed #include directive" error - look at line 18 in ifi_aliases.h and see if someone accidentally bumped a key and inserted a character or something.

zeep25 24-02-2004 21:59

Re: Problems with MPLAB
 
wait so ur saying u didnt have the mplab cd so you copied the files (the mplab and mcc18) from the other computer where it works :s ?

if so try this ... remove the directories and download the MPLAB[30 Megs] and mcc18 (demo)[10 megs] from the microchip website

and install the mplab first and tghen mcc18 ... make sure when ur installing mcc18 you check on when it asks you to configure mplab to use this version of mcc18 and stuff ...

if you didnt copy the files over and installed them ... try removing them from add/remove program and then do a fresh clean installation (as mentioned above)

btw what is the directory path to the files now ?

Mark McLeod 24-02-2004 22:25

Re: Problems with MPLAB
 
Quote:

Originally Posted by Paradox1350
We do have a "c:\mcc18" directory.

Message: "error 1 spawning C:\mcc18\bin\cpp18" after I verified the build options were set properly. I have no idea what this means!

Check the toolsuite locations.
under Project->Select Language Toolsuite...

Under Toolsuite Contents "MPLAB C18 C Compiler (mcc18.exe)" should be listed.
Click on that line and see that the Location shows "C:\mcc18\bin\mcc18.exe"

Descartes 25-02-2004 09:50

Re: Problems with MPLAB
 
We had the exact same problem, same errors and everything. Its turns out its an occasional MPLAB bug where the compiler cannot locate the Language Toolsuite , even if you have it pointing right at it. We actually tried the exact method that McLeod there suggested. Didn't work. Only solution we found was to back up your source code and uninstall and reinstall MPLAB.

Mark McLeod 25-02-2004 10:28

Re: Problems with MPLAB
 
Quote:

Originally Posted by Descartes
We had the exact same problem, same errors and everything. Its turns out its an occasional MPLAB bug where the compiler cannot locate the Language Toolsuite , even if you have it pointing right at it.

Just curious, what version of MPLAB are each of you using?
We're running MPLAB 6.4 downloaded from the Microchip site, rather than the 6.3 version shipped with the EDU Bot.

Greg Ross 25-02-2004 15:12

Re: Problems with MPLAB
 
Quote:

Originally Posted by Paradox1350
We do have a "c:\mcc18" directory.

Message: "error 1 spawning C:\mcc18\bin\cpp18" after I verified the build options were set properly. I have no idea what this means!

Is there a cpp18 there?
Quote:

Originally Posted by deltacoder1020
i'm willing to guess it just means that mcc18 didn't like something you sent it, hence the "malformed #include directive" error - look at line 18 in ifi_aliases.h and see if someone accidentally bumped a key and inserted a character or something.

I think it's more likely that it means that when it encountered the #include directive, and went to spawn cpp18.exe (the preprocessor) it didn't find it in C:\mcc18\bin where it expected to find it.

Descartes 25-02-2004 15:29

Re: Problems with MPLAB
 
The problem occured on our backup PC, while I was updating it. Our main computer for programming had the up - to - date version, but the backup did not.

Incidentally, I discovered another solution. Under "Projects, Build Options, Project." Click on the General tab. If your Include Directory does not have anything in it, point it at the c:/mcc18/

This worked for us.

Ryan M. 25-02-2004 15:50

Re: Problems with MPLAB
 
Quote:

Originally Posted by Paradox1350
I'm on Charley's team. We have not tried reinstalling. We lost the disc that came with the EDU bot kit and transfered the files from one computer to the laptop that we have. The program works on the original computer, but not the laptop. I have no idea whether or not we are missing the C18 compiler.

There are changes that the installer makes to your PATH environment environment variable. You need to set it the same way that the computer it is working on is set to. To access the path, open a run box and type "msconfg". Hope that helps. If you need more help with modifying the PATH post. :)

Jared Stofflett 25-02-2004 16:09

Re: Problems with MPLAB
 
Just to add to all this I tried running the newest version of the ide off the web sight on xp and it didn't work, the version that shipped with the kit worked. Something with either version 6.31 or 6.4 not working with nt based opperating systems.

Astronouth7303 25-02-2004 16:12

Re: Problems with MPLAB
 
6.3 works fine on XP and 2k. I don't think it's the version.

ps- is there a diference?

Mark McLeod 25-02-2004 16:41

Re: Problems with MPLAB
 
Quote:

Originally Posted by Jared Stofflett
Just to add to all this I tried running the newest version of the ide off the web sight on xp and it didn't work, the version that shipped with the kit worked. Something with either version 6.31 or 6.4 not working with nt based opperating systems.

Several of the schools I'm working with are using MPLAB 6.4 on XP systems.
There must be some other little quirks, like OS patch level, involved.

deltacoder1020 25-02-2004 17:25

Re: Problems with MPLAB
 
Quote:

Originally Posted by Texan
There are changes that the installer makes to your PATH environment environment variable. You need to set it the same way that the computer it is working on is set to. To access the path, open a run box and type "msconfg". Hope that helps. If you need more help with modifying the PATH post. :)

find autoexec.bat, and add the following lines to it:

set PATH="C:\mcc18\bin;%PATH%"
set PATH="C:\mcc18\mpasm;%PATH%"
set MCC_INCLUDE="C:\mcc18\h;%MCC_INCLUDE%"

(change the paths to match your copy of mcc18, of course)

Greg 25-02-2004 18:13

Re: Problems with MPLAB
 
Yes, this is a problem with PATH. I wanted to post from school earlier today, but for some reason I could not :) By the way, XP/2000 will ignore autoexec.bat by default. You change these values in Control panel>system>Advanced>Environment variables


All times are GMT -5. The time now is 23:59.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi