vkorn / hassio-addons

Hass.io add-ons
58 stars 73 forks source link

Device Setup #8

Closed AJax2012 closed 6 years ago

AJax2012 commented 6 years ago

Please excuse me if this is a noob question, but I'm having some issues figuring out the SmartThings API.

I'm having issues trying to figure out how to setup the Device on My Devices IDE. Right now, I have the IP address of the device according to my router, the MAC address according to my router and port 2080. I've tried the IP address and MAC address that SSHing into the terminal and running ifconfig gives me and ports 2080, 8888, and 8080 (the port that worked on my old setup) on each IP/MAC address combination. My assumption is still that the addresses are the IP address and MAC address given by my DHCP server and I thought the port would be 2080, since that's what it looks like it is in config.json.

Can anyone help with this? Thanks

AJax2012 commented 6 years ago

Found answers from someone online.

jonathanweinberg commented 6 years ago

@AJax2012 What were the answers?

AJax2012 commented 6 years ago

@jonathanweinberg, most of the issues I was having revolved around ports and IP addresses. My Mosquitto broker was set to ports 1883 (broker port) and 8883 by default, I had to change the broker port to 1883 and the bridge port to 8080 on the SmartThingsBridge. I also forgot that I hadn't changed anonymous to false after changing my username and password on the MQTT broker. I also messed with the broker host IP address and eventually changed it to match the MQTT server, which I found in the log when I restarted it. After that, I had to go through and delete all of the settings in my SmartThings API and recreate them. I think I also had to change my config settings, so double check that...I used a light to check if it was working.

switch:
  - platform: mqtt
    name: "Laundry_Room_Light"
    state_topic: "smartthings/Laundry_Room_Light/switch/state"
    command_topic: "smartthings/Laundry_Room_Light/switch/cmd"
    payload_on: "on"
    payload_off: "off"