Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Tank Drive Troubles (http://www.chiefdelphi.com/forums/showthread.php?t=93249)

Nicandy 05-03-2011 15:38

Tank Drive Troubles
 
1 Attachment(s)
Okay, so We have the arm motors programmed pretty as you please, we are using a tank drive to control the two drive motors, as well as the two arm motors that we have. The arm motors do exactly what they are supposed to do. as well as our drive motors, but we are having issues with programming the drive motors to turn or re-invert themselves to turn. is there anyone out there who can give us some insight? we are completely stuck and out of ideas on this. There is also a photo that might help you guys. thanks very much from the Marinerds.

nighterfighter 05-03-2011 19:10

Re: Tank Drive Troubles
 
I don't know labview at all, but do you need to invert one of the joystick axis?

Remember that full forward is -1.

Vikesrock 05-03-2011 19:20

Re: Tank Drive Troubles
 
Easy way to test for proper operation of a Tank drive.

1.Put the robot up on blocks so the wheels are off the ground and not touching anything.
2. Push whichever joystick corresponds to the left side forward. Check if the left side drive wheels move forward.
2a. If they don't go to Begin.VI and wire a true constatnt into the Invert Left terminal of the Open X Motor drive.
3. Push the right joystick forward. Check if the right side drive wheels move forward.
3a. If they don't go to Begin.VI and wire a true into the Invert Right terminal of the Open X Motor drive.
4. Save and rerun, or rebuild and set as startup
5. Verify both sides now move in the proper direction.

Nicandy 06-03-2011 11:00

Re: Tank Drive Troubles
 
Quote:

Originally Posted by Vikesrock (Post 1035103)
Easy way to test for proper operation of a Tank drive.

1.Put the robot up on blocks so the wheels are off the ground and not touching anything.
2. Push whichever joystick corresponds to the left side forward. Check if the left side drive wheels move forward.
2a. If they don't go to Begin.VI and wire a true constatnt into the Invert Left terminal of the Open X Motor drive.
3. Push the right joystick forward. Check if the right side drive wheels move forward.
3a. If they don't go to Begin.VI and wire a true into the Invert Right terminal of the Open X Motor drive.
4. Save and rerun, or rebuild and set as startup
5. Verify both sides now move in the proper direction.

We want one joystick to control forward and backward, as well as turning left and turning right, while the other joystick will control the arms elevation.
and our problem is that we can't figure out how to program the first joystick to do all four things. we can only get it to do either forward and backward, or left and right.

Ether 06-03-2011 11:05

Re: Tank Drive Troubles
 
2 Attachment(s)
Quote:

Originally Posted by Nicandy (Post 1035385)
We want one joystick to control forward and backward, as well as turning left and turning right...

and our problem is that we can't figure out how to program the first joystick to do all four things. we can only get it to do either forward and backward, or left and right.

Here's your problem: What you are describing is called Arcade Drive, not Tank Drive.

Your FRC LabVIEW installation supports Arcade Drive.

See attached screenshots of the Functions Palette and the Help.



Nicandy 06-03-2011 13:48

Re: Tank Drive Troubles
 
well then can i use two arcade drives? or one tank and one arcade drive?
because i need the one joystick to be able to control the arm, and one to control the driving.

Ether 06-03-2011 14:07

Re: Tank Drive Troubles
 
Quote:

Originally Posted by Nicandy (Post 1035491)
well then can i use two arcade drives? or one tank and one arcade drive?

You could, but that's not the way it was intended to be used.

Quote:

because i need the one joystick to be able to control the arm, and one to control the driving.
Use the Arcade Drive VI to control the driving.

Don't use Arcade or Tank Vis to control non-drivetrain motors. See this post.



EthanMiller 06-03-2011 14:33

Re: Tank Drive Troubles
 
The arcade drive VI takes one joystick input, IIRC. Maybe an X and a Y input. Either way, they come from the same joystick.

Ether 06-03-2011 15:20

Re: Tank Drive Troubles
 
Quote:

Originally Posted by EthanMiller (Post 1035530)
The arcade drive VI takes one joystick input, IIRC.

Arcade Drive takes 2 joystick inputs.

Quote:

Maybe an X and a Y input. Either way, they come from the same joystick.
That's the way it's usually done, but it's not required. The 2 inputs could come from 2 different joysticks.




Nicandy 07-03-2011 13:28

Re: Tank Drive Troubles
 
Ether, thank you so much, you really helped answer a lot of questions.
:)

Ether 07-03-2011 16:23

Re: Tank Drive Troubles
 
Quote:

Originally Posted by Nicandy (Post 1035955)
Ether, thank you so much, you really helped answer a lot of questions.
:)

You are welcome.




All times are GMT -5. The time now is 03:44.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi