]> git.basschouten.com Git - openhab-addons.git/blob
f943394127df4f899fa4515b48c3b249aa2e4523
[openhab-addons.git] /
1 /**
2  * Copyright (c) 2010-2024 Contributors to the openHAB project
3  *
4  * See the NOTICE file(s) distributed with this work for additional
5  * information.
6  *
7  * This program and the accompanying materials are made available under the
8  * terms of the Eclipse Public License 2.0 which is available at
9  * http://www.eclipse.org/legal/epl-2.0
10  *
11  * SPDX-License-Identifier: EPL-2.0
12  */
13 package org.openhab.binding.senechome.internal.dto;
14
15 import java.io.Serializable;
16
17 import com.google.gson.annotations.SerializedName;
18
19 /**
20  * Json model of senec home devices: This sub model contains values of current workload, i. e. current consumption and
21  * battery charge.
22  *
23  * Section is "ENERGY"
24  *
25  * @author Steven Schwarznau - Initial Contribution
26  */
27 public class SenecHomeEnergy implements Serializable {
28
29     private static final long serialVersionUID = -5491226594672777034L;
30
31     /**
32      * House power consumption (W).
33      */
34     public @SerializedName("GUI_HOUSE_POW") String housePowerConsumption;
35
36     /**
37      * Total inverter power (W).
38      * Named "energyProduction" on channel/thing-type side.
39      */
40     public @SerializedName("GUI_INVERTER_POWER") String inverterPowerGeneration;
41
42     /**
43      * Battery power in W (+values loading, -values unloading)
44      */
45     public @SerializedName("GUI_BAT_DATA_POWER") String batteryPower;
46
47     /**
48      * Battery current (A).
49      */
50     public @SerializedName("GUI_BAT_DATA_CURRENT") String batteryCurrent;
51
52     /**
53      * Battery voltage (V).
54      */
55     public @SerializedName("GUI_BAT_DATA_VOLTAGE") String batteryVoltage;
56
57     /**
58      * Battery charge rate (%).
59      */
60     public @SerializedName("GUI_BAT_DATA_FUEL_CHARGE") String batteryFuelCharge;
61
62     /**
63      * Encoded system state.
64      */
65     public @SerializedName("STAT_STATE") String systemState;
66
67     @Override
68     public String toString() {
69         return "SenecHomeEnergy [housePowerConsumption=" + housePowerConsumption + ", inverterPowerGeneration="
70                 + inverterPowerGeneration + ", batteryPower=" + batteryPower + ", batteryVoltage=" + batteryVoltage
71                 + ", batteryCurrent=" + batteryCurrent + ", batteryFuelCharge=" + batteryFuelCharge + ", systemState="
72                 + systemState + "]";
73     }
74 }