I’ve setup the python-broadlink scripts, and I’ve managed to toggle my IR light using the RM4C Mini that I have.
So it looks like it can be connected to, and we can use it to control IR devices.
I tried using the binding again (BETA_05), but I get the same result as in post #1116. Is it anything to do with the second screenshot in that post, where the id and key show as empty, despite definitely having entered the key and vector?
The key and iv are correctly stored in configuration. But properties has empty id and key parameters. What should the id and key parameters in properties store?
Does everyone know the better way to learn RD command? I have some single hand control for garage door and it’s working but for some motor that use RF433,92 it’s not working. I have tried many option and no one is able to learn buttons for this blinds motor… From econtrol and IHC it’s able to sweap the frequency, but not leanirng the button itself…
Appreciate the effort on this. Unfortunately this snapshot doesn’t seem to fix whatever the issue is. The empty id and key parameters still exist (if that is indeed the issue), and the thing still complains of a communication_error.
10:54:53.901 [INFO ] [l.discovery.BroadlinkDiscoveryService] - BroadlinkDiscoveryService - Constructed
10:55:23.616 [WARN ] [l.discovery.BroadlinkDiscoveryService] - BroadlinkDiscoveryService - Beginning Broadlink device scan...
10:55:23.647 [WARN ] [.internal.discovery.DiscoveryProtocol] - Beginning async Broadlink device scan; will wait 10000 ms for responses
10:55:23.698 [WARN ] [.internal.discovery.DiscoveryProtocol] - Broadlink device scan waiting for 10000 ms to complete ...
10:55:23.911 [INFO ] [l.discovery.BroadlinkDiscoveryService] - Data received during Broadlink device discovery: from 192.168.1.117:80 [24:df:a7:4f:7c:e6]
10:55:23.917 [DEBUG] [l.discovery.BroadlinkDiscoveryService] - Adding new Broadlink device on 192.168.1.117 with mac '24:df:a7:4f:7c:e6' to Smarthome inbox
10:55:23.923 [DEBUG] [l.discovery.BroadlinkDiscoveryService] - Device 'broadlink:rm4:24-df-a7-4f-7c-e6' discovered at '192.168.1.117'.
10:55:23.934 [INFO ] [ig.discovery.internal.PersistentInbox] - Added new thing 'broadlink:rm4:24-df-a7-4f-7c-e6' to inbox.
10:55:30.593 [DEBUG] [link.internal.BroadlinkHandlerFactory] - Creating Thing handler for 'broadlink:rm4'
10:55:30.600 [DEBUG] [link.internal.BroadlinkHandlerFactory] - RM 4 handler requested created
10:55:33.708 [WARN ] [.internal.discovery.DiscoveryProtocol] - Device scan: wait complete ...
10:55:33.713 [WARN ] [.internal.discovery.DiscoveryProtocol] - Ended Broadlink device scan...
10:55:33.719 [INFO ] [dlink.internal.socket.BroadlinkSocket] - Socket closed
10:55:33.725 [INFO ] [l.discovery.BroadlinkDiscoveryService] - Discovery complete. Found 1 Broadlink devices
10:55:33.725 [INFO ] [dlink.internal.socket.BroadlinkSocket] - Receiver thread ended
10:55:47.265 [DEBUG] [.handler.BroadlinkRemoteModel4Handler] - rm4:24-df-a7-4f-7c-e6[?]: initializing
10:55:47.319 [DEBUG] [.handler.BroadlinkRemoteModel4Handler] - rm4:24-df-a7-4f-7c-e6[?]: initialization complete. Updating status.
10:55:48.340 [DEBUG] [.handler.BroadlinkRemoteModel4Handler] - rm4:24-df-a7-4f-7c-e6[?]: We've never actually successfully authenticated with this device in this session. Doing so now
10:55:48.348 [DEBUG] [.handler.BroadlinkRemoteModel4Handler] - rm4:24-df-a7-4f-7c-e6[?]: Authenticating with packet count = 30707
10:55:48.359 [ERROR] [.handler.BroadlinkRemoteModel4Handler] - rm4:24-df-a7-4f-7c-e6[?]: Authentication failed: Empty key
10:55:48.367 [ERROR] [.handler.BroadlinkRemoteModel4Handler] - rm4:24-df-a7-4f-7c-e6[?]: Attempting to authenticate prior to getting device status FAILED. Will mark as offline
10:55:48.373 [ERROR] [.handler.BroadlinkRemoteModel4Handler] - rm4:24-df-a7-4f-7c-e6[?]: updateItemStatus: Online -> Offline
I’ll certainly continue to help test snapshots. For now I’ve got something working with python_broadlink and broadlink_mqtt as per:
Hello,
I had everything up and running with Openhab 2.4.0, but now I wanted to upgrade.
I installed Openhab 2.5.4 in docker and used the BETA7 of “org.openhab.binding.broadlink-2.5.1-SNAPSHOT.jar”.
But in PaperUI after entering the Key and Vector, the thing always shows:
Status: OFFLINE - COMMUNICATION_ERROR Could not find device at IP address 192.168.178.54
But I see in my router that the RM Pro is available at this IP.
What am I missing?
This is the openhab.log
2020-05-11 16:56:19.615 [ERROR] [handler.BroadlinkRemoteModel2Handler] - rm2:78-0f-77-63-6a-01[v]: Attempting to authenticate prior to getting device status FAILED. Will mark as offline
2020-05-11 16:56:19.618 [ERROR] [handler.BroadlinkRemoteModel2Handler] - rm2:78-0f-77-63-6a-01[v]: updateItemStatus: Online -> Offline
edit:
Nevermind; after restarting the container, the thing is online
Hello everyone,
I’ve read as much as possible all the replies of this post and I hope I’ve not missed the answer to my question.
I’ve a R4 Mini.
With the help of the python script found here, with a little bit of modifications, I’ve successfully configured the WiFi on the device and got the values that I need to put in the config part of your addon.
So I’ve installed the addon on my OpenHAB server, manually configured the Thing object (manually because my server and my wifi are on different subnets) and finally I got these output on the OpenHAB log:
2020-05-19 18:39:10.309 [me.event.ThingUpdatedEvent] - Thing 'broadlink:rm4:e2ffe131' has been updated.
2020-05-19 18:39:10.333 [ERROR] [handler.BroadlinkRemoteModel4Handler] - rm4:e2ffe131[v]: Could not get status: Response from device is not valid. (0x22=0xFB,0x23=0xFF,0x24=0xBC)
2020-05-19 18:39:10.333 [ERROR] [handler.BroadlinkRemoteModel4Handler] - rm4:e2ffe131[v]: Device became reachable but had trouble getting status. Marking as offline ...
2020-05-19 18:39:10.333 [ERROR] [handler.BroadlinkRemoteModel4Handler] - rm4:e2ffe131[v]: updateItemStatus: Online -> Offline
In addition, I’ve the same issue of @hafniumzinc: although I entered the IV and Key on the configuration section, when I click on Show Properties the values are empty
Well I installed the new Beta 8 and now see the following:
Any thoughts?
2020-05-20 01:09:09.993 [INFO ] [g.discovery.internal.PersistentInbox] - Added new thing 'broadlink:rm3:78-0f-77-1a-13-38' to inbox.
2020-05-20 01:09:19.870 [ERROR] [core.thing.internal.ThingManagerImpl] - Exception occurred while calling thing handler factory 'org.openhab.binding.broadlink.internal.BroadlinkHandlerFactory@7327d42a': hexString needs to have an even length:
java.lang.IllegalArgumentException: hexString needs to have an even length:
at org.eclipse.smarthome.core.util.HexUtils.hexToBytes(HexUtils.java:105) ~[bundleFile:?]
at org.eclipse.smarthome.core.util.HexUtils.hexToBytes(HexUtils.java:119) ~[bundleFile:?]
at org.openhab.binding.broadlink.handler.BroadlinkBaseThingHandler.<init>(BroadlinkBaseThingHandler.java:69) ~[?:?]
at org.openhab.binding.broadlink.handler.BroadlinkRemoteHandler.<init>(BroadlinkRemoteHandler.java:46) ~[?:?]
at org.openhab.binding.broadlink.internal.BroadlinkHandlerFactory.createHandler(BroadlinkHandlerFactory.java:56) ~[?:?]
at org.eclipse.smarthome.core.thing.binding.BaseThingHandlerFactory.registerHandler(BaseThingHandlerFactory.java:126) ~[bundleFile:?]
at org.eclipse.smarthome.core.thing.internal.ThingManagerImpl.doRegisterHandler(ThingManagerImpl.java:587) [bundleFile:?]
at org.eclipse.smarthome.core.thing.internal.ThingManagerImpl.registerHandler(ThingManagerImpl.java:564) [bundleFile:?]
at org.eclipse.smarthome.core.thing.internal.ThingManagerImpl.registerAndInitializeHandler(ThingManagerImpl.java:1056) [bundleFile:?]
at org.eclipse.smarthome.core.thing.internal.ThingManagerImpl.thingAdded(ThingManagerImpl.java:445) [bundleFile:?]
at org.eclipse.smarthome.core.thing.internal.ThingRegistryImpl.notifyTrackers(ThingRegistryImpl.java:211) [bundleFile:?]
at org.eclipse.smarthome.core.thing.internal.ThingRegistryImpl.notifyListenersAboutAddedElement(ThingRegistryImpl.java:131) [bundleFile:?]
at org.eclipse.smarthome.core.thing.internal.ThingRegistryImpl.notifyListenersAboutAddedElement(ThingRegistryImpl.java:1) [bundleFile:?]
at org.eclipse.smarthome.core.common.registry.AbstractRegistry.added(AbstractRegistry.java:157) [bundleFile:?]
at org.eclipse.smarthome.core.common.registry.AbstractRegistry.added(AbstractRegistry.java:1) [bundleFile:?]
at org.eclipse.smarthome.core.common.registry.AbstractProvider.notifyListeners(AbstractProvider.java:56) [bundleFile:?]
at org.eclipse.smarthome.core.common.registry.AbstractProvider.notifyListeners(AbstractProvider.java:75) [bundleFile:?]
at org.eclipse.smarthome.core.common.registry.AbstractProvider.notifyListenersAboutAddedElement(AbstractProvider.java:79) [bundleFile:?]
at org.eclipse.smarthome.core.common.registry.AbstractManagedProvider.add(AbstractManagedProvider.java:64) [bundleFile:?]
at org.eclipse.smarthome.core.common.registry.AbstractRegistry.add(AbstractRegistry.java:325) [bundleFile:?]
at org.eclipse.smarthome.config.discovery.internal.PersistentInbox.addThingSafely(PersistentInbox.java:630) [bundleFile:?]
at org.eclipse.smarthome.config.discovery.internal.PersistentInbox.approve(PersistentInbox.java:203) [bundleFile:?]
at org.eclipse.smarthome.io.rest.core.internal.discovery.InboxResource.approve(InboxResource.java:104) [bundleFile:?]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_181]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_181]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_181]
at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_181]
at org.glassfish.jersey.server.model.internal.ResourceMethodInvocationHandlerFactory$1.invoke(ResourceMethodInvocationHandlerFactory.java:81) [bundleFile:?]
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher$1.run(AbstractJavaResourceMethodDispatcher.java:144) [bundleFile:?]
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.invoke(AbstractJavaResourceMethodDispatcher.java:161) [bundleFile:?]
at org.glassfish.jersey.server.model.internal.JavaResourceMethodDispatcherProvider$ResponseOutInvoker.doDispatch(JavaResourceMethodDispatcherProvider.java:160) [bundleFile:?]
at org.glassfish.jersey.server.model.internal.AbstractJavaResourceMethodDispatcher.dispatch(AbstractJavaResourceMethodDispatcher.java:99) [bundleFile:?]
at org.glassfish.jersey.server.model.ResourceMethodInvoker.invoke(ResourceMethodInvoker.java:389) [bundleFile:?]
at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:347) [bundleFile:?]
at org.glassfish.jersey.server.model.ResourceMethodInvoker.apply(ResourceMethodInvoker.java:102) [bundleFile:?]
at org.glassfish.jersey.server.ServerRuntime$2.run(ServerRuntime.java:326) [bundleFile:?]
at org.glassfish.jersey.internal.Errors$1.call(Errors.java:271) [bundleFile:?]
at org.glassfish.jersey.internal.Errors$1.call(Errors.java:267) [bundleFile:?]
at org.glassfish.jersey.internal.Errors.process(Errors.java:315) [bundleFile:?]
at org.glassfish.jersey.internal.Errors.process(Errors.java:297) [bundleFile:?]
at org.glassfish.jersey.internal.Errors.process(Errors.java:267) [bundleFile:?]
at org.glassfish.jersey.process.internal.RequestScope.runInScope(RequestScope.java:317) [bundleFile:?]
at org.glassfish.jersey.server.ServerRuntime.process(ServerRuntime.java:305) [bundleFile:?]
at org.glassfish.jersey.server.ApplicationHandler.handle(ApplicationHandler.java:1154) [bundleFile:?]
at org.glassfish.jersey.servlet.WebComponent.serviceImpl(WebComponent.java:473) [bundleFile:?]
at org.glassfish.jersey.servlet.WebComponent.service(WebComponent.java:427) [bundleFile:?]
at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:388) [bundleFile:?]
at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:341) [bundleFile:?]
at org.glassfish.jersey.servlet.ServletContainer.service(ServletContainer.java:228) [bundleFile:?]
at com.eclipsesource.jaxrs.publisher.internal.ServletContainerBridge.service(ServletContainerBridge.java:76) [bundleFile:?]
at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:852) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:544) [bundleFile:9.4.20.v20190813]
at org.ops4j.pax.web.service.jetty.internal.HttpServiceServletHandler.doHandle(HttpServiceServletHandler.java:71) [bundleFile:?]
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:143) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:536) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:235) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:1581) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ScopedHandler.nextHandle(ScopedHandler.java:233) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1307) [bundleFile:9.4.20.v20190813]
at org.ops4j.pax.web.service.jetty.internal.HttpServiceContext.doHandle(HttpServiceContext.java:293) [bundleFile:?]
at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:188) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:482) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:1549) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ScopedHandler.nextScope(ScopedHandler.java:186) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1204) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:141) [bundleFile:9.4.20.v20190813]
at org.ops4j.pax.web.service.jetty.internal.JettyServerHandlerCollection.handle(JettyServerHandlerCollection.java:80) [bundleFile:?]
at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:127) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.Server.handle(Server.java:494) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.HttpChannel.handle(HttpChannel.java:374) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.server.HttpConnection.onFillable(HttpConnection.java:268) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.io.AbstractConnection$ReadCallback.succeeded(AbstractConnection.java:311) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.io.FillInterest.fillable(FillInterest.java:103) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.io.ChannelEndPoint$2.run(ChannelEndPoint.java:117) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.runTask(EatWhatYouKill.java:336) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.doProduce(EatWhatYouKill.java:313) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.tryProduce(EatWhatYouKill.java:171) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.strategy.EatWhatYouKill.run(EatWhatYouKill.java:129) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.ReservedThreadExecutor$ReservedThread.run(ReservedThreadExecutor.java:367) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:782) [bundleFile:9.4.20.v20190813]
at org.eclipse.jetty.util.thread.QueuedThreadPool$Runner.run(QueuedThreadPool.java:918) [bundleFile:9.4.20.v20190813]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_181]
There are some major internal changes in this one, but first, the features:
No longer using device properties to store the device key
This was the cause of the problems with <empty> and devices not authenticating/coming on line
Devices should reliably get discovered and authenticate every time now
Cleaned up device status
devices that are not found don’t show COMMUNICATION_ERROR now, they just go OFFLINE
By contrast, devices that are in an unhappy state will have additional info about why they are offline
Improved error logging
stack traces of exceptions were being swallowed in logs, making it hard to diagnose reported issues
Support for the SP2/SP3 nightlight feature
someone who has one of these devices, please confirm that it works!
I only have an SP mini 3, which (as it turns out) doesn’t have nightlight support
As mentioned, there have been some major internal changes in this release, which means it will require a full removal of all your Broadlink devices in order to work properly. I’m really sorry about that, but my experience of the last week developing this new version has shown me that it is not reliably backwards-compatible. So, the upgrade process should be:
Delete each of your Broadlink Things using Paper UI
(Some of them might need to be force-deleted if they weren’t already online)
Once your system is “quiet” again (watch the logs) remove the old Broadlink .jar from your addons
Restart your openHAB instance (I did openhab-cli stop followed by openhab-cli start)
Once your openHAB system has restarted, copy the new Broadlink JAR into your addons directory
Run a thing discovery for Broadlink devices from PaperUI
Set up your Broadlink things using the key and IV a few replies above this one
Again, apologies for the nuisance of having to go through all of the above steps, but multiple times I have seen issues because for some reason openHAB was holding onto “old versions” of Things. This is especially applicable for people with SP2/SP3 devices wanting to use the nightlight feature - you simply won’t see the Nightlight On/Off channel under your Thing unless you do these steps.
Cheers, best of luck and as always, let me know how it goes.