Hoermann BiSecure Binding

This binding is designed to manage garage doors from Hörmann which are connected to a BiSecure Gateway. With this binding the BiSecure gateway and all doors (and other devices) which are configured in the BiSecure Mobile App are automatically discovered. You can get the current position of the garage door and you can open or close it. It should work like any other roller shutter.

BiSecure Gateway

This is the basic connection to the BiSecure gateway. You can set the username and password for the user to be used in the configuration of this thing.

Be aware that you should use a different user for each client connected to your BiSecure gateway. So you should not use the same client here as you use in the mobile app. The default user name is “admin” and password “0000”, which are the standard credential if nothing was changed. You should of course already have changed this!

BiSecure Group

A BiSecure group is any device connected to the BiSecure gateway. Your garage door will appear as a BiSecure group. The group needs no additional configuration. Only garage doors (BiSecure Type 1) devices are currently supported.

Discovery

When calling the auto discovery the gateway is discovered first. You should then correct the username and password for the BiSecure gateway and call the device discovery for the BiSecure binding again. Then all your attached devices should be discovered.

If auto discovery fails (e.g. because of network problems etc) you can add a BiSecure Gateway thing manually and set the gatewayAddress and gatewayId in the configuration properties manually.

Docker

For auto discovery to work, you will need to set the network mode to host

Thing Configuration

You should at least configure your username and password for the connection of the binding to your BiSecure Gateway. You can create this user in the mobile app and don’t forget to give him rights for all devices needed.

username=admin
password=0000

If doing manual adding of the gateway (which is normally filled by auto discovery:

gatewayAddress=192.168.0.3
gatewayId=5410EC036151

If you get often TimeoutExceptions during execution of requests, you can increase the receiveTimeout to a higher value than the default one (2000ms):

readTimeout=5000

Channels

Currently only channels for port type IMPULS are created.

| channel | type | description |

|---------|---------------|-------------------------------|

| IMPULS | Rollershutter | The impulse controlled device |

Full Example

Coming soon

Trouble Shooting

For better error investigation please set Loglevel to DEBUG. In Karaf console execute: log:set DEBUG org.openhab.binding.bisecuregateway

Binding does not install

If you see only “Start BiSecure Gateway background discovery” and no further logging of the BiSecure binding, then most probably the auto discovery is not working. If you are running under docker, the auto discovery could just not work here. Workaround is not yet available.

Auto Discovery of Gateway does not work

Add the gateway thing manually and set gatewayAddress and gatewayId in configuration

Auto Discovery of groups (devices) does not work

Check if you supplied correct username and password in the gateway thing configuration. Check the log file for more details which error occured.

Changelog

Version for OH 3.2

  • added: Parameter to disable state check before command execution

Resources

Download KAR File

Github Sources

3 Likes

Hi Thomas

I made test installation with the newest version of your binding on top of my openhab 3.3 (rpi) and noticed following issue at time of starting:

2022-01-20 21:41:04.183 [INFO ] [egateway.internal.BiSdkLoggerAdapter] - Received Exception Receiver got signal to stop -> stopping receiving activities  => retrying...
2022-01-20 21:41:24.246 [ERROR] [nternal.handler.BiSecureGroupHandler] - Got error while trying to get groups. Will retry in 30sec...
java.lang.IllegalStateException: Timeout waiting for PackageReceived (after waiting 20000 ms)
	at org.bisdk.sdk.UtilsKt.waitFor(Utils.kt:16) ~[bundleFile:?]
	at org.bisdk.sdk.UtilsKt.waitFor$default(Utils.kt:7) ~[bundleFile:?]
	at org.bisdk.sdk.Receiver.retrieveAnswer(Receiver.kt:22) ~[bundleFile:?]
	at org.bisdk.sdk.GatewayConnection.readAnswer(GatewayConnection.kt:114) ~[bundleFile:?]
	at org.bisdk.sdk.ClientAPI.relogin(ClientAPI.kt:88) ~[bundleFile:?]
	at org.bisdk.sdk.ClientAPI.sendWithRetry(ClientAPI.kt:268) ~[bundleFile:?]
	at org.bisdk.sdk.ClientAPI.getGroups(ClientAPI.kt:138) ~[bundleFile:?]
	at org.openhab.binding.bisecuregateway.internal.handler.BiSecureGatewayHandler.getGroups(BiSecureGatewayHandler.java:118) ~[bundleFile:?]
	at org.openhab.binding.bisecuregateway.internal.handler.BiSecureGroupHandler.initializeGroups(BiSecureGroupHandler.java:127) ~[bundleFile:?]
	at org.openhab.binding.bisecuregateway.internal.handler.BiSecureGroupHandler$1.run(BiSecureGroupHandler.java:110) [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) [?:?]
2022-01-20 21:41:24.253 [WARN ] [ernal.handler.BiSecureGatewayHandler] - childHandlerInitialized not implemented!

would you advice what can cause Exception related with timeout waiting, Thanks,

Regards,

Slawek

On more thing, after restart the service Openhab 3.2 when we have installed latest version bisecur binding this cause following error, which directly appears as a one of fist entry in openhab.log at time of starting openhab service.

ore.features.karaf:org.openhab.core.features.karaf.openhab-core:xml:features:3.3.0-SNAPSHOT] : mvn:org.openhab.core.features.karaf/:/3.3.0-SNAPSHOT/xml/features
	at org.apache.karaf.features.internal.service.RepositoryImpl.load(RepositoryImpl.java:121) ~[bundleFile:?]
	at org.apache.karaf.features.internal.service.RepositoryImpl.<init>(RepositoryImpl.java:51) ~[bundleFile:?]
	at org.apache.karaf.features.internal.service.RepositoryCacheImpl.create(RepositoryCacheImpl.java:51) ~[bundleFile:?]
	at org.apache.karaf.features.internal.service.FeaturesServiceImpl.getFeatureCache(FeaturesServiceImpl.java:611) [bundleFile:?]
	at org.apache.karaf.features.internal.service.FeaturesServiceImpl.ensureCacheLoaded(FeaturesServiceImpl.java:582) [bundleFile:?]
	at org.apache.karaf.features.internal.service.FeaturesServiceImpl.listRequiredRepositories(FeaturesServiceImpl.java:514) [bundleFile:?]
	at org.apache.karaf.deployer.features.FeatureDeploymentListener.bundleChanged(FeatureDeploymentListener.java:247) [bundleFile:?]
	at org.apache.karaf.deployer.features.FeatureDeploymentListener.init(FeatureDeploymentListener.java:90) [bundleFile:?]
	at org.apache.karaf.deployer.features.osgi.Activator$DeploymentFinishedListener.deploymentEvent(Activator.java:86) [bundleFile:?]
	at org.apache.karaf.features.internal.service.FeaturesServiceImpl.registerListener(FeaturesServiceImpl.java:296) [bundleFile:?]
	at org.apache.karaf.deployer.features.osgi.Activator.doStart(Activator.java:53) [bundleFile:?]
	at org.apache.karaf.util.tracker.BaseActivator.start(BaseActivator.java:92) [bundleFile:?]
	at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:814) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:1) [org.eclipse.osgi-3.16.300.jar:?]
	at java.security.AccessController.doPrivileged(Native Method) ~[?:?]
	at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:806) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:763) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:1028) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:371) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.container.Module.doStart(Module.java:605) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.container.Module.start(Module.java:468) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel$2.run(ModuleContainer.java:1849) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.internal.framework.EquinoxContainerAdaptor$1$1.execute(EquinoxContainerAdaptor.java:136) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1842) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1785) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1747) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1669) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:234) [org.eclipse.osgi-3.16.300.jar:?]
	at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:345) [org.eclipse.osgi-3.16.300.jar:?]
