Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   NI LabVIEW (http://www.chiefdelphi.com/forums/forumdisplay.php?f=182)
-   -   Gyro Drive Straight (http://www.chiefdelphi.com/forums/showthread.php?t=133575)

roberthashley 27-01-2015 17:20

Gyro Drive Straight
 
How to you use a gyro to keep your bot driving straight. We are using LabView.

Alan Anderson 28-01-2015 00:21

Re: Gyro Drive Straight
 
If you know what direction you want the robot to face, and you know what direction it is currently facing, you can use the difference between them to control the "turn" input of either a Mecanum or Arcade drive function.

If you scale the values properly, that will tend to rotate the robot toward the desired direction. That's a simple Proportional control system, which is what the "P" in "PID" stands for. If you find that you can't get the robot to hold its direction strongly enough without overshooting and oscillating, then you need to implement a more complete PID control with some Integral to account for the steady-state error, and perhaps some Derivative to reduce overshoot when the error starts out too high.

roberthashley 28-01-2015 11:11

Re: Gyro Drive Straight
 
Can you post a screenshot of that please im a visual learner.

Skyehawk 28-01-2015 12:35

Re: Gyro Drive Straight
 
I will be able to post some screenshots of the general principal of how this works later today, sometime around 4:00 CST (maybe sooner).

Ether 28-01-2015 13:43

Re: Gyro Drive Straight
 
Quote:

Originally Posted by roberthashley (Post 1435157)
Can you post a screenshot of that please im a visual learner.

What kind of drivetrain do you have, and what software are you using to control it?

If you have a mecanum drive and are using mecanum_Cartesion, here's a picture showing an approach you could use to drive straight at any desired orientation angle.



roberthashley 28-01-2015 15:21

Re: Gyro Drive Straight
 
We are using Tank Drive.

Ether 28-01-2015 16:42

Re: Gyro Drive Straight
 
Quote:

Originally Posted by roberthashley (Post 1435263)
We are using Tank Drive.

Please be more specific.

"Tank Drive" means different things to different people in different contexts.

[1]What kind of drivetrain do you have1, and

[2]what software2 are you using to control it?


1details please: number and type of wheels, number of gearboxes and gear ratio, chains/belts/direct, etc etc. The more detail, the better.

2e.g. what vi are you using, and how is your driver interface (joystick) mapped to that vi's inputs e.g. arcade, tank, other?




roberthashley 28-01-2015 16:55

Re: Gyro Drive Straight
 
1 Attachment(s)
six wheel
two mini cims preside
belt
two shifting gearboxes
i don't know the gear ratio
Xbox Controller

Dose that help

Ether 28-01-2015 17:36

Re: Gyro Drive Straight
 
Quote:

Originally Posted by roberthashley (Post 1435304)
six wheel
two mini cims preside
belt
two shifting gearboxes
i don't know the gear ratio
Xbox Controller

Dose that help

Somewhat.

What does "two mini cims preside" mean?

Also can you get answers for the questions highlighted in red below:

Quote:

Originally Posted by Ether (Post 1435297)
[1]What kind of drivetrain do you have1, and

[2]what software2 are you using to control it?


1details please: number and type of wheels, number of gearboxes and gear ratio, chains/belts/direct, etc etc. The more detail, the better.

2e.g. what vi are you using, and how is your driver interface (joystick) mapped to that vi's inputs e.g. arcade, tank, other?





Alan Anderson 28-01-2015 17:47

Re: Gyro Drive Straight
 
Driving a six-wheel skid-steer drivebase using Tank Drive (left and right joysticks) is not easy if the robot doesn't want to go straight, even with computer control based on a gyro sensor. It is very easy to make it go straight using Tank Drive if the robot is properly constructed.

But if you really want to try to compensate for a difficult-to-control robot, the idea is simple. Compute the difference between desired and measured heading, scale it to something that will yield a value between -1 and 1, then add it to the joystick input for one side and subtract it from the joystick input for the other side.

roberthashley 28-01-2015 18:14

Re: Gyro Drive Straight
 
two cims on each side.


All times are GMT -5. The time now is 08:52.

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