GitHub repository: tehniemer/esphome-magnetometer-water-gas-meter
Description: Using ESP8266 or ESP32 and QMC5883L, a triple-axis magnetometer, to read your water meter or gas meter