|
|
|
![]() |
|
|||||||
|
||||||||
|
|
Thread Tools | Rate Thread | Display Modes |
|
#2
|
||||
|
||||
|
Re: 1 Joystick Control
That code assumes that both motors (or sets of motors) move the robot in one direction when they are going forwards. In order to make it work for conventional systems, you need to reverse one of the sides. Simplest way to do that is subtract the value you assign to the PWM outputs from 254:
Code:
p1_x = 255 - p1_y; p1_y = 255 - pwm05; pwm13 = pwm14 = 254 - Limit_Mix(2000 + p1_y + p1_x - 127); // reverse this side pwm15 = pwm16 = Limit_Mix(2000 + p1_y - p1_x + 127); |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Joystick control rotated? | silliewillie | Control System | 6 | 12-02-2005 21:23 |
| We need help with joystick control | Team ICE #1611 | Control System | 4 | 24-01-2005 15:57 |
| Single joystick control problem | Mr. Van | Programming | 7 | 23-11-2004 09:10 |
| One Joystick Control | KWalsh | Programming | 4 | 24-02-2004 17:53 |
| Control System, Joystick mod? | Jordan A. | Technical Discussion | 16 | 13-02-2002 02:29 |