If you need assistance, please send an email to forum at 4hv dot org. To ensure your email is not marked as spam, please include the phrase "4hv help" in the subject line. You can also find assistance via IRC, at irc.shadowworld.net, room #hvcomm.
Support 4hv.org!
Donate:
4hv.org is hosted on a dedicated server. Unfortunately, this server costs and we rely on the help of site members to keep 4hv.org running. Please consider donating. We will place your name on the thanks list and you'll be helping to keep 4hv.org alive and free for everyone. Members whose names appear in red bold have donated recently. Green bold denotes those who have recently donated to keep the server carbon neutral.
Special Thanks To:
Aaron Holmes
Aaron Wheeler
Adam Horden
Alan Scrimgeour
Andre
Andrew Haynes
Anonymous000
asabase
Austin Weil
barney
Barry
Bert Hickman
Bill Kukowski
Blitzorn
Brandon Paradelas
Bruce Bowling
BubeeMike
Byong Park
Cesiumsponge
Chris F.
Chris Hooper
Corey Worthington
Derek Woodroffe
Dalus
Dan Strother
Daniel Davis
Daniel Uhrenholt
datasheetarchive
Dave Billington
Dave Marshall
David F.
Dennis Rogers
drelectrix
Dr. John Gudenas
Dr. Spark
E.TexasTesla
eastvoltresearch
Eirik Taylor
Erik Dyakov
Erlend^SE
Finn Hammer
Firebug24k
GalliumMan
Gary Peterson
George Slade
GhostNull
Gordon Mcknight
Graham Armitage
Grant
GreySoul
Henry H
IamSmooth
In memory of Leo Powning
Jacob Cash
James Howells
James Pawson
Jeff Greenfield
Jeff Thomas
Jesse Frost
Jim Mitchell
jlr134
Joe Mastroianni
John Forcina
John Oberg
John Willcutt
Jon Newcomb
klugesmith
Leslie Wright
Lutz Hoffman
Mads Barnkob
Martin King
Mats Karlsson
Matt Gibson
Matthew Guidry
mbd
Michael D'Angelo
Mikkel
mileswaldron
mister_rf
Neil Foster
Nick de Smith
Nick Soroka
nicklenorp
Nik
Norman Stanley
Patrick Coleman
Paul Brodie
Paul Jordan
Paul Montgomery
Ped
Peter Krogen
Peter Terren
PhilGood
Richard Feldman
Robert Bush
Royce Bailey
Scott Fusare
Scott Newman
smiffy
Stella
Steven Busic
Steve Conner
Steve Jones
Steve Ward
Sulaiman
Thomas Coyle
Thomas A. Wallace
Thomas W
Timo
Torch
Ulf Jonsson
vasil
Vaxian
vladi mazzilli
wastehl
Weston
William Kim
William N.
William Stehl
Wesley Venis
The aforementioned have contributed financially to the continuing triumph of 4hv.org. They are deserving of my most heartfelt thanks.
Registered Member #2431
Joined: Tue Oct 13 2009, 09:47PM
Location: Chico, CA. USA
Posts: 5639
Please ive researched this first in other places and i have some physics knowledge and formal education, but some of these questions i have, are a real punch to my brain.
Question: how is a magnetometer (3 axis) used to minimise/mitagate the drift rate of a gyro ( 3 axis too) of course i have a 3 axis accelerometer too...
is the magnetometer used to re-origin the gyro every so often to prevent cumulative errors due to the drift rate? If so, how is this done?
the rate of drift is measured in degree second per second (d/s/s) right?
Registered Member #30
Joined: Fri Feb 03 2006, 10:52AM
Location: Glasgow, Scotland
Posts: 6706
The way I understand it, a gyro measures angular acceleration, and an inertial navigation system integrates twice to get the angular position. The double integration is very susceptible to drift. (An old-fashioned gyrocompass essentially did the double integration mechanically in the gyro itself, but the same drift issues apply.)
In the yaw axis, the angular position is the same thing as a compass bearing. A magnetometer is a compass, so it also gives a compass bearing that can be used to cross-check the one from the gyro. If they disagree, the integrators in the gyro can be reset to make them agree.
I don't know how this works in the other two axes, since the Earth's magnetic field isn't normally used for navigation in those axes. That's where the 3 axis accelerometer helps, it can sense the Earth's gravitational field and tell you which way is down. That can be used to reset the pitch and roll integrators.
You can think of the gyro and accelerometer working together to give you 6 axes of acceleration data: 3 translational and 3 rotational. This data can then be used for both stability control and navigation.
Registered Member #2431
Joined: Tue Oct 13 2009, 09:47PM
Location: Chico, CA. USA
Posts: 5639
Steve Conner wrote ...
A magnetometer is a compass, so it also gives a compass bearing that can be used to cross-check the one from the gyro. If they disagree, the integrators in the gyro can be reset to make them agree.
ok im going to investigate this further with C code, any other oppinons and explanations are still appreciated...
Registered Member #2431
Joined: Tue Oct 13 2009, 09:47PM
Location: Chico, CA. USA
Posts: 5639
ok, im going to consider strobing the gyro back to a zero rate value since my machine wont be continuosly in rotation in any single axis, therefore the magnometer can be used to reset the error out of the gyro on a timed baisis... I think.
Registered Member #2431
Joined: Tue Oct 13 2009, 09:47PM
Location: Chico, CA. USA
Posts: 5639
You guys save me once again, i wasnt even going to look at the kalman types until i had the pid + imu partially complete.
that source was exactly what i needed!!! i should probably startposting on the diydrones forum too. though 4hv is my favorite and i feel like im cheating on a girlfriend>>
Registered Member #65
Joined: Thu Feb 09 2006, 06:43AM
Location:
Posts: 1155
@Patrick Make sure to audit an advanced linear algebra, and inverse kinematics course if these programs are not part of your curriculum. These are key to solving numerous problems, and will clearly explain how PID is related to Kalman filters.
Remember that the filter has an initial "learning" moment when state is first initiated, and actuators should be "inhibited" during this brief time (do not constantly "reset" your gyro, as "angular rate" data does not work that way). Additionally, you will need to "tune" the filters to match the moment-of-inertia for your craft.
Tip: separate your navigational and guidance sub-systems, and things will get a little easier.
Registered Member #2431
Joined: Tue Oct 13 2009, 09:47PM
Location: Chico, CA. USA
Posts: 5639
Carbon_Rod wrote ...
@Patrick Make sure to audit an advanced linear algebra, and inverse kinematics course if these programs are not part of your curriculum. These are key to solving numerous problems, and will clearly explain how PID is related to Kalman filters.
I was afraid someone would say this!
Carbon_Rod wrote ...
Remember that the filter has an initial "learning" moment when state is first initiated, and actuators should be "inhibited" during this brief time (do not constantly "reset" your gyro, as "angular rate" data does not work that way). Additionally, you will need to "tune" the filters to match the moment-of-inertia for your craft.
Yes im following the advice from a expert in PIDs at the moment...and i wont strobe the gyro as i previously conjuectured.
Carbon_Rod wrote ...
Tip: separate your navigational and guidance sub-systems, and things will get a little easier.
Yes, i had already made this realization...
Ok so my question remains: how do i prevent the gyros from accummulating the drift error? Obviously it can be done, my tilt-rotor from KKmulticopter does it...
tilt-rotor (twin-rotor) single board, uses only a 3 DOF gyro, no accelerometers no mags.
EDIT:
Source: This article may explain things well, not sure yet.
Im making two assumptions: first: rotational saturation is not a problem with solid state gyros. second: the gyro drift isnt linear over dozens of seconds, (becuase i cant be that lucky)
Thought: when dealing with angular rates, absolute/instantaneous values are not stable. And therefore only fast changing rates are of value. steep slopes on the graph are useful, shallow slopes are closer to drift...
Registered Member #65
Joined: Thu Feb 09 2006, 06:43AM
Location:
Posts: 1155
As Steve stated... there are many links for 9DOF IMU Kalman filters:
I would wager one of your chips is not part of the gyro, and is an accelerometer for a 5 or 6 DOF unit... Who knows, it may indeed be polling multiple gyros like a sync joke or something...
Essentially the predicted-error increases as the gyro drifts.
This site is powered by e107, which is released under the GNU GPL License. All work on this site, except where otherwise noted, is licensed under a Creative Commons Attribution-ShareAlike 2.5 License. By submitting any information to this site, you agree that anything submitted will be so licensed. Please read our Disclaimer and Policies page for information on your rights and responsibilities regarding this site.