fickle autonomous

In autonomous mode i have entered the program and all errors are fixed but one, a syntax error. when i call it up it is 2 lines after all code is finished, nothing is there, how do I fix this phantom error?

It is most likely a missing end bracket, or less likely, you forgot your semicolon on the last statement.

hehe and you were right, again if LaBar or Jake is avalible, try them first to make things faster because programming is easier to troubleshoot in real life and I believe I have enough knowledge to trouble shoot programming also.

To give an Idea of the problem i’m having, when i compile it the following message appears: (note: it is typed exactly as seen after this line)

Skipping file. There is no tool to process the file with the given suffix.
Skipping link step. Not all sources built successfully.
BUILD FAILED: Mon Jan 30 13:38:58:2006

if you can translate this and fix the error hypothetically plz let me know how!

Do all your source files end in .c?

IE no .cpp, .C, .cxx, .cc or anything else?

yes it’s titled static output.c

Ignore this, I fixed That problem, but now a new one pops up and it says this:

Make: The target “C:\Documents and Settings\jeffco\Desktop\autonomous.c\static output.o” is out of date.
Executing: “C:\mcc18\bin\mcc18.exe” -p=18F8722 “static output.c” -fo=“static output.o” /i"C:\Documents and Settings\jeffco\Desktop\012406c" -Ou- -Ot- -Ob- -Op- -Or- -Od- -Opa-
C:\Documents and Settings\jeffco\Desktop\autonomous.c\static output.c:55:Error: syntax error
Skipping link step. Not all sources built successfully.
BUILD FAILED: Mon Jan 30 15:55:19 2006

Well, it seems there is an error at line 55. Again, check for missing semicolons or brackets.

the thing is, there is NOTHING on line 55 or line 54 or line 56!

What about 53, 52, or 51? A syntax error that shows up on a line that doesn’t have anything is usually a missing bracket, parenthesis, or semicolon. Your problem isn’t actually at line 55, but the compiler thinks it is because your syntax from a previous line is invalid.

I shall check.

all brackets, parenthesis, and semicolons are accounted for. any other possibilities?

The phase of the moon, the tides, the compiler’s horoscope…

There are times when the compiler will just spit at you and throw semingly random syntax errors.

Open the file in notepad, and check to make sure there’s nothing there.

Look for syntax errors at the previous code line.

Contact someone and have them check.

If I remember correctly, the tools choke if your path or file name have an embedded space. Move your project off your desktop to something like c:\code and rename your source file(s) static_output.c, etc.


You probably did this, but go to Project->Clean then try building.

I also don’t know how tolerant MPLab is of alternate line break settings - did you by chance write your code on Linux or a Mac?

Lastly, try selecting lines 54-56 together and deleting them. Maybe there’s a hidden character somewhere (maybe way off the right margin?).

EDIT: oh, and make sure any strings you use have beginning and ending quotes - MPLab has given me errors in weird places when I’ve forgotten to close a string.

ok to give everyone a clear picture of the problem i will post the error message and the code itself, btw i tried both of your suggestions, it didn’t like either of them. (note: tabs are included in the proper areas)
Skipping file. There is no tool to process the file with the given suffix.
Skipping link step. Not all sources built successfully.
BUILD FAILED: Tue Jan 31 13:42:48 2006
#include <stdio.h>

#include “ifi_aliases.h”
#include “eeprom.h”
#include “ifi_default.h”
#include “ifi_utilities.h”
#include “serial_ports.h”
#include “terminal.h”
#include “tracking.h”
#include “tracking_menu.h”
#include “user_routines.h”
#include “camera.h”
#include “camera_menu.h”

void User_Autonomous_Code(void)
/* Initialize all PWMs and Relays when entering Autonomous mode, or else it
will be stuck with the last values mapped from the joysticks. Remember,
even when Disabled it is reading inputs from the Operator Interface.
pwm01 = pwm02 = pwm03 = pwm04 = pwm05 = pwm06 = pwm07 = pwm08 = 127;
pwm09 = pwm10 = pwm11 = pwm12 = pwm13 = pwm14 = pwm15 = pwm16 = 127;
relay1_fwd = relay1_rev = relay2_fwd = relay2_rev = 0;
relay3_fwd = relay3_rev = relay4_fwd = relay4_rev = 0;
relay5_fwd = relay5_rev = relay6_fwd = relay6_rev = 0;
relay7_fwd = relay7_rev = relay8_fwd = relay8_rev = 0;
static unsigned int t;
while (autonomous_mode) /
if (statusflag.NEW_SPI_DATA) /
26.2ms loop area /
Getdata(&rxdata); /
DO NOT DELETE, or you will be stuck here forever! */

    /* Add your own autonomous code here. */

		if (t&lt;19)
			pwm01=190;   /* left motor */
			pwm02=190;   /* right motor */
			pwm03=127;   /* launcher motor */
			pwm04=127;   /* feeder motor? */
		else if (t&lt;38)
	 	else if (t&lt;95)
		else if (t&lt;380)



You’re missing a closing brace

Line 70 lines up with 32
Line 71 lines up with 30
Line 72 lines up with 27

Line 16 has an open brace but no matching closing brace

use the code ] tag next time, please.

what is a code tag? a thread name?

you weren’t using the entire “bells and whistles” default programming. you were trying to make a brand new program of your own. so try again using the code me and Jake’s been altering because I bet you need the vaules of what are the pwm outputs(because we’ve completely changed them) and a whole bunch of other stuff.

When I saw your screen, you were missing a bunch load of files. And can’t just dump all the files your missing right into the workspace. Load “bells and whistles” and redo it. Or else you’ll never get the autonomous code to work.

A code tag is an attachment that you can just put the code into so you don’t take up half the screen.

By nickname Jake was asking, he was asking what’s your nickname, not your s/n. Like mine is Light Goddess in the theatre dept.