Control TP-Link Smart Plug with Harmony Hub via Emulated Hue Bridge

This entry is part 7 of 11 in the series Creating My Smart Home.

One of my first smart devices was a TP-Link Wi-fi Smart Plug (model HS100). I used it to control the lights in our Christmas tree by voice control using an Amazon Echo. It worked great then, and after Christmas I moved it to our family room to control a floor lamp that we usually turn on in the evenings while watching TV or reading stories to our daughter. Unfortunately it is not compatible with Logitech’s Harmony Hub, so I wasn’t able to control it with my Harmony app/remote.

This is where Home Assistant proved how good it is at bridging the gaps between smart home devices. Adding it was easy enough. I assigned it a static IP address–all of my Home Assistant-related devices have a static IP address set–and followed the documentation to add it to my configuration.yaml file:

switch:
  - platform: tplink
    host: 192.168.0.150

After checking the configuration and restarting Home Assistant it showed up as a switch in the web UI. It even used the name I had assigned the plug in the TP-Link Kasa app. I went on to customize it using the customize section of the configuration.yaml file by changing the icon, capitalizing the friendly_name, and enabling control of it with the Emulated Hue Bridge component.

homeassistant:
  # Name of the location where Home Assistant is running
  name: Home
  # ... some code omitted for brevity
  customize:
    # ... some code omitted for brevity
    switch.lamp:
      friendly_name: Lamp
      icon: mdi:lamp
      emulated_hue: true

After another restart of Home Assistant, my Logitech Harmony Hub picked up the “Lamp” as a Philips Hue bulb, getting around the incompatibility issue. Now I’m able to assign one of the smart home buttons on my Harmony remote to turn the lamp on/off. That was one of my initial complaints in the first post in this series, and it really does add convenience when watching a movie at night.

By exposing the TP-Link plug via the Emulated Hue Bridge, I can control my “Lamp” with the Harmony app/remote.

Another bonus (in my mind) is that to use Alexa for voice control of the plug, now I can disable the “Remote Control” feature in the TP-Link Kasa app–bypassing TP-Link’s cloud service–and instead have Alexa see it as a Hue bulb and control it locally within my network.

My TP-Link Wi-Fi Smart Plug is configured for local control only; no remote access via the internet through TP-Link’s cloud service.

3 thoughts on “Control TP-Link Smart Plug with Harmony Hub via Emulated Hue Bridge

  1. Thanks, finally got it working, I would like to point out that in the MyHarmony app in Windows 10 you need to “Scan for Devices” to find the emulated Hue device.

    (If you “Add Device” under “Home Control” and Add Philips Hue it will continuously search for Hue Hub without ever finding it.)

Leave a Reply

Your email address will not be published. Required fields are marked *