kriswiner / MPU6050

Basic MPU6050 Arduino sketch of sensor function

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Magnetometer raw data issue

proba238 opened this issue · comments

Hello, in first place I want to thank you for the amazing work about MPU9250. Even though I’m a student I have very little practical knowledge about sensor fusion (new to the topic), so having a guide like yours means a lot, a ton!

And now about the problem, ill tri to be as simple as possible. So I hooked up my MPU9250, setu up the communication and so on… I can easly access the raw data registers from AK8963. The problem is the measurement. In your article “Simple and Effective Magnetometer Calibration” ,the first picture shows raw data from AKA8963, The blue marks indicates the change in magnetic field along the xy plane.

I rotated the module for 360 degrees in the xy plane and my measurements of the magnetic field along the plane, with the z pointing to ground shows this:

proba

(The transition from nord to east is shown by the red rhomb)

Could you give me an opinion about what the problem might be, and how to fix it?

Hello, and thank you for the quick response!

Well the problem is that I cant use the given magnetic field measurement in the xy to get any reasonable data outcome. If the data would be distributed in a say…circle form as it is the case in :

https://cloud.githubusercontent.com/assets/6698410/8768651/04fe05be-2e3d-11e5-9f70-b6897fdca9ca.jpg

Then I could use a function as tan or tan2 to get the approximate heading where the field is pointing. Of course I tried to calibrate the sensor as explained in your work but, still. I mean, calibrating just shift the measurement so that the long term run, mean is always at 0,0.
It seems to me that I should use some form of whited function to calibrate the sensor, a PID or something, in order to scale the measurement to the proper level.

All right, ill keep trying till I get them right. Thanks for the effort! 👍

@proba238
Any progress?

I have the same problem. I get data from CC2650 to my android phone using formula at http://processors.wiki.ti.com/index.php/CC2650_SensorTag_User%27s_Guide#Movement_Sensor

My decode function:

Scatter chart:

@kriswiner I waved my sensor in figure 8 motion but result was not expected. Could you help me ?
@proba238 did you resolve this problem ?

@kriswiner I tried again in all 3D directions. Here is result

Thank you so much! What can I do to get circular clouds of points like you ?