![]() |
Reversing the joystick axis
Sorry if I didn't search well enough, but how does one go about reversing the joystick value? I tried a negative, but I realized the pwm value is an unsigned val, what is the math I need to do on the joystick value to make it so foreward is backward and backward is foreward?
|
Re: Reversing the joystick axis
Code:
#DEFINE PWM_MAX 254 |
Re: Reversing the joystick axis
Quote:
Code:
pwm01=p1_x;Code:
pwm01=255-p1_x; |
Re: Reversing the joystick axis
Quote:
Yeah, this worked for us |
| All times are GMT -5. The time now is 10:04. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi