Page 1 of 1

BroadLink RM2/RM Bridge Plugin

PostPosted: Sun Dec 20, 2015 5:04 pm
by Dava
Hello All,

I have managed to hack support for the RM Bridge available here http://rm-bridge.fun2code.de/ using the LIRC plugin as a base. My python is rusty and I did not fully understand how the LIRC plugin worked so there is lots of superfluous code still in there, but it works. Just drop the folder in the ZIP to the plugins folder. I would suggest testing the bridge functionality using the Web based UI here before configuring the plugin. http://rm-bridge.fun2code.de/rm_manage/index.html

It supports learning new IR and 433MHz code shortcuts and sending these through the Bridge to the RM2. My bridge has been up for over a week now using a cheap Android TV box so it would seem to be a reliable, if not slightly a convoluted way of using the RM2. An old phone would probably work too if left on charge.

Unfortunately, you do need an Android device on the network, running RM bridge as Broadlink have no support for Windows direct sending.

Happy Christmas!

Re: BroadLink RM2/RM Bridge Plugin

PostPosted: Sun Dec 20, 2015 8:28 pm
by kalinkamaen
Thank you Dava. Looking forward to try this. Having a wireless IR is really good :)

Re: BroadLink RM2/RM Bridge Plugin

PostPosted: Tue May 03, 2016 11:49 am
by kalinkamaen
Hello sir. I really need help with your plugin!!

I have managed to send ir signals through this web page, but not with your plugin!

http://rm-bridge.fun2code.de/rm_manage/ ... rning.html

Image

Re: BroadLink RM2/RM Bridge Plugin

PostPosted: Sun Sep 04, 2016 8:35 am
by kalinkamaen
Sorry to bump this, but i really want this to work!

Re: BroadLink RM2/RM Bridge Plugin

PostPosted: Sun Sep 04, 2016 11:18 am
by jonib
kalinkamaen wrote:Sorry to bump this, but i really want this to work!
I don't know if this will fix the plugin, but it should fix this error:

Put this:
Code: Select all
            stat = ""
on line 608 (right before "for t in range(1, retries + 1):") so it looks like this:
Code: Select all
            #print BridgeURL + str(retries)
            stat = ""
            for t in range(1, retries + 1):


jonib

Re: BroadLink RM2/RM Bridge Plugin

PostPosted: Sun Sep 04, 2016 8:02 pm
by kalinkamaen
Thank you for your suggestion. Here is the error i get when trying to send:

Code: Select all
RM Bridge: Send Command: HK power ON
   RM Bridge connection failed to http://192.168.10.192:7474
   Error in Action: "RM Bridge: Send Command: HK power ON"
   Traceback (most recent call last) (1722):
     File "C:\EventGhost\eg\Classes\ActionBase.py", line 170, in CallWrapper
       return self(*args)
     File "C:\EventGhost\plugins\RMBridge\__init__.py", line 623, in __call__
       self.PrintError ( "RM Bridge: " + stat + " - Retry: " + str(t) + "of" + retries)
   TypeError: cannot concatenate 'str' and 'int' objects

Re: BroadLink RM2/RM Bridge Plugin

PostPosted: Sun Sep 04, 2016 8:14 pm
by jonib
kalinkamaen wrote:Thank you for your suggestion. Here is the error i get when trying to send:

Change line 623 from:
Code: Select all
self.PrintError ( "RM Bridge: " + stat + " - Retry: " + str(t) + "of" + retries)
to:
Code: Select all
self.PrintError ( "RM Bridge: " + stat + " - Retry: " + str(t) + "of" + str(retries))

I suspect these fixes will just fix the symptom and not the cause, as the problem seems to be it can't connect.

I have not tested the plugin and I'm not interested in it, so I can only fix simple Python errors.

jonib

Re: BroadLink RM2/RM Bridge Plugin

PostPosted: Sun Sep 04, 2016 9:18 pm
by kalinkamaen
WOW I found my issue with this plugin.

The problem is the name I used for my send command. My send command name was: HK power ON
As I understand you are not allowed to have space in the command name. When I used: HKpowerON instead
there is no error and command is sent!

Finaly, it works lika a champ. Thank you for this nice plugin :)

Re: BroadLink RM2/RM Bridge Plugin

PostPosted: Tue Dec 06, 2016 2:31 pm
by Dava
Sorry,

I have only just looked back at this as it seems I was not getting notification on topic updates. I think it is an RM-bridge limitation to have names with no spaces, but I am not sure. Glad you got it working.

I have just found some Python examples of how to communicate directly with the RM2 and their new little IR only device, the RM Mini:

http://www.banggood.com/Broadlink-Black ... mds=search

£10 for a Wifi IR blaster in a nice package has to worth a shot!!


I have ordered the mini for testing and plan to wite a direct from EG/Python plugin to handle them both without the Android bridge in the middle. The Android bridge is great and has allowed me to communicate from EG but there are sometimes some latency issues which I suspect are due to the bridge.... And it is another point of failure, so I hope the direct approach will make things even better.

I will update this thread as and when I make something.

Re: BroadLink RM2/RM Bridge Plugin

PostPosted: Sun Dec 11, 2016 10:21 pm
by kalinkamaen
Thankyou so much. I am looking forward to a direct connection to Broadlink. Then i do not need my android phone anymore ;) hehe

I allready have a mini working on your plugin. Read here:

http://fun2code-blog.blogspot.no/2016/0 ... round.html

Re: BroadLink RM2/RM Bridge Plugin

PostPosted: Sat Jan 28, 2017 8:42 pm
by kalinkamaen
https://github.com/mjg59/python-broadlink

This is not for EG, just wanted to put it on here, if someone wanted to convert it for working with Eventghost!