|
|
|
![]() |
|
|||||||
|
||||||||
|
|
Thread Tools | Rate Thread | Display Modes |
|
#2
|
||||
|
||||
|
Re: 4 Motor Drive
Start with the given Simple Robot Template and add the import "edu.wpi.first.wpilibj.*"
Then add Code:
RobotDrive drive = new RobotDrive(1,2,3,4);
Joystick leftStick = new Joystick(1);
Joystick rightStick = new Joystick(2);
Then add Code:
drive.tankDrive(leftStick,rightStick); This will give you a tank drive system for a four motor robot with front left motor in port 1, back left in port 2, front right in port 3, and rear right in port 4 using the left joystick in port 1 and the right joystick in port 2. Best of luck ![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Single Motor Drive | Team2339 | NI LabVIEW | 1 | 04-02-2009 23:43 |
| Tracking Servo motor with drive motor in Labview | mbone206 | Technical Discussion | 5 | 28-01-2009 17:32 |
| Motor drive function? | Mike | Programming | 3 | 15-02-2006 11:55 |
| Screw drive motor | top dog | Motors | 7 | 01-02-2005 09:43 |
| 8 Drive Motor Robot | Dan Izzo | Motors | 9 | 28-04-2002 23:08 |