An Example using Roku to Control a dlink Smart Plug over the network
- A Roku that is in developmer mode
- An Account at IFTTT
- A Dlink Wi-Fi Smart Plug
- A Text Editor (for full Roku Brightscript Development use Eclipse IDE for Java Developers with the Roku SDK Plugin)
- Grab your dlink username & password
- Successfully connect your smart plug to the network and verify it is functioning correctly from the Android or iOS application.
- Login to IFTTT
- Navigate to Maker WebHooks
- Enable your webhooks and access the 'documentation' button in the top right of the page
- Copy the key, we will need this for the Roku Code section coming up
- Return to your Applets and create a new Applet
- For THIS select Maker Webhooks and name your request (you will also need this name coming up)
- For THAT we will be selecting the DLINK SMART PLUG and Toggling it On/Off for 30 seconds.
- Return to the documentation at Maker WebHooks and enter your new event name from step 6
- Verify it toggles your plug on/off
- open 'components/SimpleTask.xml' in an editor
- change '{YOUR API KEY HERE}' to the API Key you generated in IFTTT step 4.
- change '{EVENT}' to the event name you generated in IFTTT step 6.
- rezip the directory and use the Roku Development Portal (usually 192.168.1.12) to upload the package. Note: Updating the package instantly fires the command we set up in IFTTT earlier.