Quote:
|
Originally Posted by Guy_E
Hi,
I started to learn how to use the gyro. I downloaded Kevin's code from the internet and tried to use it. There are some things which I haven't understood completely.
I tried to print the variable "gyro_rate", but its values were between 1800-2200.
Shouldn't it be much lower? Shouldn't this variable be measuring the angular velocity in (radians/seconds)? I don't know if there is something wrong with the code, or something wrong with my understanding. I then tried to print the value from the function Get_Gyro_Angle(), but again, the printed values were unreasonable. The value jumped from positive to negative numbers without any logical order.
I would be very glad if someone could guide me through it.
Thanks,
Guy
|
I haven't used the gyro code in a little over a year, but if I remember right the angular unit used in Kevin Watson's gyro code is milliradians, not radians. You should also be able to change it to tenths of a degree in the gyro.h file. That would at least explain the large numbers you were getting.
Sorry I don't know the complete answer to your question, but it's a start.