Simple Electronic Compass

This is a simple electronic compass display project, which uses the HM55B compass module to determine the North direction. The LEDs will be used to indicate where North is. When the module is facing north, the specific LED that is facing north will light up. The code used was adapted from here.

How it works


The HM55B compass module is a dual axis magnetic field sensor, which means that it measures the strength of magnetic field of both the x-axis & y-axis. In this project, we will measure the surrounding magnetic field & indicate the direction of North using 4 LEDs located, which would be allocated as North, South, East & West direction respectively.



Basically, when the Compass Module is facing North, the LED facing North will light up.