2 * Copyright (c) 2010-2024 Contributors to the openHAB project
4 * See the NOTICE file(s) distributed with this work for additional
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
11 * SPDX-License-Identifier: EPL-2.0
13 package org.openhab.binding.solax.internal.model.local;
15 import org.eclipse.jdt.annotation.NonNullByDefault;
16 import org.openhab.binding.solax.internal.connectivity.rawdata.local.LocalConnectRawDataBean;
19 * The {@link X1BoostAirMiniInverterData} is an implementation of the single phased inverter data interface for X1 Mini
20 * / X1 Air Mini or X1 Boost Mini inverter.
22 * @author Konstantin Polihronov - Initial contribution
25 public class X1BoostAirMiniInverterData extends CommonLocalInverterData {
27 public X1BoostAirMiniInverterData(LocalConnectRawDataBean data) {
32 public double getInverterVoltage() {
33 return (double) getData(0) / 10;
37 public double getInverterCurrent() {
38 return (double) getData(1) / 10;
42 public short getInverterOutputPower() {
47 public double getPV1Voltage() {
48 return (double) getData(3) / 10;
52 public double getPV2Voltage() {
53 return (double) getData(4) / 10;
57 public double getPV1Current() {
58 return (double) getData(5) / 10;
62 public double getPV2Current() {
63 return (double) getData(6) / 10;
67 public short getPV1Power() {
72 public short getPV2Power() {
77 public double getInverterFrequency() {
78 return (double) getData(9) / 100;
82 public double getTotalEnergy() {
83 return (double) getData(11) / 10;
87 public double getTodayEnergy() {
88 return (double) getData(13) / 10;
92 public short getPowerUsage() {
93 return (short) Math.round((double) getData(43) / 10);