Quote:
Originally Posted by Tom Line
Just so I'm clear - the higher rate gyro is going to drift more, so you're suggesting using the lower rate gyro to correct the higher rate one. Essentially, saying that when the lower rate gyro isn't turning at a rate that's above it's maximum, you would constantly update a correction factor to minimize the high dps gyro's error from zero. Is that right?
|
Yes... you are estimating the bias of the coarse relative to the reference rate which is the fine gyro. During start up, the reference rate is zero for both gyros. Once you are going, use the best gyro to be your reference. The averaging time should be enough to give a large number of samples... I would use an averaging time constant at least 100 times the sample period. This would give a mean estimate that is roughly a factor 10 better than the combined noise error rms.
The pseudo code might look like this:
if(abs(fine)> sat_value) // check for saturation
{rate = coarse + bias;} //use corrected coarse if saturated
else
{
bias = bias + .01*(fine - coarse -bias); // compute the bias with an exponential filter tau = 100*dt
rate = fine;// use fine gyro
}
angle = angle + rate*dt; //Integrate rate
Quote:
|
Regarding the compass: what are the rate sensors used for in the compass? Wouldn't they be knocked off-kilter just as much because of a collision?
|
Typically, accelerometer sensors rather than rates sensors are used to calculate compass tilt which is needed to determine the horizontal component of the earths magnetic field. Horizontal plane rotations from a robot bump will not cause any compass tilt errors of significance. Low, steady state accelerations however can cause tilt errors.
Having done our simple analysis, the compass solution seems more cost effective since only one cheap sensor (
http://www.chiefdelphi.com/forums/sh...d=1#post956268) can be used with no added regulators. Its accuracy is adequate for the field-centric task provided a location can be found on the robot that is free from strong magnetic disturbances. Maybe someone can chime in with some real life FRC testing experience.
But it would be fun to fool with the dual gyro project.