View Single Post
  #3   Spotlight this post!  
Unread 17-02-2006, 01:57
Mike AA's Avatar
Mike AA Mike AA is offline
Programmer and Mentor
AKA: Mike Aalderink
FRC #3458 (Code Blue)
Team Role: Programmer
 
Join Date: Jan 2003
Rookie Year: 1999
Location: Holland, Mi
Posts: 698
Mike AA is a splendid one to beholdMike AA is a splendid one to beholdMike AA is a splendid one to beholdMike AA is a splendid one to beholdMike AA is a splendid one to beholdMike AA is a splendid one to beholdMike AA is a splendid one to beholdMike AA is a splendid one to behold
Send a message via MSN to Mike AA
Re: Victors Controlled By Joystick Buttons

You can also, using Joel's code, change the 254 to something else smaller to change the speed of the item you are looking to control. Just keep in mind 127 is center less than is one direction, more than is the other direction.

ie

Quote:
pwm05 == the pwm channel the victor is connected to
p1_sw_trig == joystick button that activates victor

if (p1_sw_trig)
{
pwm05 = 75;
}
else
{
pwm05 = 127;
}
-Mike