|
|
|
![]() |
|
|||||||
|
||||||||
|
|
Thread Tools | Rate Thread | Display Modes |
|
#1
|
||||
|
||||
|
Syntax Error!
I'm getting a syntax error on this line:
int Distance_Function(float tilt_angle_rad) { if (tracking_initialized == 1) { distance_from_wall = (int)(3.162 / tan(tilt_angle_rad)); return(distance_from_wall); } } I'm not really sure I declaired everything right, but can someone help me out? I added math.h and included it in the tracking.c(where this code is from). float tilt_angle_rad; tilt_angle_rad = (0.01745) * (((TILT_SERVO - 144) * 25)/50); Distance_Function(tilt_angle_rad); I also have that somewhere else in the code. And I declaired my function aswell. Help? Thanks in advance! |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| C18 v2.4 -- Syntax error where there is no syntax error | Joel J | Programming | 7 | 12-01-2007 17:27 |
| Syntax Error: externs, structs, and macros | Astronouth7303 | Programming | 3 | 16-02-2005 15:39 |
| syntax error using enum{} | gnormhurst | Programming | 8 | 07-02-2005 14:25 |
| MPLink Error | cloudago | Programming | 2 | 01-02-2005 23:00 |
| Routine declaration syntax error (Or: Where's wlado?) | Astronouth7303 | Programming | 15 | 24-03-2004 05:51 |