Control LEDs with Alexa via Raspberry Pi – Easy Step‑by‑Step Guide
Components and supplies
Raspberry Pi 3 Model B
×
1
Arduino UNO
×
1
LED (generic)
×
2
Resistor 100 ohm
×
1
Breadboard (generic)
×
1
Amazon Alexa Amazon Echo
×
1
Apps and online services
Arduino IDE
Node-RED
About this project
Introduction
It turns out that it is quite easy to get Alexa communicate with Arduino via Raspberry Pi with Node-RED. All you have to do is installing two Node-RED modules and setup up a Node-RED Flow with Alexa Local and Arduino nodes. Here I have a project which has Alexa turn on and off two LED lights as a demo.
Step 1. Setup Raspberry Pi
Follow this step to get your Raspberry Pi ready.
Step 2. Install Node-RED
Follow this step to install Node-RED.
Step 3. Install the Arduino node
Follow this step to install the Arduino node for Node-RED. I am using Firmata in this project. You need to upload the Standard Firmata to the Arduino Uno, follow this link to accomplish that.
Step 4. Install the Alexa Local
Follow this step to install the Alexa Local Node-RED module.
Step 5. Setup the Node-RED Flow
Import the Node-RED Flow from the code section below.