Gyro speed and the code

I’m currently using Kevin Watson’s gyro code and I’ve noticed when our robot turns a bit too quickly the gyro will fall behind leaving us with an incorrect angle. Now, I know this years gyro has a lot less resolution than the ones from last year but is there any way I could figure out a way for the gyro to keep up through code? I know it would be a bit complicated but I thought I’d ask before either ordering a brand new gyro or finding the gyro from last year. Any help would be appreciated, thanks.

The old gyro supports 80 degrees per second of rotation and the new one can handle 150 degrees of rotation. Do you know about how fast you are rotation?

Edit: Opps, other way around. I read to quickly and mixed them up.

I had heard somewhere that the new one had a lower resolution, but anyways, so you’re saying the new one has a resolution of 150 degrees/sec? If you are, we are definitely not going anywhere near that close, it could be the way that i have it mounted, but when I do a printf() of the rate I get between -39 and 39 when turning. I’ll try mounting it at a different spot on the robot to test it out.

The gyro saturation is 150 deg/s. If your robot turns faster than that, the gyro won’t be able to keep up. There isn’t really a way around this, other than buying a faster gyro. AD has a 300 deg/s model.

Alright, thanks everyone! I’ll try mounting it in a different spot on the robot and see if we get different results.

I’m not sure what this talk about old gyro vs. new gyro is, but if you are using this year’s kit gyro, then you are using a 80 deg/sec gyro.

Okay, that’s what I though :S. I’m getting confused, so does anyone know the saturation of the new gyro’s this year compared to the last years?

EDIT: Alright, I’ve read through the rules and this years gyro has a dynamic range of +/- 80 deg/sec whereas last years gyro had a dynamic range of +/- 150 deg/sec. Therefore, I think I’m going to find last year’s gyro and hook that up :smiley:

[quote=2008 Sensor Manual;]The actual Yaw Rate Gyro chip that was used in 2007 was the ADXRS150. The
AD22304 has a guaranteed dynamic range of +/- 80 degrees per second vs. the +/- 150
degrees per second for the ADXRS150. Most other specifications are identical.

This year the gyro is accurate at rates under 80 degrees per second.

Last years gyro was accurate at rates under 150 degrees per second.

Please read the documentation before answering questions.

While turning, you can monitor the rate output and make sure you don’t go over 1396 milliradians per second (i.e., 80 degrees per second). You could even craft a software control loop that would ensure you didn’t exceed that rate while turning.


If it’s turn rate limited, it won’t matter where on your bot you are mounting it.