The HMC5883L is an easy to use and cheap module for measuring magnetic fields. A common purpose is to use the device to determine magnetic north ... and hence that makes it a compass. In this video and related code link, we use the ESP32 to read data from it.
https://www.youtube.com/watch?v=4JUnS0wViaQ
Code:
https://github.com/nkolban/esp32-snippe ... re/compass
[Video] ESP32 - HMC5883L - Compass
[Video] ESP32 - HMC5883L - Compass
Free book on ESP32 available here: https://leanpub.com/kolban-ESP32
Who is online
Users browsing this forum: No registered users and 23 guests