Broadlink binding for RMx, A1, SPx and MP. Any interest?

Found the answer:

Now I can run commands in writing and they work:
image

Edit:
From this stage all that’s left is just to add a button (not switch) in HabPanel for each command:

It was really hard for me to find all the required info to install this binding for OpenHab 2.5, my config is mainly based on PaperUI and HabPanel,
So here is a guide for the next ones which are looking for instructions:

  1. Download the latest version of the binding from here: Releases · themillhousegroup/openhab2-addons · GitHub
    All the thanks to @themillhousegroup of course.

  2. Place the .jar file you downloaded to \sys\addons\ this will create the broadlink binding, and will enable to add your broadlink device from Inbox (at paperUI), after it was connected to your wifi network with the IHC app.

  3. In PaperUI add map transformation add-on, PaperUI: Add-ons → Transformations → Map Transformation.

  4. Use broadlink manager to learn the IR codes of your remotes (Broadlink Manager download | SourceForge.net)

  5. Create an broadlink.map file at \conf\transform\ (if you have more than 1 broad link device you can create a separate .map file for each device, the syntax of the file is as follows:

AC_OFF = 2600BC026C741C1E1C591C1E1C5A1E581B5A1C5A1E571F1B1C5A1C1E1B5A1E581C591C5A1C591C1E1F571E1C1E571F1B1C1F1B1E1C1E1C1E1C591C1E1C5A1C1E1C1E1C1E1B1E74711E1C1C591C1E1C5A1E571F571C591C5A1C1E1C591C1E1C5A1B5A1F571C591C5A1C1E1C591F1B1C5A1D1D1B1E1C1F1B1E1C1E1C5A1C1E1C591C1E1C1E1C1E1C1E73711C1F1B5A1C1E1B5A1C5A1B5A1C5A1B5A1F1C1B5A1B1F1B5A1F571E571C5A1B5A1F1B1C5A1B1E1F571C1E1C1E1C1E1B1F1B1E1C5A1C1E1C591C1E1C1F1B1E1C1E73711C0008A073711F571C1E1C1E1C1E1B5A1E1C1C1E1C591F571C1E1C1E1C1E1B5A1E1C1C1E1C591C5A1D581E1C1C1F1B5A1D581E1C1C1E1C591E581D1D1C1E1C591E581D1D1C1E72721D581C1E1D1D1D1D1C591D1D1D1D1D581D591D1D1D1D1D1D1D581D1D1D1D1D581D591D581D1D1D1D1D581D591D1D1D1D1D581D591D1D1D1D1C591D581D1E1C1E72711D591E1C1E1C1E1C1D581D1D1E1C1E571E581D1D1E1C1D1C1E581E1C1E1C1E571C5A1E571C1F1D1C1E571C5A1E1C1E1C1D581C5A1B1F1E1C1E571B5A1C1E1E1C71731F00089F00012691163516111612151216111611161116111635161116121634161216111611161116111612151216111611163516111611161116121512161116351611163513141611163516111600028F131415121611161116111611161215121611161116111611161215351612161116111611161116111612151216111611161116111612151216111635153616111600051C0001239416351611161215121611161116111611163516111810163515121611161116111611161116121611161116351611161116121611161116111635163513381314161116351611160002911014161116121611161116111611161116121512161116111611161116121512161116111611161116111612161116111611161116121512161116111635161116000D05000000000000000000000000
AC_COOL_25 = 2600BC0271711E1C1C591C1E1E591D591A5A1C591C5A1C1E1C591C1E1C5A1C591C5A1E581B5A1C1E1C5A1E1C1B5A1C1E1C1E1C1E1C1E1C1E1C591C1E1C5A1E1C1B1F1B1F1B1E74711B1F1B5A1E1C1C591C5A1C591C5A1C5A1E1C1B5A1C1E1C591C5A1C591C5A1C591E1D1B5A1C1E1C591F1B1C1E1C1E1C1E1C1E1C591F1B1C5A1D1D1B1E1C1E1C1E73711D1D1C5A1C1E1B5A1D591D581E581D581D1D1D591D1D1D581D5A1D571D591D581D1D1D591B1E1D591D1D1D1D1D1D1D1D1D1D1D581D1D1D581C1F1C1E1C1D1E1C72721D00089E72731D581E1C1E1C1D1E1C591D1D1D1D1D591B5A1D1D1D1C1D1D1D591B1F1D1D1D581D591D581D1D1D1D1D581E581D1D1D1D1D581D591D1D1D1D1D581D591D1D1D1D72721D581D1D1D1D1D1D1D581D1E1C1D1D591D581D1D1D1D1D1D1D581C1E1D1D1D581E581D581C1E1D1D1D581E581D1D1D1D1E571C5A1D1D1D1D1D581D581C1E1E1C72721D591D1D1D1D1D1D1D581D1D1D1D1D581C5A1B1F1D1C1D1D1D591D1D1D1D1D581D581C5A1D1D1D1D1D581D591D1D1D1C1D591D581C1E1D1D1D591D581D1D1D1D72721D0008A0000125921635131514131437131414131414141314361513141314361315141314131414131315121513141314131437141314131513141215131413143714131437131414131437131415000290121415131413141315121611151314131413141314141412151314361513141314131413141315121513141314131413141315121513141314131437143714371400051E0001259214371314141314371314151314131413143616121413143714131414131315131413141314131413141314371413151215131413141314131437143714371314141314371413150002901214151215131413151214131414141215121513151214131413151314131413141314131413141315121513141314131413141414131412151314131437143615000D05000000000000000000000000

  1. In paperUI create a command Item for your broadlink Thing (if it wasn’t created allready)
    It should look similar to this:

  2. In HabPanel, create a button for each command you placed in broadlink.map:

Good luck!

1 Like

@themillhousegroup

  1. I just got my rm mini 3

  2. Installed the latest add on release

  3. I confirmed thht I can send commands using the python-broadlink instructions

  4. I followed the instructions by @Eli.Roz

  5. I get the same status error that others have shared; below are the error logs:

18:13:27.182 [INFO ] [smarthome.event.ItemStateChangedEvent] - BR_MiniSplit_Command changed from FAN_MODE to DRY_MODE
18:13:29.905 [ERROR] [.handler.BroadlinkRemoteModel4Handler] - rm4:24-df-a7-de-e9-ca[v]: Could not get status:
java.net.ProtocolException: Response from device is not valid. (0x22=0xFB,0x23=0xFF,0x24=0x00)
at org.openhab.binding.broadlink.internal.BroadlinkProtocol.decodePacket(BroadlinkProtocol.java:191) ~[bundleFile:?]
at org.openhab.binding.broadlink.handler.BroadlinkBaseThingHandler.decodeDevicePacket(BroadlinkBaseThingHandler.java:206) ~[bundleFile:?]
at org.openhab.binding.broadlink.handler.BroadlinkRemoteModel4Handler.getStatusFromDevice(BroadlinkRemoteModel4Handler.java:51) [bundleFile:?]
at org.openhab.binding.broadlink.handler.BroadlinkRemoteModel4Handler.onBroadlinkDeviceBecomingReachable(BroadlinkRemoteModel4Handler.java:37) [bundleFile:?]
at org.openhab.binding.broadlink.handler.BroadlinkBaseThingHandler.transitionToOnline(BroadlinkBaseThingHandler.java:297) [bundleFile:?]
at org.openhab.binding.broadlink.handler.BroadlinkBaseThingHandler.updateItemStatus(BroadlinkBaseThingHandler.java:245) [bundleFile:?]
at org.openhab.binding.broadlink.handler.BroadlinkBaseThingHandler$1.run(BroadlinkBaseThingHandler.java:109) [bundleFile:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_252]
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) [?:1.8.0_252]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) [?:1.8.0_252]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) [?:1.8.0_252]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_252]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_252]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_252]
18:13:29.908 [ERROR] [.handler.BroadlinkRemoteModel4Handler] - rm4:24-df-a7-de-e9-ca[v]: Device became reachable but had trouble getting status. Marking as offline …
18:13:29.908 [WARN ] [.handler.BroadlinkRemoteModel4Handler] - rm4:24-df-a7-de-e9-ca[v]: Online → Offline due to: Trouble getting status

