Categorygithub.com/roeldev/youless-client
modulepackage
0.2.0
Repository: https://github.com/roeldev/youless-client.git
Documentation: pkg.go.dev

# README

Client for YouLess energy monitor

Latest release Build status Go Report Card Documentation

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

MethodEndpointDescription
GetDeviceInfo/dGet device information
GetMeterReading/eGet meter reading
GetPhaseReading/fGet phase reading
GetP1Telegram/V?p=#Get P1 telegram
GetLog/VGet report of Electricity utility
/WGet report of Gas utility
/KGet report of Water utility
/ZGet report of S0 utility

Utilities

ConstPageUnits
ElectricityVWatt, kWh
S0ZWatt, kWh
GasWL, m3
WaterKL, m3

Intervals

ConstIntervalParamLS110 history*LS120 history*Unit (electricity/s0)Unit (gas/water)
PerMin1 minuteh1 hour (2x30)10 hours (20x30)wattn/a
Per10Min10 minutesw1 day (3x48)10 days (30x48)wattliter
PerHour1 hourd7 days (7x24)70 days (70x24)wattliter
PerDay1 daym1 year (12x31)1 year (12x31)kWhm3 (cubic meter)
  • = max. history (amount of pages x data entries)

Units

ConstAPI equiv.Utilities
WattWattelectricity, s0
KWhkWhelectricity, s0
LiterLgas, water
CubicMeterm3gas, water

Documentation

Additional detailed documentation is available at pkg.go.dev

Links

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.

# Type aliases

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author