Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   NI LabVIEW (http://www.chiefdelphi.com/forums/forumdisplay.php?f=182)
-   -   Driving In a Straight Line Correction (http://www.chiefdelphi.com/forums/showthread.php?t=104781)

androb4 18-03-2012 20:14

Driving In a Straight Line Correction
 
1 Attachment(s)
Hello. I need some help making our robot drive straight. I would like to ask if this would work?

Thanks!

Jay1986 18-03-2012 21:35

Re: Driving In a Straight Line Correction
 
I would like to know why you are running gyro angle times 52 into pid. I would just try running gyro angle straight into pid as process variable. Also I would make sure your pid values are reasonable.

Dusk Star 18-03-2012 21:49

Re: Driving In a Straight Line Correction
 
My team has just run the gyro angle straight into ArcadeDrive in the past, and I believe that is how the old gyro examples did it. Why go through the pain that is pid?

androb4 19-03-2012 11:07

Re: Driving In a Straight Line Correction
 
Quote:

Originally Posted by Jay1986 (Post 1145884)
I would like to know why you are running gyro angle times 52 into pid. I would just try running gyro angle straight into pid as process variable. Also I would make sure your pid values are reasonable.

That way it'll be converted into degrees.

androb4 19-03-2012 11:09

Re: Driving In a Straight Line Correction
 
Quote:

Originally Posted by Dusk Star (Post 1145890)
My team has just run the gyro angle straight into ArcadeDrive in the past, and I believe that is how the old gyro examples did it. Why go through the pain that is pid?

That wouldn't work because the gyro doesn't give out a value of -1 to 1

Dusk Star 19-03-2012 12:42

Re: Driving In a Straight Line Correction
 
Quote:

Originally Posted by androb4 (Post 1146079)
That wouldn't work because the gyro doesn't give out a value of -1 to 1

Right, but the code runs at ~200 Hz, correct? so the change in angle is never really going to be that large. (assuming rate gyro)

If it is an absolute value gyro, then multiplying would not work- dividing by 30 if less than 30, and by the absolute value of the angle if the absolute value was greater than 30 would work.

Good luck, in any case!


All times are GMT -5. The time now is 11:17.

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