joeharrison714 / fpp-smartthings-plugin

1 stars 3 forks source link

fpp-smartthings

This is a Falcon Player (fpp) plugin that allows you to control SmartThings devices by using commands in fpp.

I developed this so that I could automate the turning on/off of my tune-to sign (which is plugged into a smart plug) and turn on/off other house lights before and after the show without having to maintain separate triggers in SmartThings.

NOTE: This currently uses the SmartThings groovy IDE, which is said to be going away sometime in 2021. When that happens this plugin will need to be updated.

Installation

In fpp, go to Content Setup, Plugin Manager and paste the following URL in the box and click "Retrieve Plugin Info": https://raw.githubusercontent.com/joeharrison714/fpp-smartthings-plugin/master/pluginInfo.json

Setup

Install SmartApp

  1. Login to https://graph.api.smartthings.com/ide/apps
  2. Click New SmartApp and then From Code
  3. Copy and paste the contents of this file into the text box: https://raw.githubusercontent.com/joeharrison714/fpp-smartthings-app/master/smartapps/fpp-smartthings/fpp-web-services.src/fpp-web-services.groovy
  4. Click Save
  5. Click Publish -> For Me
  6. Edit the SmartApp
  7. Under OAuth click "Enable OAuth in Smart App"
  8. Leave defaults and click update
  9. Copy the client ID and client Secret for use in the next step

Setup plugin

  1. In the plugin configuration, paste the client ID and secret that you copied above.
  2. Move away from the text box for the value to save
  3. Click the link that should appear titled "Configure SmartThings Access"
  4. Login with SmartThings and choose which switches you want FPP to be able to control
  5. Click Authorize
  6. After returning to FPP, restart FPPD
  7. Test control of your devices/routines using the buttons on the plugin configuration page
  8. The SmartThings commands should now be available in FPP

NOTE: If you want to trigger a scene, you will need to create a virtual switch and then create an automation to trigger the scene. You can then trigger the virtual switch using this plugin.