Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 47 additions & 0 deletions cnf/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,33 @@
<artifactId>jackson-annotations</artifactId>
<version>2.21</version>
</dependency>
<!-- START EEBUS Dependencies -->
<dependency>
<groupId>com.fasterxml.jackson.module</groupId>
<artifactId>jackson-module-jakarta-xmlbind-annotations</artifactId>
<version>2.21.2</version>
</dependency>
<dependency>
<groupId>jakarta.xml.bind</groupId>
<artifactId>jakarta.xml.bind-api</artifactId>
<version>4.0.5</version>
</dependency>
<dependency>
<groupId>org.jvnet.jaxb</groupId>
<artifactId>jaxb-plugins-runtime</artifactId>
<version>4.0.12</version>
</dependency>
<dependency>
<groupId>org.glassfish.jaxb</groupId>
<artifactId>jaxb-runtime</artifactId>
<version>4.0.7</version>
</dependency>
<dependency>
<groupId>com.sun.xml.bind</groupId>
<artifactId>jaxb-impl</artifactId>
<version>4.0.7</version>
</dependency>
<!-- END EEBUS Dependencies -->
<dependency>
<groupId>com.github.rzymek</groupId>
<artifactId>opczip</artifactId>
Expand Down Expand Up @@ -866,5 +893,25 @@
<artifactId>objenesis</artifactId>
<version>3.5</version>
</dependency>
<dependency>
<groupId>io.netty</groupId>
<artifactId>netty-transport</artifactId>
<version>4.2.12.Final</version>
</dependency>
<dependency>
<groupId>io.netty</groupId>
<artifactId>netty-handler</artifactId>
<version>4.2.12.Final</version>
</dependency>
<dependency>
<groupId>io.netty</groupId>
<artifactId>netty-common</artifactId>
<version>4.2.12.Final</version>
</dependency>
<dependency>
<groupId>io.netty</groupId>
<artifactId>netty-codec-http</artifactId>
<version>4.2.12.Final</version>
</dependency>
</dependencies>
</project>
12 changes: 12 additions & 0 deletions io.openems.common.bridge.eebus/.classpath
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="con" path="aQute.bnd.classpath.container"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-21"/>
<classpathentry kind="src" output="bin" path="src"/>
<classpathentry kind="src" output="bin_test" path="test">
<attributes>
<attribute name="test" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="output" path="bin"/>
</classpath>
2 changes: 2 additions & 0 deletions io.openems.common.bridge.eebus/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/bin_test/
/generated/
23 changes: 23 additions & 0 deletions io.openems.common.bridge.eebus/.project
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>io.openems.common.bridge.eebus</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>bndtools.core.bndbuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
<nature>bndtools.core.bndnature</nature>
</natures>
</projectDescription>
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
eclipse.preferences.version=1
encoding/<project>=UTF-8
13 changes: 13 additions & 0 deletions io.openems.common.bridge.eebus/bnd.bnd
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Bundle-Name: OpenEMS Common EEBUS Bridge
Bundle-Vendor: FENECON GmbH
Bundle-License: https://opensource.org/licenses/EPL-2.0
Bundle-Version: 1.0.0.${tstamp}

-buildpath: \
${buildpath},\
io.openems.common,\
javax.jmdns,\
org.openmuc.jeebus.ship,\

-testpath: \
${testpath}
6 changes: 6 additions & 0 deletions io.openems.common.bridge.eebus/readme.adoc
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
= Http

Http is a widely used standard for web communication. It is used for some hardware devices like electric meters, relays and so on.
The standard architecture used by the devices are RESTful api's.

https://github.com/OpenEMS/openems/tree/develop/io.openems.common.http[Source Code icon:github[]]
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
package io.openems.common.bridge.eebus.api;

import org.openmuc.jeebus.ship.api.ConnectionHandler;
import org.openmuc.jeebus.ship.api.DisconnectReason;
import org.openmuc.jeebus.ship.api.ShipConnectionInterface;
import org.osgi.service.component.annotations.Activate;
import org.osgi.service.component.annotations.Component;
import org.osgi.service.component.annotations.ServiceScope;

