Thread
:
Programming motors with joystick buttons
View Single Post
#
2
15-02-2005, 23:01
incognito_NICK
hidden in the corner
AKA: Nick Ferreira
#0179 (Children of the swamp (swampthing))
Team Role: Programmer
Join Date: Nov 2004
Rookie Year: 2002
Location: palm beach gardens
Posts: 15
Re: Programming motors with joystick buttons
you have the right idea about using an if statment.
what you can try is something like this:
Code:
if(p1_sw_trig==1) { pwm01=254; } else if(p1_sw_top==1) { pwm01=0; } else { pwm01=127; }
incognito_NICK
View Public Profile
Visit incognito_NICK's homepage!
Find all posts by incognito_NICK
Find CD-Media Photos by incognito_NICK
Find CD-Media Papers by incognito_NICK