Get information from GCE Eco-Devices.
Project description
pyecodevices - Python GCE Eco-Devices
Get information from GCE Eco-Devices
Parameters
host
: ip or hostnameport
: (default: 80)username
: if authentication enabled on Eco-Devicespassword
: if authentication enabled on Eco-Devicesrequest_timeout
: (default: 10)
Properties
host
: return the hostversion
: return the firmware versionmac_address
: return the mac address
Methods
get_info
: get properties from the APIglobal_get
: return all data from the APIget_t1
: return values of input T1get_t2
: return values of input T2get_c1
: return values of input C1get_c2
: return values of input C2
Example
from pyecodevices import EcoDevices
import asyncio
async def main():
async with EcoDevices('192.168.1.239', '80', "username", "password") as ecodevices:
await ecodevices.get_info()
print("firmware version:", ecodevices.version)
data = await ecodevices.global_get()
print("all values:", data)
data = await ecodevices.get_t1()
print("teleinfo 1:", data["current"], "VA")
if __name__ == "__main__":
loop = asyncio.get_event_loop()
loop.run_until_complete(main())
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pyecodevices-1.2.1.tar.gz
(3.7 kB
view details)
Built Distribution
File details
Details for the file pyecodevices-1.2.1.tar.gz
.
File metadata
- Download URL: pyecodevices-1.2.1.tar.gz
- Upload date:
- Size: 3.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.6.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4aa3d4db7752b414568eb50897f7cd5c3045e7352277a88e2937fbe572ac83bb |
|
MD5 | 816c6a989ee063692b8327e30c05693a |
|
BLAKE2b-256 | a8e139ff432554d1732e166ec448a5dde17e01ff4fd1c9dddf2bef56bb883ce6 |
Provenance
File details
Details for the file pyecodevices-1.2.1-py3-none-any.whl
.
File metadata
- Download URL: pyecodevices-1.2.1-py3-none-any.whl
- Upload date:
- Size: 3.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/3.7.3 pkginfo/1.6.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.54.1 CPython/3.9.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 09479ca12efc6e7d2b8d7ad327850af491eb1c482b4e807130798517f6385f6a |
|
MD5 | 07a22d78dc8201f4504b860537db436a |
|
BLAKE2b-256 | 852467d3eb5d7ed32753e8c113979e9cb60b81aca7aed054ff58d22ecc7b6175 |