import java.net.Inet4Address;
import java.util.Arrays;
import java.util.Objects;

@Component(scope = ServiceScope.SINGLETON, service = EebusDeviceDiscovery.class)
public class EebusDeviceDiscovery {
/*private ServiceRegistry registry;

@Activate
public void activate() {
this.registry = new ServiceRegistry(Inet4Address.getLoopbackAddress(), "me", "_ship._tcp.local.", new ConnectionHandler() {
@Override
public void onMessageReceived(byte[] fullMsg, byte[] payload, ShipConnectionInterface shipConn) {
}

@Override
public void onDisconnect(DisconnectReason reason, ShipConnectionInterface shipConn) {
}

@Override
public void serviceAdded(String socketAddress, String ski) {
System.out.println("Service resolved: " + socketAddress + " - " + ski);
// TODO@fenecon: this is called whenever a SHIP mDNS Service is
// resolved.
// If the socket and SKI are not enough, you may use
// registry.listServices(); and filter that for the full
// service info. It is an ugly work-around though.
System.out.println(Arrays.stream(EebusDeviceDiscovery.this.registry.listServices())
.filter(s -> Objects.equals(
s.getAddress().getHostAddress() + ":" + s.getPort(),
socketAddress
)).findAny().get());
}

@Override
public void serviceRemoved(String ipAddr) {
}

@Override
public void connectionDataExchangeEnabled(String ipAddr) {
}
});
}*/

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@org.osgi.annotation.versioning.Version("1.0.0")
@org.osgi.annotation.bundle.Export
package io.openems.common.bridge.eebus.api;
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@org.osgi.annotation.versioning.Version("1.0.0")
@org.osgi.annotation.bundle.Export
package io.openems.common.bridge.eebus;
Empty file.
28 changes: 27 additions & 1 deletion io.openems.edge.application/EdgeApp.bndrun
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@
bnd.identity;id='io.openems.edge.bridge.modbus',\
bnd.identity;id='io.openems.edge.bridge.mqtt',\
bnd.identity;id='io.openems.edge.bridge.onewire',\
bnd.identity;id='io.openems.edge.bridge.eebus',\
bnd.identity;id='io.openems.edge.common',\
bnd.identity;id='io.openems.edge.controller.api.backend',\
bnd.identity;id='io.openems.edge.controller.api.common',\
Expand Down Expand Up @@ -229,6 +230,7 @@
bcprov;version='[1.84.0,1.84.1)',\
bcutil;version='[1.84.0,1.84.1)',\
com.fasterxml.aalto-xml;version='[1.4.0,1.4.1)',\
com.fasterxml.jackson.core.jackson-annotations;version='[2.21.0,2.21.1)',\
com.fazecast.jSerialComm;version='[2.11.4,2.11.5)',\
com.google.gson;version='[2.14.0,2.14.1)',\
com.google.guava;version='[33.6.0,33.6.1)',\
Expand Down Expand Up @@ -261,6 +263,7 @@
io.openems.edge.bridge.modbus;version=snapshot,\
io.openems.edge.bridge.mqtt;version=snapshot,\
io.openems.edge.bridge.onewire;version=snapshot,\
io.openems.edge.bridge.eebus;version=snapshot,\
io.openems.edge.common;version=snapshot,\
io.openems.edge.controller.api;version=snapshot,\
io.openems.edge.controller.api.backend;version=snapshot,\
Expand Down Expand Up @@ -503,4 +506,27 @@
org.owasp.encoder;version='[1.4.0,1.4.1)',\
reactive-streams;version='[1.0.4,1.0.5)',\
rrd4j;version='[3.10.0,3.10.1)',\
stax2-api;version='[4.3.0,4.3.1)'
stax2-api;version='[4.3.0,4.3.1)',\
io.netty.buffer;version='[4.2.12,4.2.13)',\
io.netty.codec-base;version='[4.2.12,4.2.13)',\
io.netty.codec-compression;version='[4.2.12,4.2.13)',\
io.netty.codec-http;version='[4.2.12,4.2.13)',\
io.netty.common;version='[4.2.12,4.2.13)',\
io.netty.handler;version='[4.2.12,4.2.13)',\
io.netty.resolver;version='[4.2.12,4.2.13)',\
io.netty.transport;version='[4.2.12,4.2.13)',\
io.netty.transport-native-unix-common;version='[4.2.12,4.2.13)',\
org.openmuc.jeebus.ship;version='[2.2.1,2.2.2)',\
io.openems.common.bridge.eebus;version=snapshot,\
com.fasterxml.jackson.core.jackson-core;version='[2.21.2,2.21.3)',\
com.fasterxml.jackson.core.jackson-databind;version='[2.21.2,2.21.3)',\
com.fasterxml.jackson.module.jackson-module-jakarta-xmlbind-annotations;version='[2.21.2,2.21.3)',\
com.sun.xml.bind.jaxb-core;version='[4.0.7,4.0.8)',\
jakarta.activation-api;version='[2.1.4,2.1.5)',\
jakarta.xml.bind-api;version='[4.0.5,4.0.6)',\
org.glassfish.jaxb.core;version='[4.0.7,4.0.8)',\
org.jvnet.jaxb.plugins-runtime;version='[4.0.12,4.0.13)',\
org.openmuc.jeebus.spine;version='[4.1.0,4.1.1)',\
org.openmuc.jeebus.usecase.powerlimitation.abstract-controllablesystem;version='[1.0.0,1.0.1)',\
org.openmuc.jeebus.usecase.powerlimitation.lpc-controllablesystem;version='[1.0.0,1.0.1)',\
org.openmuc.jeebus.usecase.powerlimitation.lpp-controllablesystem;version='[1.0.0,1.0.1)',\
12 changes: 12 additions & 0 deletions io.openems.edge.bridge.eebus/.classpath
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="con" path="aQute.bnd.classpath.container"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-21"/>
<classpathentry kind="src" output="bin" path="src"/>
<classpathentry kind="src" output="bin_test" path="test">
<attributes>
<attribute name="test" value="true"/>
</attributes>
</classpathentry>
<classpathentry kind="output" path="bin"/>
</classpath>
3 changes: 3 additions & 0 deletions io.openems.edge.bridge.eebus/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
/bin/
/bin_test/
/generated/
23 changes: 23 additions & 0 deletions io.openems.edge.bridge.eebus/.project
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>io.openems.edge.bridge.eebus</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>bndtools.core.bndbuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
<nature>bndtools.core.bndnature</nature>
</natures>
</projectDescription>
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
eclipse.preferences.version=1
encoding/<project>=UTF-8
27 changes: 27 additions & 0 deletions io.openems.edge.bridge.eebus/bnd.bnd
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
Bundle-Name: OpenEMS Edge Bridge EEBUS
Bundle-Vendor: FENECON GmbH
Bundle-License: https://opensource.org/licenses/EPL-2.0
Bundle-Version: 1.0.0.${tstamp}

-buildpath: \
${buildpath},\
io.openems.common,\
io.openems.common.bridge.eebus,\
io.openems.common.bridge.http,\
io.openems.edge.common,\
org.openmuc.jeebus.usecase.powerlimitation.abstract-controllablesystem,\
org.openmuc.jeebus.ship,\
org.openmuc.jeebus.spine,\
org.openmuc.jeebus.usecase.powerlimitation.lpc-controllablesystem,\
org.openmuc.jeebus.usecase.powerlimitation.lpp-controllablesystem,\
jakarta.xml.bind-api;version='[4.0.5,4.0.6)',\
org.jvnet.jaxb.plugins-runtime;version='[4.0.12,4.0.13)',\
bcpkix;version='[1.83,2)',\
bcprov;version='[1.83,2)',\
bcutil;version='[1.83,2)',\

-testpath: \
${testpath},\
bcpkix;version='[1.83,2)',\
bcprov;version='[1.83,2)',\
bcutil;version='[1.83,2)',\
Loading
Loading