Project tutorial
Anna: Alexa Powered Interactive Light

Anna: Alexa Powered Interactive Light © GPL3+

Enables any of your lights/lamps to be powered by Alexa.

  • 1,848 views
  • 0 comments
  • 7 respects

Components and supplies

Apps and online services

About this project

Introduction

This is a quick hack because I have built these two project earlier:

Step 1. Setup the Raspberry Pi, Node-RED and Arduino Uno

To complete this step, follow steps 1 to 4 of the first project (Alexa Controlled LEDs Through Raspberry Pi).

Step 2. Add relay to the power extension

Hack the power extension by adding a relay to it (see section Finishing touch of Turn a Livingroom Table Lamp on and off with Echo).

Step 3. Import the Node-RED Flow

Import the Node-RED Flow from the code section below. Note that there is a 'transform' function added which change "on" to "off" and vise versa. The reason is the relay is wired according to the Normally Closed (NC) configuration.

Testing Time

Demo video

.

Code

Anna Node-RED FlowJSON
[{"id":"e349e731.cc5038","type":"alexa-local","z":"d4157f57.cd02a","devicename":"anna","inputtrigger":false,"x":170,"y":200,"wires":[["cc7b51f0.00c0f","a90367f8.ee4718"]]},{"id":"cc7b51f0.00c0f","type":"debug","z":"d4157f57.cd02a","name":"","active":true,"console":"true","complete":"payload","x":380,"y":100,"wires":[]},{"id":"d5463435.4dbe88","type":"arduino out","z":"d4157f57.cd02a","name":"","pin":"10","state":"OUTPUT","arduino":"d4c6e849.844578","x":550,"y":200,"wires":[]},{"id":"a90367f8.ee4718","type":"function","z":"d4157f57.cd02a","name":"transform","func":"if (msg.payload == \"on\") { msg.payload = \"off\" } else { msg.payload = \"on\" };\n\nreturn msg;","outputs":1,"noerr":0,"x":360,"y":200,"wires":[["d5463435.4dbe88"]]},{"id":"d4c6e849.844578","type":"arduino-board","z":"","device":"/dev/ttyACM0"}]

Comments

Similar projects you might like

Alexa Controlled LEDs Through Raspberry Pi

Project tutorial by vincent wong

  • 5,270 views
  • 5 comments
  • 23 respects

Animated Smart Light with Alexa and Arduino

Project tutorial by Bruno Portaluri

  • 3,652 views
  • 9 comments
  • 23 respects

Enable Alexa Control to your Ceiling Fan

Project tutorial by Jithin Thulase

  • 3,123 views
  • 5 comments
  • 9 respects

Light Control Using Arduino and Amazon Alexa

Project tutorial by Rajesh

  • 12,180 views
  • 1 comment
  • 14 respects

KidGuard

Project tutorial by vincent wong

  • 1,592 views
  • 0 comments
  • 4 respects

Dooreo - The Alexa Powered Automatic Door Opener

Project tutorial by Keith Caskey

  • 2,744 views
  • 0 comments
  • 12 respects
Add projectSign up / Login