View Single Post
  #1   Spotlight this post!  
Unread 29-01-2005, 16:40
CmptrGk's Avatar
CmptrGk CmptrGk is offline
Programming Mentor
AKA: Dillon
FRC #0716 (Who'sCTEKS)
Team Role: College Student
 
Join Date: Jan 2004
Rookie Year: 2004
Location: Kent,CT
Posts: 212
CmptrGk has much to be proud ofCmptrGk has much to be proud ofCmptrGk has much to be proud ofCmptrGk has much to be proud ofCmptrGk has much to be proud ofCmptrGk has much to be proud ofCmptrGk has much to be proud ofCmptrGk has much to be proud of
problem with void Process_Data_From_Local_IO

ok, this has been sort of annoying, mplab says that there is a syntax error in this line void Process_Data_From_Local_IO(void) this to me makes no sense whatsoever. also, it says that there is a syntax error on the last line of the program which is completly blank. here is the problem code
Code:
 /*******************************************************************************
 * FUNCTION NAME: Process_Data_From_Local_IO
 * PURPOSE:	   Execute user's realtime code.
 * You should modify this routine by adding code which you wish to run fast.
 * It will be executed every program loop, and not wait for fresh data 
 * from the Operator Interface.
 * CALLED FROM:   main.c
 * ARGUMENTS:	 none
 * RETURNS:	   void
 *******************************************************************************/
 void Process_Data_From_Local_IO(void)
 {
 	  if (p3_sw_aux1 == 0 && p3_sw_top == 0 && p3_sw_trig == 0)
 	{
 		   auton_state = 1;
 	 }
 
 	 else if (p3_sw_aux1 == 1 && p3_sw_top == 0 && p3_sw_trig == 0)
 	{
 		auton_state = 2;
 	  }
 
 	else if (p3_sw_aux1 == 0 && p3_sw_top == 1 && p3_sw_trig == 0)
 	{
 		auton_state = 3;
 	}
 
 	  else if (p3_sw_aux1 == 0 && p3_sw_top == 0 && p3_sw_trig == 1)
 	{
 		auton_state = 4;
 	  }
 
 	  else if (p3_sw_aux1 == 1 && p3_sw_top == 1 && p3_sw_trig == 0)
 	{
 		auton_state = 5;
 	 }
   
 	else if (p3_sw_aux1 == 1 && p3_sw_top == 0 && p3_sw_trig == 1)
 	{
 		auton_state = 6;
 	}
 
 	 else if (p3_sw_aux1 == 0 && p3_sw_top == 1 && p3_sw_trig == 1)
 	{
 		auton_state = 7;
 	}
 
 	  else if (p3_sw_aux1 == 1 && p3_sw_top == 1 && p3_sw_trig == 1) 
 	{
 		auton_state = 8;
 	}
 	
 	
 }
 
 }
 
 
 /******************************************************************************/
 /******************************************************************************/
 /******************************************************************************/
__________________
#14


"Great autonomous mode Dillon."," It hasn't been written yet"
after an Archimedes match