Micro Compass ESP32



Micro compass is an open source compass UI project with esp32c3 mini and round tft display.


The UI is designed in SquareLine Studio and built with PlatformIO.



Parts required:

1. ESP32 C3 Supermini

AliExpress➡️ Buy Option 1  Buy Option 2

2. 1.28" GC9A01 display (7 Pin Version)


AliExpress➡️ Buy option 1  Buy option 2 

3. QMC5883P magnetometer (GY-271 module)

AliExpress➡️ Buy option 1  Buy option 2 

(Note: This project is based on QMC5883P not HMC5883L)

Circuit Diagram
Source Code:

Visit my github repository for code  https://github.com/LazydaysCr/micro-compass

I've made a step by step guideline on how to upload the code and calibrate the compass.


If you face any issue send me an email with subject "micro compass" to abid.business01@gmail.com

Comments

  1. I'd love one of these for aligning a telescope for astrophotography, does it reflect magnet or true North?

    ReplyDelete
    Replies
    1. Not true north. Magnetic north only.

      Delete
    2. The hardware MEASURES magnetic north, but you can use a fixed offset in the code, or an adjustable offset from either GPS, or an external knob to have it display true north.

      Delete
  2. This comment has been removed by the author.

    ReplyDelete
  3. I wanted this to work so bad. I’m a pilot and low how this matches a vertical compass card, however I was not able to get it to accurately read known headings. When turning the the Magnetometer 180 from a fixed point it would only read 165 degrees. I’ve calibrated twice with no change. Would really like for it to work correctly.

    ReplyDelete
    Replies
    1. I have the similar problem! Definitely a cool project. I ran the calibration test, entered the results and set the heading offset. It works perfectly from north to west but when I rotate from north to east it shows 120 degrees and south shows 220 degrees.
      Anybody know why this is happening? I'm thinking it's a bad magnatometer

      Delete
  4. Just like a whisky compass this needs an adjustment mechanism so it can be 'swung'. i.e. calibrated by offsetting the magnetic field of the actual mechanism so it detects only the earths magnetic field. It would need a small ferous magnetic object nearby that can be adjusted in horizontal XY position to do this. As a pilot you should know this.

    ReplyDelete

Post a Comment