Rayan kiwan
Published © LGPL

Bluetooth control LED using Arduino

Hello all, in this project I will show you how to control LED using bluetooth

IntermediateFull instructions provided2,495
Bluetooth control LED using Arduino

Things used in this project

Hardware components

Arduino UNO
Arduino UNO
×1
LED (generic)
LED (generic)
×1
HC-05 Bluetooth Module
HC-05 Bluetooth Module
×1
Resistor 220 ohm
Resistor 220 ohm
×1
Jumper wires (generic)
Jumper wires (generic)
×1
Breadboard (generic)
Breadboard (generic)
×1

Software apps and online services

Arduino IDE
Arduino IDE

Story

Read more

Schematics

bt control led circuit

Code

bt control led

Arduino
char data=0;
void setup(){
Serial.begin(9600);
pinMode(2,OUTPUT);
}
void loop(){
if (Serial.available()>0){
data = Serial.read();
Serial.print(data);
Serial.print("\n");
if(data=='1')
digitalWrite(2,HIGH);
else if (data=='0')
digitalWrite(2,LOW);
}

Credits

Rayan kiwan

Rayan kiwan

36 projects • 1 follower

Comments