good work it shuld be on the Openhab docs…

The Broadlink Manager doesn’t seem to support the RM4 Mini. However, I found that I could use the python scripts directly at https://github.com/mjg59/python-broadlink to get the codes. After you get a code, convert it to hex, then you can use it. For example:

>>> devices[0].enter_learning()
>>> tvpower = devices[0].check_data()
>>> tvpower.hex()
'260058000001289114121312133712131213121312131213123713371213123812371337133712381213121312121337131212131213121312371337133712131238123713371337120005220001294912000c5f0001284913000d050000000000000000000000000000'
1 Like

In case this helps anyone. I was able to get python-broadlink integrated to openhab via the exec command.
I ended documenting my work in github for reference:

3 Likes

RF codes do not work in Openhab 2.5.* with Broadlink RM Pro+. They do work properly on version 2.4. Should I modify codes? Maybe feature requires a fix?

I use Broadlink RM Pro+

Hi!

I update my openHAB to 2.5.7 and the Broadlink RM binding stopped working. I tried severel versions versions:
org.openhab.binding.broadlink-2.4.0-BETA-2.jar (worked fine with openHAB 2.1)
org.openhab.binding.broadlink-2.4.0-BETA-4.jar
org.openhab.binding.broadlink-2.4.0-BETA-17.jar
Is it possible, to openHAB 2.5.7 not supported?

Thanks!

I have RM3 mini. After installing org.openhab.binding.broadlink-2.5.1-SNAPSHOT (see previous posts to download) it works with with Openhab 2.5.7 on RPI3

