forked from J-N-K/openhab-addons
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[semsportal] initial contribution (openhab#10100)
Signed-off-by: Iwan Bron <bron@olisa.eu>
- Loading branch information
1 parent
bfae70e
commit 04dc78b
Showing
36 changed files
with
2,817 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
This content is produced and maintained by the openHAB project. | ||
|
||
* Project home: https://www.openhab.org | ||
|
||
== Declared Project Licenses | ||
|
||
This program and the accompanying materials are made available under the terms | ||
of the Eclipse Public License 2.0 which is available at | ||
https://www.eclipse.org/legal/epl-2.0/. | ||
|
||
== Source Code | ||
|
||
/~https://github.com/openhab/openhab-addons |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
# SEMSPortal Binding | ||
|
||
This binding can help you include statistics of your SEMS / GoodWe solar panel installation into openHAB. | ||
It is a read-only connection that maps collected parameters to openHAB channels. | ||
It provides current, day, month and total yields, as well as some income statistics if you have configured these in the SEMS portal. | ||
It requires a power station that is connected through the internet to the SEMS portal. | ||
|
||
## Supported Things | ||
|
||
This binding provides two Thing types: a bridge to the SEMS Portal, and the Power Stations which are found at the Portal. | ||
The Portal (semsportal:portal) represents your account in the SEMS portal. | ||
The Power Station (semsportal:station) is an installation of a Power Station or inverter that reports to the SEMS portal and is available to your account. | ||
|
||
## Discovery | ||
|
||
Once you have configured a Portal Bridge, the binding will discover all Power Stations that are available to this account. | ||
You can trigger discovery in the add new Thing section of openHAB. | ||
Select the SEMS binding and press the Scan button. | ||
The discovered Power Stations will appear as new Things. | ||
|
||
## Thing Configuration | ||
|
||
The configuration of the Portal Thing (Bridge) is pretty straight forward. | ||
You need to have your power station set up in the SEMS portal, and you need to have an account that is allowed to view the power station data. | ||
You should log in at least once in the portal with this account to activate it. | ||
The Portal needs the username and password to connect and retrieve the data. | ||
You can configure the update frequency between 1 and 60 minutes. | ||
The default is 5 minutes. | ||
|
||
Power Stations have no settings and will be auto discovered when you add a Portal Bridge. | ||
|
||
## Channels | ||
|
||
The Portal(Bridge) has no channels. | ||
The Power Station Thing has the following channels: | ||
|
||
| channel | type | description | | ||
| ------------- | ---------------- | ---------------------------------------------------------------------------------------------------------- | | ||
| lastUpdate | DateTime | Last time the powerStation sent information to the portal | | ||
| currentOutput | Number:Power | The current output of the powerStation in Watt | | ||
| todayTotal | Number:Energy | Todays total generation of the station in kWh | | ||
| monthTotal | Number:Energy | This month's total generation of the station in kWh | | ||
| overallTotal | Number:Energy | The total generation of the station since installation, in kWh | | ||
| todayIncome | Number | Todays income as reported by the portal, if you have configured the power rates of your energy provider | | ||
| totalIncome | Number | The total income as reported by the portal, if you have configured the power rates of your energy provider | | ||
|
||
## Parameters | ||
|
||
The PowerStation Thing has no parameters. | ||
Only the Bridge has the following configuration parameters: | ||
|
||
| Parameter | Required? | Description | | ||
| ----------- |:---------:| ---------------------------------------------------------------------------------------------------------- | | ||
| username | X | Account name (email address) at the SEMS portal. Account must have been used at least once to log in. | | ||
| password | X | Password of the SEMS portal | | ||
| update | | Number of minutes between two updates. Between 1 and 60 minutes, defaults to 5 minutes | | ||
|
||
## Credits | ||
|
||
This binding has been created using the information provided by RogerG007 in this forum topic: https://community.openhab.org/t/connecting-goodwe-solar-panel-inverter-to-openhab/85480 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://maven.apache.org/POM/4.0.0" | ||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
|
||
<modelVersion>4.0.0</modelVersion> | ||
|
||
<parent> | ||
<groupId>org.openhab.addons.bundles</groupId> | ||
<artifactId>org.openhab.addons.reactor.bundles</artifactId> | ||
<version>3.1.0-SNAPSHOT</version> | ||
</parent> | ||
|
||
<artifactId>org.openhab.binding.semsportal</artifactId> | ||
|
||
<name>openHAB Add-ons :: Bundles :: SEMSPortal Binding</name> | ||
|
||
</project> |
9 changes: 9 additions & 0 deletions
9
bundles/org.openhab.binding.semsportal/src/main/feature/feature.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<features name="org.openhab.binding.semsportal-${project.version}" xmlns="http://karaf.apache.org/xmlns/features/v1.4.0"> | ||
<repository>mvn:org.openhab.core.features.karaf/org.openhab.core.features.karaf.openhab-core/${ohc.version}/xml/features</repository> | ||
|
||
<feature name="openhab-binding-semsportal" description="SEMSPortal Binding" version="${project.version}"> | ||
<feature>openhab-runtime-base</feature> | ||
<bundle start-level="80">mvn:org.openhab.addons.bundles/org.openhab.binding.semsportal/${project.version}</bundle> | ||
</feature> | ||
</features> |
31 changes: 31 additions & 0 deletions
31
...sportal/src/main/java/org/openhab/binding/semsportal/internal/CommunicationException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
/** | ||
* Copyright (c) 2010-2021 Contributors to the openHAB project | ||
* | ||
* See the NOTICE file(s) distributed with this work for additional | ||
* information. | ||
* | ||
* This program and the accompanying materials are made available under the | ||
* terms of the Eclipse Public License 2.0 which is available at | ||
* http://www.eclipse.org/legal/epl-2.0 | ||
* | ||
* SPDX-License-Identifier: EPL-2.0 | ||
*/ | ||
package org.openhab.binding.semsportal.internal; | ||
|
||
import org.eclipse.jdt.annotation.NonNullByDefault; | ||
|
||
/** | ||
* Exception indicating there was a problem communicating with the portal. It can indicate either no response at all, or | ||
* a response that was not expected. | ||
* | ||
* @author Iwan Bron - Initial contribution | ||
* | ||
*/ | ||
@NonNullByDefault | ||
public class CommunicationException extends Exception { | ||
private static final long serialVersionUID = 4175625868879971138L; | ||
|
||
public CommunicationException(String message) { | ||
super(message); | ||
} | ||
} |
30 changes: 30 additions & 0 deletions
30
...sportal/src/main/java/org/openhab/binding/semsportal/internal/ConfigurationException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
/** | ||
* Copyright (c) 2010-2021 Contributors to the openHAB project | ||
* | ||
* See the NOTICE file(s) distributed with this work for additional | ||
* information. | ||
* | ||
* This program and the accompanying materials are made available under the | ||
* terms of the Eclipse Public License 2.0 which is available at | ||
* http://www.eclipse.org/legal/epl-2.0 | ||
* | ||
* SPDX-License-Identifier: EPL-2.0 | ||
*/ | ||
package org.openhab.binding.semsportal.internal; | ||
|
||
import org.eclipse.jdt.annotation.NonNullByDefault; | ||
|
||
/** | ||
* Exception indicating that the configuration of the portal was wrong, like an unknown account or invalid password. | ||
* | ||
* @author Iwan Bron - Initial contribution | ||
* | ||
*/ | ||
@NonNullByDefault | ||
public class ConfigurationException extends Exception { | ||
private static final long serialVersionUID = -803416460838670618L; | ||
|
||
public ConfigurationException(String message) { | ||
super(message); | ||
} | ||
} |
Oops, something went wrong.