Tinker Project
Published

Arduino-Powered Smart Light (Works with Amazon Echo)

Build your own Arduino-powered light switch that can be controlled using Amazon Alexa.

IntermediateFull instructions provided13,551
Arduino-Powered Smart Light (Works with Amazon Echo)

Things used in this project

Hardware components

Arduino Nano R3
Arduino Nano R3
×1
ESP8266 ESP-12E
Everything ESP ESP8266 ESP-12E
×1
SparkFun FTDI Basic Breakout - 3.3V
SparkFun FTDI Basic Breakout - 3.3V
×1
Breadboard (generic)
Breadboard (generic)
×1

Software apps and online services

Arduino IDE
Arduino IDE
AWS Lambda
Amazon Web Services AWS Lambda
Alexa Skills Kit
Amazon Alexa Alexa Skills Kit

Story

Read more

Schematics

Circuit

Circuit ep715hzeks

Code

Arduino Nano Code

Arduino
int light = 4; // Light Connected to digital pin 4
void setup()
{
  pinMode(light, OUTPUT);
  Serial.begin(115200);
  while (!Serial);
}

void loop() {
  if (Serial.available())
  {
    int state = Serial.parseInt(); //Convert serial data to int 
    if (state == 1)   
    {
      digitalWrite(light, HIGH); // When state is 1 turn on the Light 
    }
    if (state == 0)
    {
      digitalWrite(light, LOW); // When state is 0 turn off the Light
    }
  }
}

Credits

Tinker Project

Tinker Project

1 project • 5 followers
I make DIY and IoT related Projects.

Comments

Add projectSign up / Login