Skip to content

lesinigo/sdm2influx

Repository files navigation

sdm2influx

A multithreaded Python application that reads energy measurements from Eastron SDM 120/230 Modbus meters and stores them in InfluxDB, with optional ZeroMQ data publishing.

Overview

This Python module continuously monitors one or more Eastron SDM120 / SDM230 Modbus energy meters, storing the collected data in an InfluxDB time-series database. Additionally, it can publish real-time data through ZeroMQ for integration with other systems.

It has been developed and is in real world usage on a Raspberry Pi 1 Model B revision 1 (older 256MB model).

Requirements

Runtime Dependencies

System Requirements

  • Access to Eastron SDM120/SDM230 energy meters via Modbus
  • InfluxDB instance for data storage
  • Optional: ZeroMQ-compatible systems for real-time data consumption

Usage

To see all available command-line options and configuration parameters:

python sdm2influx.py -h

Basic Example

# Monitor a single meter and store data in InfluxDB
python sdm2influx.py --influx-host localhost --influx-database energy_data

For detailed configuration options, refer to the help output.

Development

  1. Install the required development tools:

  2. Set up the development environment:

    pre-commit install
    make install

Wishlist

  • Publish package to PyPI
  • Support for complex meter configurations like multi-branch monitoring

Contributing

Contributions are welcome! Please ensure all code passes make check to maintain code quality.

About

read Eastron SDM 120/230 measurements via ModBus and store them to InfluxDB

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published