Skip to main content

Package for communicate with iec62056-21 Meters

Project description

Python IEC62056 Meter Tools

How to use ?

Install

pip install py-iec62056

Create SerialClient

client = SerialClient(
    baudrate=19200,
    port="COM3",
    transport="serial",
    parity="E",
    bytesize=7,
    stopbits=1
)

Read A meter identification

This return an identification message from the meter. You must set the ack_stop to True if you don't want to meter to give the default table.

result = client.read_tariff_identification("5987893", ack_stop=True)

Read Table dataset

This will return a list of DataSet instance. Raise error if Timeout.

result = client.request(meter_address="5987893", table=7, timeout=30)
assert isinstance(result, TariffResponse)
for dataset in result.data:
    logging.info(f"{dataset}")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

iec62056-protocol-1.0.1.tar.gz (2.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

iec62056_protocol-1.0.1-py3-none-any.whl (2.6 kB view details)

Uploaded Python 3

File details

Details for the file iec62056-protocol-1.0.1.tar.gz.

File metadata

  • Download URL: iec62056-protocol-1.0.1.tar.gz
  • Upload date:
  • Size: 2.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.12.0

File hashes

Hashes for iec62056-protocol-1.0.1.tar.gz
Algorithm Hash digest
SHA256 3c89ef9295c0ceb537ab69621aad1d4f6fc8acbcc6c2ec74f182c5c601aea6a4
MD5 afcfa1d4bd529c64c7b728afac0d7e22
BLAKE2b-256 8cbedd0dda8cd79ff04dac983a1fac628a7e37f60a03917d02f1f00ff88cf66f

See more details on using hashes here.

File details

Details for the file iec62056_protocol-1.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for iec62056_protocol-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 c69918f32c0dc3d1e67180ebd3705ac74ae1664854d647adfe0e235095005133
MD5 891ad573fd77708083dc4fcfcb0b6b14
BLAKE2b-256 16000645e88f0f5e6cb8548a23496ae4a612bfe9a9f72c3787762eb381ef3d21

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page