smartthings-mqtt-bridge icon indicating copy to clipboard operation
smartthings-mqtt-bridge copied to clipboard

Getting unexpected error in smart app

Open ScottChapman opened this issue 7 years ago • 6 comments

OK, I think I got everything installed and running on my raspberry pi. The app says it is listening on port http://localhost:8080

So, in the device I enter the IP address of my PI, port 8080, and the HW MAC address of wlan0

But when I run the smart app, select one of my switches, and the MQTT Bridge device I just get "Unexpected error" in the smart app.

Any ideas?

ScottChapman avatar Jun 01 '17 00:06 ScottChapman

tldr: If you're using a wired connection, try using your wireless connection instead?

I just had this issue and was able to figure it out. Are you by chance using both a wired and wireless connection on the Raspberry Pi, or maybe just a wired connection?

I was having this same issue with the app and the service was starting and listing just like yours. I noticed it was saying localhost and with my pi I'm using both a wired and wireless connection (my home network is overly complex). I wanted to tell this bridge to listen on a specific IP address/interface but couldn't find a way to do that. I figured maybe instead of using my wired pi IP and MAC which is on the same subnet as my SmartThings hub, I'd try to use the IP and MAC from my pi's wireless connection which connects to another subnet on my network (i told you it's overly complex :). *I allow traffic from these two subnets to talk to each other on my firewall). To my surprise, once I configured the smarthings bridge device to use my pi's wireless IP address and MAC address for that interface, it started working. Doesn't make sense to me but hey, it's working now :)

xtreme22886 avatar Jun 19 '17 03:06 xtreme22886

I am also having this issue

@ScottChapman did you figure this out? @stjohnjohnson just flagging if you have any suggestions

wkethman avatar Apr 22 '18 17:04 wkethman

Do you have any logs from the SmartThings console? Either for the device or smart app?

stjohnjohnson avatar Apr 22 '18 22:04 stjohnjohnson

Interestingly enough, I was getting the same issue. The way I solved the issue was watching the Live logging for the device. After doing so, I noticed the log stated its Device Network ID.

image

In the App, I did not close out, I left the error open and then in the SmartThings IDE, I copied the Device Network ID from the logs, and then I edited the Device I created in the "My Devices Tab"

When I created the device I had created the device with a network ID as 999, I did not create it empty. This may have been the cause. Once I replaced the network ID, all was right with the world. Hope this helps @wkethman @ScottChapman

image

jfeulner avatar Apr 27 '18 22:04 jfeulner

I found this issue occurred for me as well.

While trying to save in the SmartApp, it was spinning when I clicked Save and I eventually got the "Sorry, but there was an unexpected error". I believe there was an "Error saving page" as well. Any case I noticed the smartapp listed on my mqtt bridge device settings.

It was just kinda sitting there until, through the Web UI, "My Location" -> smartapps (under Installed SmartApps) -> Other -> MQTT Bridge (dev) -> click update

My MQTT Bridge device "Device Network ID" was my arbitrary entry, until I clicked the "update" button, it changed the mac address ID of my bridge container on port 8080.

After that all the communication started to occur.

kenthua avatar Jun 26 '18 05:06 kenthua

@jfeulner Thank you! This worked for me.

profesaurus avatar Jul 03 '18 21:07 profesaurus