Skip to content

Aims to periodically reads over IR the register of a Landis+Gyr E230 Power Meter and displays some statistics in a console app

Notifications You must be signed in to change notification settings

gbolabs/landisgyr-e230-reporter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

55 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Objective

Aims to periodically reads over IR the register of a Landis+Gyr E230 Power Meter and displays some statistics in a console app

Side objectives

  • Realize a clean and proper C# console application.
  • Submit the read data to a http://www.volkszaehler.org/ instance hosted on Synology using Docker.

Material used

  • Using an IR Reader ()
  • Using a RaspberryPi ()
  • Using a 3.2-inch HAT-Screen ()

Principle

  1. Triggers a read using echo -n -e '\x2F\x3F\x21\x0D\x0A' > /dev/ttyUSB0
  2. Reads the output into a C# application manually the output can be read while having run this command before chating with the unit. cat /dev/ttyUSB0
  3. At first the application will only show the latest values. The statistics will be added later on.

Sample Output

This output has been read using the cat-command.

/LGZ4ZMR120AC.K750
/LGZ4ZMR120AC.K750
F.F.0(00000000)
0.0.2(  175225)
0.0.0(13267131)
0.0.3(        )
1.8.1(024581.111*kWh)
1.8.2(019882.194*kWh)
2.8.1(000000.000*kWh)
2.8.2(000000.000*kWh)
1.8.0(044463.305*kWh)
2.8.0(000000.000*kWh)
15.8.0(044463.305*kWh)
C.7.0(0053)
32.7.0(233)
52.7.0(235)
72.7.0(236)
31.7.0(001.06)
51.7.0(001.93)
71.7.0(000.12)
p

Corresponding OBIS-Code: https://www.promotic.eu/en/pmdoc/Subsystems/Comm/PmDrivers/IEC62056_OBIS.htm

Python Implementation

To ease the string-processing and posting results to http-based API I transform the bash-base sample into a python application.

Programatic read using Python

Sources / References

Without those sources and references I would not have been able to achieve this result.

How to develop

Linux

sudo apt install python3 python3-pip
pip install requests

About

Aims to periodically reads over IR the register of a Landis+Gyr E230 Power Meter and displays some statistics in a console app

Resources

Stars

Watchers

Forks

Packages

No packages published