Building A Heading Sensor Resistant To Magnetic Disturbances

Light aircraft often use a heading indicator as a way to know where they’re going. Retired instrumentation engineer [Don Welch] recreated a heading indicator of his own, using cheap off-the-shelf hardware to get the job done.

The heart of the build is a Teensy 4.0 microcontroller. It’s paired with a BNO085 inertial measurement unit (IMU), which combines a 3-axis gyro, 3-axis accelerometer, and 3-axis magnetometer into a single package. [Don] wanted to build a heading indicator that was immune to magnetic disturbances, so ignored the magnetometer readings entirely, using the rest of the IMU data instead.

Upon startup, the Teensy 4.0 initializes a small round TFT display, and draws the usual compass rose with North at the top of the display. Any motion after this will update the heading display accordingly, with [Don] noting the IMU has a fast update rate of 200 Hz for excellent motion tracking. The device does not self-calibrate to magnetic North; instead, an encoder can be used to calibrate the device to match a magnetic compass you have on hand. Or, you can just ensure it’s already facing North when you turn it on.

Thanks to the power of the Teensy 4.0 and the rapid updates of the BNO085, the display updates are nicely smooth and responsive. However, [Don] notes that it’s probably not quite an aircraft-spec build. We’ve featured some interesting investigations of just how much you can expect out of MEMS-based sensors like these before, too.

Continue reading “Building A Heading Sensor Resistant To Magnetic Disturbances”

A Compass That Looks To The Stars

Although a lot of tools have been digitized and consolidated into our smartphones, from cameras, music players, calendars, alarm clocks, flashlights, and of course phones, perhaps none are as useful as the GPS and navigational capabilities. The major weakness here, though, is that this is a single point of failure. If there’s no cell service, if the battery dies, or you find yourself flying a bomber during World War II then you’re going to need another way to navigate, possibly using something like this Astro Compass.

The compass, as its name implies, also doesn’t rely on using the Earth’s magnetic field since that would have been difficult or impossible inside of an airplane. Instead, it can use various celestial bodies to get a heading. But it’s not quite as simple as pointing it at a star and heading off into the wild blue yonder. First you’ll need to know the current time and date and look those up in a companion chart. The chart lists the global hour angle and the declination for a number of celestial bodies which can be put into the compass. From there the latitude is set and the local hour angle is calculated and set, and then the compass is rotated until the object is sighted. After all of that effort, a compass heading will be shown.

For all its complexity, a tool like this can be indispensable in situations where modern technology fails. While it does rely on precise tabulated astrometric data to be on hand, as long as that’s available it’s almost failsafe, especially compared to a modern smartphone. Of course, you’ll also need a fairly accurate way of timekeeping which can be difficult in some situations.

Continue reading “A Compass That Looks To The Stars”

Do You Know Where Your Drone Is Headed? HJWYDK Article Explores Limits Of MEMS Sensors

Knowing in what absolute direction your robot is pointed can be crucial, and expensive systems like those used by NASA on Mars are capable of calculating this six-dimensional heading vector to within around one degree RMS, but they are fairly expensive. If you want similar accuracy on a hacker budget, this paper shows you how to do it using cheap MEMS sensors, an off-the-shelf motion co-processor IC, and the right calibration method.

The latest article to be published in our own peer-reviewed Hackaday Journal is Limits of Absolute Heading Accuracy Using Inexpensive MEMS Sensors  (PDF). In this paper, Gregory Tomasch and Kris Winer take a close look at the heading accuracy that can be obtained using several algorithms coupled with two different MEMS sensor sets. Their work shows that when properly used, inexpensive sensors can produce results on par with much more costly systems. This is a great paper that illustrates the practical contributions our community can make to technology, and we’re proud to publish it in the Journal.

Continue reading “Do You Know Where Your Drone Is Headed? HJWYDK Article Explores Limits Of MEMS Sensors”