Comments (10)
Sounds like your mag is not properly calibrated. If you plot Mx vs Mz gathered while moving the magnetometer in a figure eight, do you get a spherical cloud of points?
from mpu9250.
Magneto XZY data.txt
Hello,
I have attached the magnetometer data in XZY sequence after one time calibration. Can you take a look and tell me what is wrong, I am not able to plot the data in a convenient way.
Thanks and Regards,
Akhil
from mpu9250.
Try excel.
-----Original Message-----
From: Akhil Mohan [mailto:[email protected]]
Sent: February 11, 2016 2:01 AM
To: kriswiner/MPU-9250
Cc: Kris Winer
Subject: Re: [MPU-9250] Yaw Pitch Roll Estimation (#41)
Magneto XZY data.txt
https://github.com/kriswiner/MPU-9250/files/126151/Magneto.XZY.data.txt
Hello,
I have attached the magnetometer data in XZY sequence after one time
calibration. Can you take a look and tell me what is wrong, I am not able to
plot the data in a convenient way.
Thanks and Regards,
Akhil
Reply to this email directly or view it on GitHub
#41 (comment) .
<https://github.com/notifications/beacon/AGY1qlIl4PTIrB5GkXysJltddkx1Ydyoks5
pjFNUgaJpZM4HXnV3.gif>
from mpu9250.
I am not able to interpret the meaning fully, its not centered wrt origin. What is your opinion on the result ?
from mpu9250.
Was this data taken while you were moving the sensor in a figure eight
motion to sample the entire response surface?
If so it shows a very biased magnetometer response. You need to calculate
the offsets and apply them to the subsequent data in order to recenter the
response surface on the origin.
There is no way you are going to get sensible results with this kind of poor
calibration.
See:
https://github.com/kriswiner/MPU-6050/wiki/Simple-and-Effective-Magnetometer
-Calibration
-----Original Message-----
From: Akhil Mohan [mailto:[email protected]]
Sent: February 12, 2016 1:45 AM
To: kriswiner/MPU-9250
Cc: Kris Winer
Subject: Re: [MPU-9250] Yaw Pitch Roll Estimation (#41)
calibrated mag result
<https://cloud.githubusercontent.com/assets/5743851/13003359/33892b3c-d19b-1
1e5-9161-f6a3a35f2523.png>
I am not able to interpret the meaning fully, its not centered wrt origin.
What is your opinion on the result ?
Reply to this email directly or view it on GitHub
#41 (comment) .
<https://github.com/notifications/beacon/AGY1qvPoTtOjOo26xwjs9T4yPtkGqWcOks5
pjaEigaJpZM4HXnV3.gif>
from mpu9250.
Yes, the data is taken while movement as you suggested. I followed the wiki article you suggested and have already implemented. Instead of each time calibrating. I have taken data once and cakculated the hard iron and soft iron biases. The hard irn is then converted to mG and is being constantly subtracted. Thisbis then multiplied by the soft irin scale factor. The plot obtained is after akl this work. So what do you think the mistake that i have done?
from mpu9250.
Sorry lots of typo error,am using phone.
from mpu9250.
I don't know what the problem is. Once you have the biases, you should be
able to subtract them from the subsequent data and get cloud of points
centered at the origin. Sounds like either the scaling or subtraction is
wrong.
-----Original Message-----
From: Akhil Mohan [mailto:[email protected]]
Sent: February 12, 2016 9:16 AM
To: kriswiner/MPU-9250
Cc: Kris Winer
Subject: Re: [MPU-9250] Yaw Pitch Roll Estimation (#41)
Sorry lots of typo error,am using phone.
Reply to this email directly or view it on GitHub
#41 (comment) .
<https://github.com/notifications/beacon/AGY1qtpNzk30DIkbJ6Ox8q3aKXhA_G13ks5
pjgrBgaJpZM4HXnV3.gif>
from mpu9250.
I have recorded the data once moving in some possible combinations covering the 3D space and then obtained the biases. Each time when a magneto read a data, the biases are removed (one time calibration). But still my estimation of YPR is not correct. The sequence right now to the filter is,
Filter (ax,ay,az,gx,gy,gx,my,mx,mz) where gyro are in rad/s. I feel it should be my,-mx and mz but that also is not giving me a good result. The quat is converted to rotation matrix and then used to determine Y, P and R. I am not sure what mistake I am making now.
from mpu9250.
Hi Akhil,
It looks like you have the mag more or less properly calibrated.
You can read about the use of the North-East-Down convention here:
https://github.com/kriswiner/EM7180_SENtral_sensor_hub/wiki/C.-Managing-the-
Configuration-File
which could help you choose the proper order to pass the sensor data to the
Madgwick algorithm.
Additionally, this is how I go from quaternions to YPR:
Heading = atan2[(Qx2 - Qy2 - Qz2 + Qw2), 2(QxQy + QzQw)]
Pitch = asin[-2(QxQz - QyQw)]
Roll = atan2[(-Qx2 - Qy2 + Qz2 + Qw2), 2*(QxQw + QyQz)]
Even with everything correct you shouldn't expect heading accuracy much
better than four or five degrees with this simple algorithm.
Kris
-----Original Message-----
From: Akhil Mohan [mailto:[email protected]]
Sent: February 17, 2016 12:38 AM
To: kriswiner/MPU-9250
Cc: Kris Winer
Subject: Re: [MPU-9250] Yaw Pitch Roll Estimation (#41)
I have recorded the data once moving in some possible combinations covering
the 3D space and then obtained the biases. Each time when a magneto read a
data, the biases are removed (one time calibration). But still my estimation
of YPR is not correct. The sequence right now to the filter is,
Filter (ax,ay,az,gx,gy,gx,my,mx,mz) where gyro are in rad/s. I feel it
should be my,-mx and mz but that also is not giving me a good result. The
quat is converted to rotation matrix and then used to determine Y, P and R.
I am not sure what mistake I am making now.
magneto_calib_1
<https://cloud.githubusercontent.com/assets/5743851/13103917/e2423f32-d57f-1
1e5-8823-01a281460834.png>
magneto_calib_2
<https://cloud.githubusercontent.com/assets/5743851/13103918/e24615d0-d57f-1
1e5-8648-1a759ae56195.png>
magneto_calib_3
<https://cloud.githubusercontent.com/assets/5743851/13103919/e26e8380-d57f-1
1e5-8f84-4067e7201c50.png>
Reply to this email directly or view it on GitHub
#41 (comment) .
<https://github.com/notifications/beacon/AGY1qoQgRT-zdlJ5cwyLNIDqLuV2p5ndks5
plCkCgaJpZM4HXnV3.gif>
from mpu9250.
Related Issues (20)
- 5 different MPU9250 and not a single one 100% working (broken axis) HOT 5
- Pitch range only from -90 to 90 HOT 1
- How to increase data read rate?
- Reading ACCEL and Gyro Registers are wrong? HOT 6
- MPU9250 custom board didn‘t work HOT 4
- Alternative to MPU9250 and BNO055 HOT 9
- How can I get Ak8963 Address from MPU9250 HOT 1
- MPU9250 magnetometer not accessible by any read HOT 4
- The Magnetometer adress doesn't show up at MPU9250 with RPI3 HOT 3
- Azimuth HOT 10
- Computing Beta and Zeta Values HOT 9
- 9250 Who am I 0x75 ? HOT 5
- Sanity Check of mpu9250-derived values? Am I in the right units? HOT 19
- MPU9250 interrupt pin not working HOT 7
- Yaw values are not precise HOT 9
- Can such sensor be used for indoors inertial navigation ? HOT 1
- Calibration - figure of eight HOT 2
- Reset FIFO and DMP HOT 5
- Sensitivity Adjustment HOT 3
- Limitations/Considerations when 3D-tracking a fast rotating object for 1 second HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mpu9250.