Announcement

Collapse
No announcement yet.

Bridge between SmartThings and MQTT

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Bridge between SmartThings and MQTT


    Smartthings MQTT bridge

    This project was spawned by the desire to control SmartThings from within Home Assistant. Since Home Assistant already supports MQTT, we chose to go and build a bridge between SmartThings and MQTT.

    Click image for larger version

Name:	Smartthingtomqtt.jpg
Views:	709
Size:	37.0 KB
ID:	1268696
    - Pete

    Auto mator
    Homeseer 3 Pro - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e 64 bit Intel Haswell CPU 16Gb
    Homeseer Zee2 (Lite) - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e - CherryTrail x5-Z8350 BeeLink 4Gb BT3 Pro
    HS4 Lite - Ubuntu 22.04 / Lenovo Tiny M900 / 32Gb Ram

    HS4 Pro - V4.1.18.1 - Ubuntu 22.04 / Lenova Tiny M900 / 32Gb Ram
    HSTouch on Intel tabletop tablets (Jogglers) - Asus AIO - Windows 11

    X10, UPB, Zigbee, ZWave and Wifi MQTT automation-Tasmota-Espurna. OmniPro 2, Russound zoned audio, Alexa, Cheaper RFID, W800 and Home Assistant

    #2
    What is interesting in smartthing? Did install the hub v2 at my mom's place. But, only control one zwave device with it, which could be replace by a lutron dimmer.
    The Lutron's cloud is very fast for control only with google home , at her place

    Comment


      #3
      Yeah here interfaced the Samsung Smartthings with my Leviton OmniPro 2 panel a while ago and used it concurrent with the Homeseer Omni Plugin.

      I am though alway tinkering here with multiple protocals and recently have added MQTT and Home Assistant, nodered to the automation mix...(plus Domoticz and for a bit OpenHab).
      - Pete

      Auto mator
      Homeseer 3 Pro - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e 64 bit Intel Haswell CPU 16Gb
      Homeseer Zee2 (Lite) - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e - CherryTrail x5-Z8350 BeeLink 4Gb BT3 Pro
      HS4 Lite - Ubuntu 22.04 / Lenovo Tiny M900 / 32Gb Ram

      HS4 Pro - V4.1.18.1 - Ubuntu 22.04 / Lenova Tiny M900 / 32Gb Ram
      HSTouch on Intel tabletop tablets (Jogglers) - Asus AIO - Windows 11

      X10, UPB, Zigbee, ZWave and Wifi MQTT automation-Tasmota-Espurna. OmniPro 2, Russound zoned audio, Alexa, Cheaper RFID, W800 and Home Assistant

      Comment


        #4
        Is the ST MQTT App intercepting traffic intended for cloud or does it have a local API?

        Comment


          #5
          I do not know.


          Installing it in my docker directory..

          /opt# ls
          alexa-api containerd home-assistant mqtt.py node-red omnilink-bridge OmniLinkBridge OmniLinkBridge.ini zigbee2mqtt

          /opt# docker run \
          > -d \
          > --name="mqtt-bridge" \
          > -v /opt/mqtt-bridge:/config \
          > -p 8080:8080 \
          > stjohnjohnson/smartthings-mqtt-bridge
          266fe31ff30fa54d62ffa4c6ce02e91592634a84bdf70796d416ae37ffaf 3d68

          edited config file

          /opt/mqtt-bridge# docker restart mqtt-bridge
          mqtt-bridge


          - Pete

          Auto mator
          Homeseer 3 Pro - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e 64 bit Intel Haswell CPU 16Gb
          Homeseer Zee2 (Lite) - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e - CherryTrail x5-Z8350 BeeLink 4Gb BT3 Pro
          HS4 Lite - Ubuntu 22.04 / Lenovo Tiny M900 / 32Gb Ram

          HS4 Pro - V4.1.18.1 - Ubuntu 22.04 / Lenova Tiny M900 / 32Gb Ram
          HSTouch on Intel tabletop tablets (Jogglers) - Asus AIO - Windows 11

          X10, UPB, Zigbee, ZWave and Wifi MQTT automation-Tasmota-Espurna. OmniPro 2, Russound zoned audio, Alexa, Cheaper RFID, W800 and Home Assistant

          Comment


            #6
            Doing the Samsung Smartthing IDE stuff was a real PITA. Not working here. I do not see any messages at this time. Set up two devices. How it works

            HTTP Endpoint: There are really only 2 ways to communicate with the SmartThings hub that we could find. The easiest approach is to create a RESTful SmartApp authenticated with OAuth that provides state changes via HTTP directly. This approach is pretty straightforward to implement, but it requires communication with the SmartThings cloud service, and can’t be done entirely on your LAN. We hoped to keep all communication internal, and came up with a second approach.

            Custom Device Type: SmartThings custom device types allow developers to define handlers for HTTP events received directly over the local network by the SmartThings hub. Messages received are authenticated by MAC address, and can contain arbitrary strings in their payload. Since a Device Type is only ever tied to a single device, we need to add a SmartApp to the mix in order to translate events between individual devices and our special Home Assistant Bridge device. Here is what we have so far:
            - Pete

            Auto mator
            Homeseer 3 Pro - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e 64 bit Intel Haswell CPU 16Gb
            Homeseer Zee2 (Lite) - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e - CherryTrail x5-Z8350 BeeLink 4Gb BT3 Pro
            HS4 Lite - Ubuntu 22.04 / Lenovo Tiny M900 / 32Gb Ram

            HS4 Pro - V4.1.18.1 - Ubuntu 22.04 / Lenova Tiny M900 / 32Gb Ram
            HSTouch on Intel tabletop tablets (Jogglers) - Asus AIO - Windows 11

            X10, UPB, Zigbee, ZWave and Wifi MQTT automation-Tasmota-Espurna. OmniPro 2, Russound zoned audio, Alexa, Cheaper RFID, W800 and Home Assistant

            Comment


              #7
              Well decided it was a bit too much stuff relating to the Samsung IDE and not really worth it. Deleted the Docker and IDE stuff this morning.
              - Pete

              Auto mator
              Homeseer 3 Pro - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e 64 bit Intel Haswell CPU 16Gb
              Homeseer Zee2 (Lite) - 3.0.0.548 (Linux) - Ubuntu 18.04/W7e - CherryTrail x5-Z8350 BeeLink 4Gb BT3 Pro
              HS4 Lite - Ubuntu 22.04 / Lenovo Tiny M900 / 32Gb Ram

              HS4 Pro - V4.1.18.1 - Ubuntu 22.04 / Lenova Tiny M900 / 32Gb Ram
              HSTouch on Intel tabletop tablets (Jogglers) - Asus AIO - Windows 11

              X10, UPB, Zigbee, ZWave and Wifi MQTT automation-Tasmota-Espurna. OmniPro 2, Russound zoned audio, Alexa, Cheaper RFID, W800 and Home Assistant

              Comment


                #8
                Originally posted by Michael McSharry View Post
                Is the ST MQTT App intercepting traffic intended for cloud or does it have a local API?
                There is a "SmartApp" that has to be installed through the IDE. This sends updates/status to the node.js app which then translates into MQTT and pushes to the broker. It's a bi-directional setup and works ok if you a need for the setup as it does take time to setup and adjust.

                Comment

                Working...
                X