6 votes
Accepted

Why would a drone need a magnetometer? Are an accelerometer and a gyroscope not sufficient?

The main difference between accelerometer and gyroscope vs magnetometer is that first two give only relative information - you may calculate heading relative to your starting position, but you won't ...
  • 963
5 votes
Accepted

Kalman Filter GPS + IMU

This is a complete re-working of the answer I had originally provided. If you're curious, you can check the edit history and see what was posted earlier. In comments to this question, OP stated that ...
  • 15.1k
4 votes
Accepted

Practicality of using magnetometer inside AUV

Mags are used in almost all UAVs. It will be useful and it will be a unique source of information. Adding a some shielding between the mag and your computers and power lines will greatly reduced the ...
  • 1,823
4 votes
Accepted

Noisy magnetometer data

First, let's look at if your findings seem reasonable given the datasheet specifications for the sensor. For this, I'll assume that Wikipedia is generally correct and that the strength of Earth's ...
  • 15.1k
4 votes
Accepted

Weird magnetometer values

Apparently a magnetometer is useless in indoor environments like man made buildings. I cite from this paper Multi-Magnetometer Based Perturbation Mitigation for Indoor Orientation Estimation ...
  • 681
3 votes

Why would a drone need a magnetometer? Are an accelerometer and a gyroscope not sufficient?

A magnometer lets the drone control its geographical heading. It's really the accelerometer that tells direction (not the gyroscope) and, in this case, the direction is down-wards. This provides ...
  • 217
3 votes

Is there a way to measure 3 axis orientation without a magnetometer?

Calibration procedures for magnetometers exist, to compensate for soft iron (nearby ferromagnetic objects) and hard iron (nearby magnetic fields) offsets, which skew the measurements. However, these ...
  • 530
2 votes

FreeIMU External Magnetometer

OK so I managed to solve this by doing a couple of things. Connect external magnetometer to the same I2C bus as the FreeIMU. The FreeIMU is 5V and the external magnetometer is 3.3V so I had to use a ...
2 votes

Adding magnetic field vector to a Kalman filter

I doubt you need to add anything to the state vector regarding the magnetometer calibration. The magnetometer measurement should just be treated at another signal that triggers a measurement/...
  • 1,823
2 votes
Accepted

3D Magnetometer calibration algorithm

We always need a reference for calibration to which we calibrate our sensor. For example in case of 3D accelerometer we use gravity as a reference which is assumed vertically downwards at a place. ...
  • 633
2 votes

How to create a Complementary Filter for a linearly accelerating body to obtain estimate of orientation in quaternion?

The point of a complementary filter is combine the low-pass parts of some measurements (e.g. accelerometer) with the high-pass parts of other measurements (e.g. gyro). If the accelerometer perfectly ...
  • 2,709
1 vote

Tilt-compensated compass - at my wits' end

You may want to take a look at FreeIMU library that does 'data fusion' that combine raw data from multiple sensors and present user with a much reliable, stable and easy-to-use data in a roll, pitch ...
  • 419
1 vote

Do electromagnets affect magnetometer calibration?

Without knowing the specifics of the sensitivity of your magnetometer and electromagnet, it is impossible to give a concrete yes or no answer. With that, in general any source of magnetic field is ...
  • 261
1 vote

Orientation from magnetometer data

Usually the magnetometer is used to find the yaw. It acts as a digital compass in this case. To calculate roll and pitch you need an accelerometer. But there are some techniques that can be used to ...
1 vote

Practicality of using magnetometer inside AUV

As mentioned in the previous answer, many small, low-cost underwater (and aerial) vehicles use a magnetic compass. You need a good procedure for both hard-iron and soft-iron calibration of your ...
  • 106
1 vote

Gyro yaw drift compensation

Your best would be using the Madgwick filter, as its already implemented in several languages and programs. Yaw, pitch or roll can then be easily called from the filter. Follow the link to a ...
1 vote
Accepted

How to transform raw accelerometer data into the Earth fixed frame to determine position

There are several questions here, so I'll try to address them all. First, using the integrated gyro output. Integrating the gyro output, which provides angular velocity, gives you an orientation ...
  • 15.1k
1 vote

How to add a magnetometer in an Extended Kalman filter for innovation update?

A magnetometer measures the local magnetic field. When assuming that the Earth is the only magnetic source, then this magnetic field should be constant in world coordinates. But the magnetometer ...
  • 941
1 vote

Kalman Filter GPS + IMU

id recommend estimating position, velocity, and bias in the yaw reading from the imu. You'd assume the yaw bias is a first order system driven by zero mean Gaussian noise. You can also estimate biases ...
  • 1,823
1 vote

What are the specifications of the digital compass used in iPhone 6S

Typically, and unsurprisingly, proprietary information (to include part numbers, schematics, etc.) is closely guarded by companies. As such, I am not sure how much information you can expect to ...
  • 926
1 vote

Quadcopter heading calculation

A GPS unit doesn't give you heading, although it is possible to estimate the heading based on successive GPS readings. Unless you're looking to set and forget the heading, which you shouldn't be doing ...
  • 15.1k
1 vote

Quadcopter heading calculation

The habitual way to do this is to have an attitude and position loop for the quadrotor, as in next picture. Attitude loop manages the quadrotor to achieve the desired angles (pitch, yaw, and roll). ...
  • 460
1 vote

Why would a drone need a magnetometer? Are an accelerometer and a gyroscope not sufficient?

As other people have said, in a steady-state condition, a gyroscope+accelerometer sensor suite can successfully estimate the roll and pitch values of the UAV, but not its yaw angle. However, there ...
  • 530
1 vote
Accepted

3-axis Magnetometer Question

I don't think it would make a difference what the orientation is. I would recommend maybe using hall effect sensors instead of a 3 axis magnetometer if ALL else fails. That would be a last resort ...
1 vote

Weird magnetometer values

Everything looks fine to me. Imagine if you kept driving in clockwise circles. Would you want your heading to be 18064? Would that mean anything to you? Which direction are you facing? No, instead ...
  • 15.1k
1 vote

Robot wire follower + how to position on wire

There are a lot of possible ways to solve your problem. First, let's get you off the wrong track: this isn't a simple, line following problem. For it to be a line following robot, you need to lay ...
1 vote
Accepted

Sensor orientation of an external magnetometer

I'll try to go through your question as best as I can: I was wondering, whether one could calculate the rotation of the sensor relative to the vehicle by application of the accelerometer and ...
  • 15.1k
1 vote

Axis of rotation via IMU

Yes, in theory, from the gyro information. The accelerometers will give you orientation information, but won't help you interpret where the axis has been translated to. Keep in mind though, that data ...
  • 1,037

Only top scored, non community-wiki answers of a minimum length are eligible