modulepackage
0.2.0
Repository: https://github.com/roeldev/youless-client.git
Documentation: pkg.go.dev
# README
Client for YouLess energy monitor
Package youless
contains a client which can read from the api of a YouLess device.
go get github.com/roeldev/youless-client
import "github.com/roeldev/youless-client"
API
Method | Endpoint | Description |
---|---|---|
GetDeviceInfo | /d | Get device information |
GetMeterReading | /e | Get meter reading |
GetPhaseReading | /f | Get phase reading |
GetP1Telegram | /V?p=# | Get P1 telegram |
GetLog | /V | Get report of Electricity utility |
/W | Get report of Gas utility | |
/K | Get report of Water utility | |
/Z | Get report of S0 utility |
Utilities
Const | Page | Units |
---|---|---|
Electricity | V | Watt, kWh |
S0 | Z | Watt, kWh |
Gas | W | L, m3 |
Water | K | L, m3 |
Intervals
Const | Interval | Param | LS110 history* | LS120 history* | Unit (electricity/s0) | Unit (gas/water) |
---|---|---|---|---|---|---|
PerMin | 1 minute | h | 1 hour (2x30) | 10 hours (20x30) | watt | n/a |
Per10Min | 10 minutes | w | 1 day (3x48) | 10 days (30x48) | watt | liter |
PerHour | 1 hour | d | 7 days (7x24) | 70 days (70x24) | watt | liter |
PerDay | 1 day | m | 1 year (12x31) | 1 year (12x31) | kWh | m3 (cubic meter) |
- = max. history (amount of pages x data entries)
Units
Const | API equiv. | Utilities |
---|---|---|
Watt | Watt | electricity, s0 |
KWh | kWh | electricity, s0 |
Liter | L | gas, water |
CubicMeter | m3 | gas, water |
Documentation
Additional detailed documentation is available at pkg.go.dev
Links
- YouLess: https://youless.nl
- YouLess API info: http://wiki.td-er.nl/index.php?title=YouLess
Created with
License
Copyright © 2024 Roel Schut. All rights reserved.
This project is governed by a BSD-style license that can be found in the LICENSE file.
# Functions
No description provided by the author
NewAPIRequester returns an APIRequester which uses Requester r to make requests to the YouLess device's api.
NewClient creates a new Client with Config and applies any provided Option(s).
No description provided by the author
No description provided by the author
ParseTimestamp parses a timestamp from a uint64 in layout TimestampLayout to a time.Time.
ToTimestamp converts a time.Time to an uint64 timestamp in layout TimestampLayout.
No description provided by the author
No description provided by the author
WithHTTPClient sets the underlying http.Client for the client.
No description provided by the author
No description provided by the author
WithTracerProvider sets a new tracer for the client from the specified tracer provider.
# Constants
goland:noinspection GoUnusedConst.
goland:noinspection GoUnusedConst.
goland:noinspection GoUnusedConst.
goland:noinspection GoUnusedConst.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
goland:noinspection GoUnusedConst.
goland:noinspection GoUnusedConst.
goland:noinspection GoUnusedConst.
goland:noinspection GoUnusedConst.
No description provided by the author
goland:noinspection GoUnusedConst.
goland:noinspection GoUnusedConst.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
TimestampLayout is the layout used for non-unix timestamps, its format is "YYMMDDHHmm".
No description provided by the author
No description provided by the author
goland:noinspection GoUnusedConst.
# Structs
Client is an APIRequester which connects with the Youless device and is able to groupRequest data from its api.
Config is the configuration for a Client.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
MeterReadingResponse is the response from the /e endpoint.
P1TelegramResponse contains a raw PI telegram response from the [API.GetP1Telegram] call.
PhaseReading contains the reading values of a single phase.
https://community.home-assistant.io/t/youless-sensors-for-detailed-information-per-phase/433419 https://domoticx.com/p1-poort-slimme-meter-hardware/.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
# Interfaces
API is the interface containing all available api calls to the YouLess device.
APIRequester implements both API and Requester interfaces.
No description provided by the author
Requester requests and handles calls to a YouLess device.