View Single Post
  #3   Spotlight this post!  
Unread 21-01-2016, 10:57
BenD BenD is offline
Registered User
FRC #4828 (Swift Creek RoboEagles)
Team Role: Programmer
 
Join Date: Jan 2016
Rookie Year: 2013
Location: North Carolina
Posts: 2
BenD is an unknown quantity at this point
Re: Two Talons for Two Sets of Wheels

After defining your Talons and Joystick objects in your Robot class, create a RobotDrive object like so:
Code:
RobotDrive drive = new RobotDrive(leftTalon, rightTalon);
Then simply call the tank drive function on your RobotDrive object:
Code:
drive.tankDrive(leftJoystick, rightJoystick);
Reply With Quote