Caused by: java.io.IOException: Error resolving artifact org.openhab.core.features.karaf:org.openhab.core.features.karaf.openhab-core:xml:features:3.3.0-SNAPSHOT: [Could not find artifact org.openhab.core.features.karaf:org.openhab.core.features.karaf.openhab-core:xml:features:3.3.0-SNAPSHOT]
	at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.configureIOException(AetherBasedResolver.java:803) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:774) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:657) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:598) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:565) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:555) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.Connection.getInputStream(Connection.java:123) ~[?:?]
	at java.net.URL.openStream(URL.java:1165) ~[?:?]
	
	at org.apache.karaf.features.internal.service.RepositoryImpl.load(RepositoryImpl.java:114) ~[bundleFile:?]
	... 29 more
	Suppressed: shaded.org.eclipse.aether.transfer.ArtifactNotFoundException: Could not find artifact org.openhab.core.features.karaf:org.openhab.core.features.karaf.openhab-core:xml:features:3.3.0-SNAPSHOT
	        at shaded.org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:403) ~[?:?]
	        at shaded.org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolveArtifacts(DefaultArtifactResolver.java:215) ~[?:?]
	        at shaded.org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolveArtifact(DefaultArtifactResolver.java:192) ~[?:?]
	        at shaded.org.eclipse.aether.internal.impl.DefaultRepositorySystem.resolveArtifact(DefaultRepositorySystem.java:247) ~[?:?]
	        at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:767) ~[?:?]
	        at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:657) ~[?:?]
	        at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:598) ~[?:?]
	        at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:565) ~[?:?]
	        at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:555) ~[?:?]
	        at org.ops4j.pax.url.mvn.internal.Connection.getInputStream(Connection.java:123) ~[?:?]
	        at java.net.URL.openStream(URL.java:1165) ~[?:?]
	        at org.apache.karaf.features.internal.service.RepositoryImpl.load(RepositoryImpl.java:114) ~[bundleFile:?]
	        at org.apache.karaf.features.internal.service.RepositoryImpl.<init>(RepositoryImpl.java:51) ~[bundleFile:?]
	        at org.apache.karaf.features.internal.service.RepositoryCacheImpl.create(RepositoryCacheImpl.java:51) ~[bundleFile:?]
	        at org.apache.karaf.features.internal.service.FeaturesServiceImpl.getFeatureCache(FeaturesServiceImpl.java:611) [bundleFile:?]
	        at org.apache.karaf.features.internal.service.FeaturesServiceImpl.ensureCacheLoaded(FeaturesServiceImpl.java:582) [bundleFile:?]
	        at org.apache.karaf.features.internal.service.FeaturesServiceImpl.listRequiredRepositories(FeaturesServiceImpl.java:514) [bundleFile:?]
	        at org.apache.karaf.deployer.features.FeatureDeploymentListener.bundleChanged(FeatureDeploymentListener.java:247) [bundleFile:?]
	        at org.apache.karaf.deployer.features.FeatureDeploymentListener.init(FeatureDeploymentListener.java:90) [bundleFile:?]
	        at org.apache.karaf.deployer.features.osgi.Activator$DeploymentFinishedListener.deploymentEvent(Activator.java:86) [bundleFile:?]
	        at org.apache.karaf.features.internal.service.FeaturesServiceImpl.registerListener(FeaturesServiceImpl.java:296) [bundleFile:?]
	        at org.apache.karaf.deployer.features.osgi.Activator.doStart(Activator.java:53) [bundleFile:?]
	        at org.apache.karaf.util.tracker.BaseActivator.start(BaseActivator.java:92) [bundleFile:?]
	        at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:814) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.internal.framework.BundleContextImpl$2.run(BundleContextImpl.java:1) [org.eclipse.osgi-3.16.300.jar:?]
	        at java.security.AccessController.doPrivileged(Native Method) ~[?:?]
	        at org.eclipse.osgi.internal.framework.BundleContextImpl.startActivator(BundleContextImpl.java:806) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.internal.framework.BundleContextImpl.start(BundleContextImpl.java:763) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.internal.framework.EquinoxBundle.startWorker0(EquinoxBundle.java:1028) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.internal.framework.EquinoxBundle$EquinoxModule.startWorker(EquinoxBundle.java:371) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.container.Module.doStart(Module.java:605) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.container.Module.start(Module.java:468) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel$2.run(ModuleContainer.java:1849) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.internal.framework.EquinoxContainerAdaptor$1$1.execute(EquinoxContainerAdaptor.java:136) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1842) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.incStartLevel(ModuleContainer.java:1785) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.doContainerStartLevel(ModuleContainer.java:1747) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1669) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.container.ModuleContainer$ContainerStartLevel.dispatchEvent(ModuleContainer.java:1) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:234) [org.eclipse.osgi-3.16.300.jar:?]
	        at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:345) [org.eclipse.osgi-3.16.300.jar:?]
