Giter Club home page Giter Club logo

openhab-lgessenervu-dist's Introduction

LGEssEnervu Binding

This binding is meant to retrieve data of the LG Ess Powerrouter/Battery bundle. It is designed to retrieve data either from the lg cloud (https://enervu.lg-ess.com) or via WLAN directly from the local device. Note that some data(e.g separate information for the strings) may not be retrieved from the lg cloud.

Supported Things

The following thing types are supported:

Thing ID Description
Powerrouter powerrouter Represents the physical powerrouter & battery device

Discovery

Once the binding is initialized it will look for devices on the local network. If a scan is started manually and a device could not be found just try again. From time to time the device does not respond on the first try.

Getting started

Obtaining the password for accessing the device via local network.

In order to get the device password you need to be within the wifi provided by the box. Once you are connected to the wifi of your device send a json request to https://192.168.23.1/v1/user/setting/read/password with the following payload {"key": "lgepmsuser!@#"}

Thing Configuration

Parameter Type Required/Optional Group Description
dataSourceCloud boolean required general Select the datasource where to retrieve data from
timeout integer optional general The timeout in seconds
kwhPrice decimal optional general Price of the kWh paid to local provider
kwhPriceSell decimal optional general Price local provider pays for selling power
co2Factor decimal optional general Factor of the powermix (e.g. 0.71% of bought power is from green energy
lowbatterythreshold integer optional general Battery SOC is considered low when equal or below this value
triggergeneratedpowerthreshold integer optional comforttrigger Threshold of generated power[W] by PV to trigger event
triggergeneratedpowerthresholdtime integer optional comforttrigger Time generated power needs to be above threshold until trigger is set (0 = instant)
triggergeneratedpowerthresholdresettime integer optional comforttrigger Time generated power needs to be below threshold until a new trigger may start
refreshInterval integer optional local How often shall data be polled (in seconds)
hostName text required if source is lan local hostname/ip of local device
passwordLocal text required if source is lan local password of the local device
user text required if source is cloud cloud username / email used for login at https://enervu.lg-ess.com
passwordCloud text required if source is cloud cloud password used for login at https://enervu.lg-ess.com
refreshIntervalCloud integer optional cloud How often shall data be polled (in seconds)

Channels

channel type description
currentPowerFromGrid Number:Power Current power taken from grid
dailyPowerFromGrid Number:Power Daily power taken from grid
monthlyPowerFromGrid Number:Power Monthly power taken from grid
currentPowerToGrid Number:Power Current power provided to grid
dailyPowerToGrid Number:Power Daily power provided to grid
monthlyPowerToGrid Number:Power Monthly power provided to grid
currentPowerFromPV Number:Power Current power produced by PV
dailyPowerFromPV Number:Power Daily power produced by PV
monthlyPowerFromPV Number:Power Monthly power produced by PV
batterySoc Number Current battery SOC state
batterySafetySoc Number Current battery SOC state
batteryStatus String Current battery operating mode (idle, charging,discharging)
batteryWintermode Switch Status of wintermode
currentPowerChargingToBattery Number:Power Current power used to charge the battery
dailyBatteryCharge Number:Energy Daily energy used to charge the battery
monthlyBatteryCharge Number:Energy Monthly energy used to charge the battery
currentPowerDischargingFromBattery Number:Power Current power used to discharge the battery
dailyPowerDischargingFromBattery Number:Energy Daily energy used to discharge the battery
monthlyPowerDischargingFromBattery Number:Energy Monthly energy used to discharge the battery
lowbattery Switch Lowbattery indicator set when soc is below configured threshold
trigger_battery_status Event Triggered once if battery is depleted,low or fully charged
currentTotalPowerConsumption Number:Power Current total power consumption (grid+battery+pv)
dailyTotalPowerConsumption Number:Energy Daily total energy consumption (grid+battery+pv)
monthlyTotalPowerConsumption Number:Energy Monthly total energy consumption (grid+battery+pv)
currentDirectPowerConsumption Number:Power Current direct power consumption from PV
dailyDirectPowerConsumption Number:Energy Daily direct energy consumption from PV
monthlyDirectPowerConsumption Number:Energy Monthly direct energy consumption from PV
selfConsumption Number Percentage of self consumption for the current day
string1CurrentPotential Number:ElectricPotential Current DC Voltage of string 1 (only for LAN mode)
string2CurrentPotential Number:ElectricPotential Current DC Voltage of string 2 (only for LAN mode)
string3CurrentPotential Number:ElectricPotential Current DC Voltage of string 3 (only for LAN mode)
string4CurrentPotential Number:ElectricPotential Current DC Voltage of string 4 (only for LAN mode)
string5CurrentPotential Number:ElectricPotential Current DC Voltage of string 5 (only for LAN mode)
currentCurrentString1 Number:ElectricCurrent Current DC Current of string 1 (only for LAN mode)
currentCurrentString2 Number:ElectricCurrent Current DC Current of string 2 (only for LAN mode)
currentCurrentString3 Number:ElectricCurrent Current DC Current of string 3 (only for LAN mode)
currentCurrentString4 Number:ElectricCurrent Current DC Current of string 4 (only for LAN mode)
currentCurrentString5 Number:ElectricCurrent Current DC Current of string 5 (only for LAN mode)
currentPowerString1 Number:Power Current DC power of string 1
currentPowerString2 Number:Power Current DC power of string 2
currentPowerString3 Number:Power Current DC power of string 3
currentPowerString4 Number:Power Current DC power of string 4
currentPowerString5 Number:Power Current DC power of string 5
isDirectConsuming Switch Is PV power currently directly consumed?
isBatteryCharging Switch Is the battery currently charging?
isBatteryDischarging Switch Is the battery currently discharging?
isGridSelling Switch Currently selling power to grid?
isGridBuying Switch Currently buying power from grid?
isChargingFromGrid Switch Is battery currently charging from grid?
monthlyCO2Savings Number Saved CO2 by consuming power from PV/Battery rather than from grid
monthlyEarnings Number Money earned by selling power to local energy provider in current month
monthlyPaid Number Money paid to local energy provider in current month
monthlyMoneySavings Number Saved money by selling power rather than buying in current month
trigger_powergen_status Event Triggered once pv produces power above a configurable threshold for a configured time

openhab-lgessenervu-dist's People

Contributors

mksway avatar

Stargazers

Nico avatar

Watchers

 avatar

openhab-lgessenervu-dist's Issues

Errors getNumericValueOfString empty String

I run openhab 3.4.4 and just installed the latest openhab-lgessenervu-dist-binding (3.4.3-SNAPSHOT). I get the following errors every 20 seconds:
2023-06-23 10:03:23.943 [ERROR] [ssenervu.internal.LGEssenervuHandler] - getNumericValueOfString empty String java.lang.NumberFormatException: empty String at jdk.internal.math.FloatingDecimal.readJavaFormatString(FloatingDecimal.java:1842) ~[?:?] at jdk.internal.math.FloatingDecimal.parseDouble(FloatingDecimal.java:110) ~[?:?] at java.lang.Double.parseDouble(Double.java:543) ~[?:?] at org.openhab.binding.lgessenervu.internal.LGEssenervuHandler.getNumericValueOfString(LGEssenervuHandler.java:322) [bundleFile:?] at org.openhab.binding.lgessenervu.internal.LGEssenervuHandler.responseCallbackCurrentData(LGEssenervuHandler.java:483) [bundleFile:?] at org.openhab.binding.lgessenervu.internal.client.LGLanClient.getCurrentData(LGLanClient.java:174) [bundleFile:?] at org.openhab.binding.lgessenervu.internal.job.SnapshotJob.run(SnapshotJob.java:35) [bundleFile:?] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) [?:?] at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) [?:?] at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) [?:?] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?] at java.lang.Thread.run(Thread.java:829) [?:?]

Uninstalling the binding and using the old version 3.1.0 solves the problem, there I have no errors.

Not working with OH 3.4.1 / 3.4.2

Hi, I have tried to implement the the binding by simply copying the org.openhab.binding.lgessenervu-3.1.0-SNAPSHOT.jar file to the /usr/share/openhab/addons directory of my 3.4.1 openhabian on a raspberry Pi3
unfortunately, the binding is not recognized - it is not possible to create a correspponding thing using this binding (using the white plus in the blue bullet in the things view of OH 3.4.1, the binding cannot be chosen)

I restarted my installation several times, I cleaned the OH cache, I extended the file authorizations - all without any success

another try was using my raspberry PI with a brand new, native OH 3.4.2 Relase Build -

any advice? is the 3.1.0 binding snapshot version really not working in a 3.4.x environment? what a pity...
(my fallback is using the PYESS package, but of course I think your approach is much closer to openhab)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.