Thanks, it works!

Hello All. I am trying to onboard my RM4. Everything seems to be connected ok and in the large part its working. I can get my Samsung to work using sitemaps - happy days.
What I would like to do now is learn the IR codes for my various devices and apply them into my broadlink map. The IR codes are not in the remotecontrol db. But learning the right code is proving to be difficult to me.

I am trying to sniff or learn codes but am getting results that I dont know how to work with. Although I have my Samsung working I will use it as evidence of my challenge.

If I look up the correct Pronto code (according to http://www.remotecentral.com/cgi-bin/codes/samsung/tv_functions/)
0000 006d 0022 0003 00a9 00a8 0015 003f 0015 003f 0015 003f 0015 0015 0015 0015 0015 0015 0015 0015 0015 0015 0015 003f 0015 003f 0015 003f 0015 0015 0015 0015 0015 0015 0015 0015 0015 0015 0015 0015 0015 003f 0015 0015 0015 0015 0015 0015 0015 0015 0015 0015 0015 0015 0015 0040 0015 0015 0015 003f 0015 003f 0015 003f 0015 003f 0015 003f 0015 003f 0015 0702 00a9 00a8 0015 0015 0015 0e6e
If I convert this into the required broadlink pulse I end up with the following - which works quite happily - The Openhab required code (transform map - “tv on”)
26004e00939312371237123712121212121212121212123712371237121212121212121212121212123712121212121212121212121212371212123712371237123712371237120005f89393123712000c560d050000000000000000

When I cant lookup the pronto code then I need to learn the IR code. If I pretended I didnt have the correct pronto code from the remotecontrol db and used the hexstream dumped from wireshark from listening to IOS broadlink app I get the following
450000f4d78d00004011205fc0a800b5c0a80007e3a4005000e082fe5aa5aa555aa5aa55000000000000000000000000000000000000000000000000ef180000bc626a00e1a5f661e8a7df240100000087cf0000a52ecc1f6fce93eaeb89361895b6b9731257ec8535067bea7cbd2d5339ff9a12b47c2fa5833916a3585d32a85f0d11056918a11662d43758b4e4477d2f3d962c6a994f48604a9a083ccb24d90e079b929b47eb315676b5d07083e4d158ff58cfd604b9b632cceabac8b835c247792cea9672138059e1f2066a69ab0b1ef4e6d0ea30efeb7d0b8ec09c5de829b5fc8b25a7ce519ecd8f9e0b0637dec85d3570a3 - which has no similarities to the previous 2.

Further if I go to homebridge and try to learn by using the homebridge Broadlink Rm Pro plugin I get
2600d200909315351237143512121312131213121411123712371237121312131213121312131213123712131213121312131213121213361312133613361336133613361336130005f4929312371336123712131213121312131213123712371237131212131213121312131212133712121312131212131213121312371213123712371237133612371237120005f591931337123712371212131213121213121312371237123712131213121312131213121312371213121312131212131213121336121312371237123712371237133612000d0500000000

nothing like any of the previous 3!

I assume therefore I must be on the wrong track. Can anyone help me to arrive at what I should be doing instead please?

thank you but I’ve already problems with the simple connection.
I’ve always the error “OFFLINE - COMMUNICATION_ERROR Couldn’t authenticate”

OpenHab 2.5.6 and 2.5.1.202005300729 Broadlink Binding (beta 11?)
no more configuration on my RM4pro or router to block internet access.

I’ve configured only static IP and MAC …

Try this: Broadlink binding for RMx, A1, SPx and MP. Any interest?
Maybe you have the issue mentioned there, with the RM4 being connected to the cloud.

I’m trying to add a new RM4 Pro, but I’m getting the error “Device identifying itself as ‘24614’ is not currently supported. Please report this to the developer!”. This is device type 0x6026, which was successfully discovered by the python-broadlink tools. Can this new device type be added to this binding please?

I second that with a RM4… did anyone get it to work with RM4mini and can provide assistance?

thanks, I haven’t tried yet but I’ve a (simple) idea: can I configure static IP to the RM?
If yes, can I configure a wrong gateway IP : in this case RM can not connect to the cloud…

It’s very recommended to configure a static IP to the RM, but it’s done in your router config page, not in the RM itself.

Thanks for your summary

Please correct me i am wrong

We should just care to not register the device through the application. That’s all?

So, is it possible to get the rm4 online with the latest build

Can you successfully send RF through the rm4?

My rm pro just got broken, and I am using actively this binding for ir and RF

I am hesitating to order the old or the new one…

Thanks in advance

I have an RM4C Mini, which does not have RF, so I can’t confirm. The main point is: do not let the device communicate with the cloud - allow it to connect to your local WiFi, and then stop the setup procedure completely!

1 Like

Guys, u can use this app to easily learn ir and rf codes… enjoy…