View Single Post
  #2   Spotlight this post!  
Unread 17-02-2013, 09:30
eddie12390's Avatar
eddie12390 eddie12390 is offline
Registered User
AKA: Eddie
FRC #3260 (SHARP)
Team Role: Programmer
 
Join Date: Jan 2011
Rookie Year: 2011
Location: Pittsburgh
Posts: 285
eddie12390 is a glorious beacon of lighteddie12390 is a glorious beacon of lighteddie12390 is a glorious beacon of lighteddie12390 is a glorious beacon of lighteddie12390 is a glorious beacon of light
Re: Programming Drive with a 4 Motor, 2 Wheel Setup

Quote:
Originally Posted by r0306 View Post
We've decided to move double up the power to the back wheels by moving front motors to the back and leaving the front with free-spinning low friction wheels, as shown in the picture below. However, I am unsure as how I should program the drive code as we were using the default drive constructor:

Code:
RobotDrive drive = new RobotDrive(FRONT_LEFT, REAR_LEFT, FRONT_RIGHT, REAR_RIGHT);
Now that the two front motors are relocated, should I reverse the channels so that they turn the same direction like this:

Code:
 RobotDrive drive = new RobotDrive(FRONT_RIGHT, REAR_LEFT, FRONT_RIGHT, REAR_LEFT);
I'm not sure that you need to make any change at all, depending on the build of the gearbox the motors should still spin the same direction that they did previously. If you try to run anything like Mecanum strafing it won't work but the normal drive code (Tank/Arcade) should be just fine.
__________________
Any post that I make expresses only my opinions. I do not represent the opinions of my team or of any entity affiliated with my team.

As a Mentor:
2016 - Engineering Inspiration at Greater Pittsburgh Regional

As a Driver:
2014 - Winner of Greater Pittsburgh Regional
Reply With Quote