Caused by: shaded.org.eclipse.aether.resolution.ArtifactResolutionException: Error resolving artifact org.openhab.core.features.karaf:org.openhab.core.features.karaf.openhab-core:xml:features:3.3.0-SNAPSHOT
	at shaded.org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:413) ~[?:?]
	at shaded.org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolveArtifacts(DefaultArtifactResolver.java:215) ~[?:?]
	at shaded.org.eclipse.aether.internal.impl.DefaultArtifactResolver.resolveArtifact(DefaultArtifactResolver.java:192) ~[?:?]
	at shaded.org.eclipse.aether.internal.impl.DefaultRepositorySystem.resolveArtifact(DefaultRepositorySystem.java:247) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:767) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:657) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:598) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:565) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.AetherBasedResolver.resolve(AetherBasedResolver.java:555) ~[?:?]
	at org.ops4j.pax.url.mvn.internal.Connection.getInputStream(Connection.java:123) ~[?:?]
	at java.net.URL.openStream(URL.java:1165) ~[?:?]
	at org.apache.karaf.features.internal.service.RepositoryImpl.load(RepositoryImpl.java:114) ~[bundleFile:?]
	... 29 more
2022-01-20 22:34:30.116 [INFO ] [.core.internal.i18n.I18nProviderImpl] - Time zone set to 'xxx/yyy'.

Kind Regards,
Slawek

Thanks for testing, I have to investigate why it doesn’t work.

For some people the binding does not install at all, Zsolt has an forum entry about the error here: Config error? Unsupported 'Bundle-ManifestVersion' value: 1

@Slawomir_Ksiazek Your first message indicates that the binding could be installed, right? It just didn’t work :see_no_evil:

Could it be that It just doesn’t work on OH 3.2, but on OH 3.3 (still snapshot?) versions?

I have had a hard time to get the correct git revision for 3.2 tag, this seems to be strange set in OH. My next try will be to only use published libraries as dependencies and hopefully be more flexible with that.

For now this version doesn’t seem to work, I apology for that. It doesn’t make sense to try it out further with OH 3.2

Thanks for update, so will wait for correct version for OH 3.2, Anyway thanks for your time
Kind regards, Slawek