Project in progress
Smartwatch - Arduino LED Control

Smartwatch - Arduino LED Control

This project shows the first prototype of a connection between a smartwatch and Arduino for controlling eight LEDs.

  • 7,471 views
  • 7 comments
  • 26 respects

Components and supplies

Apps and online services

About this project

This project is developed with the objective of create a domotic system using a smartwatch because is more confortable to have the control of our house on a wristwatch than having to take the cell phone out of your pocket whenever you want to control something.

Code

Arduino - bluetooth codeArduino
# include <SoftwareSerial.h>
SoftwareSerial bt_serial(2, 3);
String peticion = "";
char c = ' ';

void setup() {
  pinMode(4, OUTPUT);
  pinMode(5, OUTPUT);
  pinMode(6, OUTPUT);
  pinMode(7, OUTPUT);
  pinMode(8, OUTPUT);
  pinMode(9, OUTPUT);
  pinMode(10, OUTPUT);
  pinMode(11, OUTPUT);
  digitalWrite(4, LOW);
  digitalWrite(5, LOW);
  digitalWrite(6, LOW);
  digitalWrite(7, LOW);
  digitalWrite(8, LOW);
  digitalWrite(9, LOW);
  digitalWrite(10, LOW);
  digitalWrite(11, LOW);
  bt_serial.begin(38400);
  bt_serial.setTimeout(5);
  Serial.begin(9600);
}

void loop() {
  if (bt_serial.available() > 0) {
    while (bt_serial.available() > 0) {
      c = bt_serial.read();
      peticion += c;
    }
    Serial.println(peticion);
    if (peticion == "act1on") {
      digitalWrite(4, HIGH);
      Serial.println("Uno on");
    }
    if (peticion == "act1off") digitalWrite(4, LOW);
    if (peticion == "act2on") digitalWrite(5, HIGH);
    if (peticion == "act2off") digitalWrite(5, LOW);
    if (peticion == "act3on") digitalWrite(6, HIGH);
    if (peticion == "act3off") digitalWrite(6, LOW);
    if (peticion == "act4on") digitalWrite(7, HIGH);
    if (peticion == "act4off") digitalWrite(7, LOW);
    if (peticion == "act5on") digitalWrite(8, HIGH);
    if (peticion == "act5off") digitalWrite(8, LOW);
    if (peticion == "act6on") digitalWrite(9, HIGH);
    if (peticion == "act6off") digitalWrite(9, LOW);
    if (peticion == "act7on") digitalWrite(10, HIGH);
    if (peticion == "act7off") digitalWrite(10, LOW);
    if (peticion == "act8on") digitalWrite(11, HIGH);
    if (peticion == "act8off") digitalWrite(11, LOW);
  }
    peticion = "";
    c = ' ';
}

Schematics

Arduino-HC 05-Leds-Connection
Diagrama v1 bb anz1jeeqnp
Smartwatch QW09
Reloj   qw09 kvzeyjjfcc
APP programming 1
App   image 1 apfpn1t5r7
APP programming 2
App   image 2 dyeqderfzs

Comments

Similar projects you might like

Servo Control with TV Remote Control

Project showcase by eldo85

  • 5,592 views
  • 5 comments
  • 17 respects

Control an LED with the Remote Control

Project showcase by Nicholas_N

  • 3,192 views
  • 2 comments
  • 9 respects

Bluetooth control led with lcd led status display real time.

Project tutorial by Youssef Sabaa

  • 17,304 views
  • 4 comments
  • 34 respects

Control 8 x 8 LED Matrix with Only Two Shift Registers

Project showcase by Jegqamas

  • 1,489 views
  • 0 comments
  • 6 respects
Add projectSign up / Login