beckyricha / Broadlink-RM-SmartThings-Alexa

Control RF and Ir devices using SmartThings and Alexa.
151 stars 115 forks source link

Becky :) I need your help: Stuck in connecting Smartthing with RMBridge. #27

Open Golden85 opened 7 years ago

Golden85 commented 7 years ago

Hi Becky,

I do need your help as I spent hours but can not find why. I) Method: RM Bridge Cloud II) Add some devices to control:

Name MAC Address URL
Bed aircon off b4:43:0d:f9:28:35 http://192.168.1.104:7474/code/Bed aircon off test delete Bed aircon on b4:43:0d:f9:28:35 http://192.168.1.104:7474/code/Bed aircon on test delete

Run the link outside is OK => showed like that:

"code 0 msg "rm2 send data success"

III) Install this app into SmartThings:

I stuck there: Used: RM Bridge Switch Cloud Changed only in line 74 for the add:

def params = [ uri: "http://192.168.1.104:7474/code/$replaced%20$toggle"

And I created a Device name:

Display Name Type Location Hub Zigbee Id Device Network Id Status Last Activity Bed aircon RM Bridge Switch Cloud CT3C Bed aircon ACTIVE 17 minutes ag

But fail to run in mobile app: The icon is changed from on to off, change colour, but the device doesn't respond.

I run simulation, the result show that:

1ad28461-6feb-4371-a369-b038d94a1310 22:15:21: error org.apache.http.conn.ConnectTimeoutException: Connect to 192.168.1.104:7474 [/192.168.1.104] failed: connect timed out @ line 73

=> I don't know what's the issues. I tryed to remove and install around 5 times, but the results are the same.

Please give me few minutes and give me some clue to solve that.

Thanks you very much indeed.

beckyricha commented 7 years ago

Thank you for providing so much detail. It appears that you are attempting to use a local ip address with the cloud version of the code. You must use an externally accessible ip address with this version.  The lan version does not require this but does require you to have a smart things hub.  Your externally accessible ip will not begin with 192.  To find your address you can go to whatsmyip.com, from the same network where you are running the rm bridge device, and use the address it shows you for testing. However, once that works you should check out a service that can give you a permanent ip address. Many are free. You can search the web for avdynamic dns service. The one i use is called no-ip.com and have had no trouble with them. They all have setup instructions on their sites.BeckyOn Apr 28, 2017 11:36 AM, Golden85 notifications@github.com wrote:Hi Becky, I do need your help as I spent hours but can not find why. I) Method: RM Bridge Cloud II) Add some devices to control: Name MAC Address URL Bed aircon off b4:43:0d:f9:28:35 http://192.168.1.104:7474/code/Bed aircon off test delete Bed aircon on b4:43:0d:f9:28:35 http://192.168.1.104:7474/code/Bed aircon on test delete Run the link outside is OK => showed like that: "code 0 msg "rm2 send data success" III) Install this app into SmartThings: I stuck there: Used: RM Bridge Switch Cloud Changed only in line 74 for the add: def params = [ uri: "http://192.168.1.104:7474/code/$replaced%20$toggle" And I created a Device name: Display Name Type Location Hub Zigbee Id Device Network Id Status Last Activity Bed aircon RM Bridge Switch Cloud CT3C Bed aircon ACTIVE 17 minutes ag But fail to run in mobile app: The icon is changed from on to off, change colour, but the device doesn't respond. I run simulation, the result show that: 1ad28461-6feb-4371-a369-b038d94a1310 22:15:21: error org.apache.http.conn.ConnectTimeoutException: Connect to 192.168.1.104:7474 [/192.168.1.104] failed: connect timed out @ line 73 => I don't know what's the issues. I tryed to remove and install around 5 times, but the results are the same. Please give me few minutes and give me some clue to solve that. Thanks you very much indeed.

—You are receiving this because you are subscribed to this thread.Reply to this email directly, view it on GitHub, or mute the thread.

Golden85 commented 7 years ago

Dear Becky

Thank you very much indeed.

Golden85 commented 7 years ago

Dear Becky

I need your support again :) (As I have very limited understanding on IP an address) For example:

I checked out my public IP as below: 183.81.##.## Your public IP address

I registered a Dynamic DNS and get an add like that: name##.ddns.net

I double checked the Dynamic DNS, it show the same public IP add as 183.81.##.## But when put it in the code in Smartthing, it shown error:

a021b131-74e1-4fbd-9d57-3b575868e5e9 16:27:32: error org.apache.http.conn.ConnectTimeoutException: Connect to name##.ddns.net:7474 [name##.ddns.net/183.81.##.##] failed: connect timed out @ line 73

I created some testing case, for ex: in RM Bridge Address, I tested successfully this code: http://192.168.1.113:7474/code/Samsung TV off

result: code 0 msg "rm2 send data success"

So I try to put the direct command: 183.81.##.##:7474/code/Samsung TV off but it did not run => It shown: The server at 183.81.##.## is taking too long to respond.

I check and tried to open the Modem port on 7474 port, with IP add of the cellphone that I run "RM Bridge", but the result was not changed.

=> So how can I do next?

So sorry for querry a lot indeed, I'm very excited with something new on technology. But this time, I don't have much experience on the Ip and network add.

beckyricha commented 7 years ago

I think you are close.  Make sure in your router that you forward port 7474 to the device running rm bridge.  Unfortunately the procedures for doing this vary with router model. I could help with a couple of models but a search online for your specific router should give you detailed instructions for this.  After you get this working, you should also make sure that the rm bridge device has a static ip address. Fit a lot of router serious, you can just set the static ip address on the rm bridge device using its Android settings and have no issues, but for some routers your may need to do this and take other steps as well. Most important is the port forwarding in the first paragraph. The static ip on the rm bridge device is only to make sure it stays working over the long term. Without this the router could reassign the bridge IP address to something different in the future and mess up a working system.Please let me know if this fixes it.BeckyOn May 2, 2017 5:44 AM, Golden85 notifications@github.com wrote:Dear Becky I need your support again :) (As I have very limited understanding on IP an address) For example: I checked out my public IP as below: 183.81.##.## Your public IP address I registered a Dynamic DNS and get an add like that: name##.ddns.net I double checked the Dynamic DNS, it show the same public IP add as 183.81.##.## But when put it in the code in Smartthing, it shown error: a021b131-74e1-4fbd-9d57-3b575868e5e9 16:27:32: error org.apache.http.conn.ConnectTimeoutException: Connect to name##.ddns.net:7474 [name##.ddns.net/183.81.##.##] failed: connect timed out @ line 73 I created some testing case, for ex: in RM Bridge Address, I tested successfully this code: http://192.168.1.113:7474/code/Samsung TV off result: code 0 msg "rm2 send data success" So I try to put the direct command: 183.81.##.##:7474/code/Samsung TV off but it is not run: The server at 183.81.##.## is taking too long to respond. I check and tried to open the Modem port on 7474 port, with IP add of the cellphone that I run "RM Bridge", but the result was not changed. => So how can I do next? So sorry for querry a lot indeed, I'm very excited with something new on technology. But this time, I don't have much experience on the Ip and network add.

—You are receiving this because you commented.Reply to this email directly, view it on GitHub, or mute the thread.

Golden85 commented 7 years ago

Dear Becky

Thank you very much indeed for your support. But I think I might face with hardware issue or something like that.

But seem that when I try to connect from dynamic DNS or even direct public IP add to the port 7474, it was failed.

I used some tools in internet to check open port 7474 in my public IP add/dynamic DNS, but it showed that the port was closed.

I think that I have to stop this issue at this step :(

Thank you very much indeed for your support until now :)