BobRak / OpenHAB-Smartthings

53 stars 54 forks source link

Discovery Not Working #2

Closed bradleonard closed 7 years ago

bradleonard commented 7 years ago

Hello

Thanks for this integration!

I haven't seen it work yet, but it seems promising.

I am stuck at the discovery step to add the binding.

When I click "Search for Things" nothing appears. All other steps in the "SmartthingsInstallation.md" file went just as described.

Do I don't have OpenHab fully installed? I am still having to go to the download folder on my Windows Server computer and launch the "start.bat" file in order to access the OpenHab web interface. Is this my issue? I will look further into proper Openhab installation while I await your reply. Thanks in advance.

BobRak commented 7 years ago

Here are some things I recommended you check to start with:

  1. On the Smartthings side, usings the developers console, have you verified the IP and mac point back to your openHAB server.
  2. On your server (which I assumes is Windows) have you as a minimum created a .things file with the Smartthings Bridge definition in it and does that IP point to you Smartthings hub.
  3. Are your openHAB server and the Smartthings hub on the same network?

If all of that seems OK then check the openhab log file on your openHAB server and verify that the Smartthings binding is getting loaded. You should see things like the following in the openHAB log file:

2017-05-25 16:48:42.008 [DEBUG] [org.openhab.binding.smartthings     ] - BundleEvent STARTING - org.openhab.binding.smartthings
2017-05-25 16:48:42.021 [DEBUG] [org.openhab.binding.smartthings     ] - BundleEvent STARTED - org.openhab.binding.smartthings
2017-05-25 16:48:42.081 [DEBUG] [org.openhab.binding.smartthings     ] - ServiceEvent REGISTERED - {org.eclipse.smarthome.core.thing.binding.ThingHandlerFactory, org.osgi.service.event.EventHandler}={event.topics=org/openhab/binding/smartthings/state, component.name=binding.smartthings, component.id=2, service.id=122, service.bundleid=183, service.scope=bundle} - org.openhab.binding.smartthings
2017-05-25 16:48:42.115 [DEBUG] [org.openhab.binding.smartthings     ] - ServiceEvent REGISTERED - {javax.servlet.http.HttpServlet}={service.pid=org.openhab.smartthings, service.config.category=binding, service.config.label=Smartthings Servlet, component.name=org.openhab.binding.smartthings, component.id=3, service.config.description.uri=binding:smartthings, service.id=123, service.bundleid=183, service.scope=bundle} - org.openhab.binding.smartthings
2017-05-25 16:48:42.226 [DEBUG] [org.openhab.binding.smartthings     ] - ServiceEvent REGISTERED - {javax.servlet.ServletContext}={osgi.web.symbolicname=org.openhab.binding.smartthings, osgi.web.version=2.1.0.201705041728, osgi.web.contextpath=/, service.id=124, service.bundleid=183, service.scope=singleton} - org.openhab.binding.smartthings
2017-05-25 16:48:42.231 [INFO ] [rtthings.internal.SmartthingsServlet] - Started Smartthings servlet at /smartthings
...
2017-05-25 16:48:56.746 [DEBUG] [s.internal.SmartthingsHandlerFactory] - SmartthingsHandlerFactory is now processing ThingTypeUID smartthings:smartthings
2017-05-25 16:48:56.757 [DEBUG] [iscovery.SmartthingsDiscoveryService] - initialize discovery service
2017-05-25 16:48:56.759 [DEBUG] [iscovery.SmartthingsDiscoveryService] - SmartthingsDiscoveryService.activate() called
2017-05-25 16:48:56.763 [DEBUG] [org.openhab.binding.smartthings     ] - ServiceEvent REGISTERED - {org.eclipse.smarthome.config.discovery.DiscoveryService}={service.id=235, service.bundleid=183, service.scope=singleton} - org.openhab.binding.smartthings
2017-05-25 16:48:56.769 [DEBUG] [org.openhab.binding.smartthings     ] - ServiceEvent REGISTERED - {org.osgi.service.event.EventHandler}={event.topics=org/openhab/binding/smartthings/discovery, service.id=236, service.bundleid=183, service.scope=singleton} - org.openhab.binding.smartthings

Are you using the PaperUI? If so, If you go to Configuration > Things are you seeing the Smartthings binding. If not there is a problem with the configuration.

Also you can look at the logs in the smartthings developers console and see what messages are flowing between the hub and your server. Start the smartthings developers console, open the log window and then start you openHAB server. You should see a discovery message.

Bob