Hallo, since 2 days I have a problem with my Magnetometer HMC5843 I have tested it with the testcode for the compass.
The initalistation faild:
It fails on this codeline (AP_Compass_HMC5843.cpp)
if( abs(mag_x) > 500 && abs(mag_x) < 2000 && abs(mag_y) > 500 && abs(mag_y) < 2000 && abs(mag_z) > 500 && abs(mag_z) < 2000)
{
the condition is not true.
abs(mag_x) and y and z only print the values 37 alle 3 Parts????
What could I do? Is it dead?
If yes can I use this one and also connect it with a level converter from 5 to 3.3 V??
http://www.watterott.com/de/Triple-Axis-Magnetometer-Breakout-HMC5883L
thx
druckgott
Replies
Hallo,
today I have uploaded and uploaded again the firmware version 2.0.39, because I can´t beleave the compass is dead.
Normaly I will do the normal Setup prozess in the ARM Planer.
But now I have changed the Progress and have not aktivated the compass on the beginning of the setup progress.
I have finished the setup without compass, make a test flight and all works perfekt.
Then I go into the setup and aktivated the compass and put into the declination. After this the compass works perfekt.
I have a sparkfun Compass HMC5843.
Could this be a bug, because If I aktivate the compass in the normal setup routine, the compass do not work look this post:
http://diydrones.ning.com/forum/topics/mag-sparfun-autodetection-do...
thx
druckgott
Ok now I have tested a older example version (2.0.29)
There is no error, but the values are very bad. Sometimes eavry 20 value is right. the rest is wrong, what can cause this?
(see attached file)
I hope anybody can help me because I don´t know what I can do
Neues Textdokument.txt