View Single Post
  #7   Spotlight this post!  
Unread 30-01-2009, 16:49
Dave Scheck's Avatar
Dave Scheck Dave Scheck is offline
Registered User
FRC #0111 (WildStang)
Team Role: Engineer
 
Join Date: Feb 2003
Rookie Year: 2002
Location: Arlington Heights, IL
Posts: 574
Dave Scheck has a reputation beyond reputeDave Scheck has a reputation beyond reputeDave Scheck has a reputation beyond reputeDave Scheck has a reputation beyond reputeDave Scheck has a reputation beyond reputeDave Scheck has a reputation beyond reputeDave Scheck has a reputation beyond reputeDave Scheck has a reputation beyond reputeDave Scheck has a reputation beyond reputeDave Scheck has a reputation beyond reputeDave Scheck has a reputation beyond repute
Re: Drive code not working; any suggestions?

Others have posted since I started writing this, but I'll post since I had a few details that the others didn't include.

As has been stated, I'm not sure how there aren't syntax errors.

You have many capitalization errors in your post (maybe it was a poor transcription?). For example, you have pwm when it should be PWM. This brings up the question of why you're using PWM directly and not going through the Victor or Jaguar class?

Your function prototype of update_drive should be giving you an error. You have
Code:
void update_drive;
when it needs to be
Code:
void update_drive(void);
The way you're trying to access class members is incorrect and should be giving you an error. You have
Code:
leftjoy:gety()
when it should be
Code:
leftjoy.GetY()
And what's with this line? The compiler would most definitely complain about that
Code:
int k = /*your value here*/;		//speed increase/decrease value
In summary, the code that you posted should not compile. Double check that you're not getting errors.