How to Turn ON LED with a Clap | Arduino Controlled Relay Module and Sound Sensor
HTML-код
- Опубликовано: 10 сен 2024
- In this tutorial we will learn how to control the Arduino Sound Sensor. So we will control our LEDs and Lamps with a clap. We will use a sound sensor and a relay module for this.
Required Hardware:
Arduino Board :
goo.gl/Rqc5w2
amzn.to/2LZr6t4
Relay Module :
goo.gl/yAxcPL
amzn.to/3u7b013
Sound Sensor :
goo.gl/2pXWsw
amzn.to/3w58aLI
LED Strip 5M :
goo.gl/Wv08ZS
amzn.to/3cxikNA
LED Adapter:
goo.gl/Qf3YA8
amzn.to/3rvNvgx
9V Battery :
goo.gl/3EIJcf
amzn.to/2O4h5vK
F to F Jumper :
goo.gl/TdGrkk
amzn.to/3dhwVM5
M to M Jumper :
goo.gl/VRzUN4
amzn.to/3dhwVM5
Breadboard :
goo.gl/08nnr1
amzn.to/3qxLxwm
Battery Cable:
goo.gl/aBKusM
amzn.to/2QHL3qi
Recommended Items:
Use Your Muscles in Project - amzn.to/3wdL45C
37 Sensor & Module Packages - amzn.to/3m66WeQ
Try this Robot Arm - amzn.to/3fq8DCl
Best Resin 3D Printer - amzn.to/39tY8KB
Arduino Compatible Kits - bit.ly/2J2AFF7
Banggood Spring Sale - bit.ly/3slMbOn
Download Source Code: create.arduino...
Social Media:
/ mertarduino
/ mertarduino
Source Code: create.arduino.cc/editor/mertarduinotech/17665c7b-b5c5-44a4-808d-027459b24cfd/preview
Recommended Items:
Use Your Muscles in Project - amzn.to/3wdL45C
37 Sensor & Module Packages - amzn.to/3m66WeQ
Try this Robot Arm - amzn.to/3fq8DCl
Best Resin 3D Printer - amzn.to/39tY8KB
Arduino Compatible Kits - bit.ly/2J2AFF7
Banggood Spring Sale - bit.ly/3slMbOn
This is gonna be one of these videos that I actually do
Simple, well explained, well done ! Thank you very much :)
The best Arduino channel
This is the best RUclips Channel
Thanks for your tutorials !! This project is really cool !
you are the best in it project
I was wondering if this can be manipulated by a different interval of claps that can increase or decrease a 3 brightness mode of a lamp? Thanks
thank you
that's cool..... I m gonna make it for my bed room. 👌👍
love your videos bro keep it up 👍
your projects are just rocking man...... can u tell me how to create an arduino programme by own.... or can u recommend any study materials
Very nice video, i'm waiting more videos about LEDs
😍😍😍😍 miss your video 😍😍❤️ good work 😍😍😎
I was clapping my hands too when he made this video.
I just want to ask one thing that the arduino in this project must be connected to battery all the day all the night because you would like to turn on lights by clapping every time you enter somewhere dark but it will take a lot of batteries is there any other option or we if we can connect the arduino to the switch board please help me
you can change also it is so sad type of saong that is whay i have say to you sir
but your tutorials i loved it very much very much very nice tutorials
Great vid man!
Cool. Nice Idea.
very nice bro
I did everything as u said but I used the relay module-JQC-3FF-S-Z and didnt used the vector board i just connected them directly to the arduino by m-f connectors but the light is not turning on/off when I clap.idk why .plz explain and let me know where may i go wrong .plz reply me as early as possible.
hi sir ... ur projects really awesome...it's very use full to me... pls upload a video .. biped robot using arduino
Very nice video
is the code for the lamp and the rgb strip?
u are going nice .keep going on .I liked ur videos and I also made the same project.nice one
sorry i want to ask, can clap replaced with a voice like turn on the lights? if it could mean simply replacing clap with turn on the lights in coding? please explanation. Thank you.
I have a quick question for you. I have a kit with that relay but no relay module, is there a way I can just use the relay or do i need to order the module to do the project?
Thanks for the video I really appreciate it.
Very nice
if you have normal jumpers do you need the f to f jumpers & the m to m jumpers
Thank you
Nice one, excellent , also learnt about relays,thanks, but one thing Mr.Mert ,can we build a mic module myself using a condenser mic and lm358??
Hey, I wanted to say that you make great and helpful videos, but I wanted to ask would it activated if you talk?
In this video you have shown this with a single colour led(white),but I have a rgb led which has four copper points. So how should I connect it to the relay module? Please reply!
thank you so mach
Sir...., can you use two relay..... and two appliance ...from single arduino uno.....
It is possible...????try to make.....like fan...,bulb...., tv
nice job dude
Mert bey bir tane tutorialınız vardı, alkışla yanan lamba yapıyordunuz, masa lambası kullanarak. O videoyu baz alarak okulumda bir proje yürütüyorum, tüm malzemeleri ona göre almıştım ama şu anda kanalınızda göremiyorum. Yardımcı olur musunuz?
thank you sir
good it works. do you have simular sketches where this is combined with more led (different volume >> diffferent light) plus an ESP8266 to upload the sound-data to thingspeak?
Please make a video on how to make a proximity sensor using ir transmitter & reciever and also how to make a line follower also if possible.
bro tessekur ederim tutolar icin.... yine ellerinize saglik.
bir sorun var.: butun clap baglantılar yaptım ben. sizinkiye göre ama 2clap yapıp olmuyor beımkı. acaba sorun nedir??? yardım
Hello!
1) What do you mean lamp's and plugs's power + cable and ground cable its AC not DC right?
2) Can i not use arduino uno but Arduino Pro Mini ATmega328 5V 16MHz?
Great job! Please, if you can do that baking bluetooth or GPRS A6 light the match?
what are those black things which connect one wire with another????
Hello, great project, I just wonder, how to sett range? Id like to be able to turn on/off lights from 1-2 m away, not just beside the arduino set up :)
Sir.. I buy another sound sensor( red color, which has 4 pin) but how to use...plz...cooperate...
nice job thanks my friend
i'm wating more videos
OK thanks
mert kilic abi cok basarili videolar gelio yeni robot el projeleri yaparmisin
Ready to Die evt bende katılıyorum
mert abi butun yorumlara mesaj atmssin helal olsun
Saol abi
can I ask? what's the purpose of 9v battery in this circuit?
Can I use the RED sound sensor which has 4 pins? (AO pin)
my sound sensor have AO, G, +, DO
i don't know the vcc, gnd , output.. could you tell me?
G is negative vcc is positive and do is output pin and AO PIN has no use
i did everthing same what you did in this video but my led is not getting on or off by clapping. It gets on when i on the main plug but does not goes off when i clap.please reply.thankyou
i have the same problem
me too
Check the sensitivity of sound sensor
mine isn't working. When I switch on the bulb it's glowing but then when i supply power to the arduino the bulb foes off and nothing takes place when clapped. Please help me out.
if my relay is always turned on i should correct sensivity of my sound sensor, or should i fix relay?
amazing
Hi Congratulations, very good tutorial.
You can give me the library of this project please.
Greetings from Colombia
@@trilokchandsahu1598 what is the code for this project? Can you give? the link doesnt open
Nice bro do more love you bro
In case of the 12v led strip, I can simply use a Nchannel MOSFET (IRFZ44N) which will reduce the cost
@@trilokchandsahu1598 yes
You can also make videos to explain Arduino programming
source code:
int sound_sensor = 4;
int relay = 5;
int clap = 0;
long detection_range_start = 0;
long detection_range = 0;
boolean status_lights = false;
void setup() {
pinMode(sound_sensor, INPUT);
pinMode(relay, OUTPUT);
}
void loop() {
int status_sensor = digitalRead(sound_sensor);
if (status_sensor == 0)
{
if (clap == 0)
{
detection_range_start = detection_range = millis();
clap++;
}
else if (clap > 0&& millis()-detection_range >= 50)
{
detection_range = millis();
clap++;
}
}
if (millis()-detection_range_start >= 400)
{
if (clap == 2)
{
if (!status_lights)
{
status_lights = true;
digitalWrite(relay, HIGH);
}
else if (status_lights)
{
status_lights = false;
digitalWrite(relay, LOW);
}
}
clap = 0;
}
}
Wait, so I don't need a soldering iron to place wires into the board?
hey man , which jumpers did you use
can i use 2 relay module attached
Can the same thing happen if i will use a 9 volt battery and a led?
komutlar gösterirken daha yakın olamiyomu ben yaparkan cok göremiyomda
Hi, the code works pretty well, could u explain the code tho? thank you!
can we use battery insted
Can i connect the arduino to power supply instead of battery ?
my sound sensor has 4 pins huh can you help?
sir, can you explain why when i clap the light it won't switch on and off
can I ask your question.. where the video "Arduino project tutorial 04 : Clap light with sound sensor" I can't find that video.. thanks you..
Mert Arduino and Tech but i like that project :') can you give me the arduino code for my homework please :"
Mert Arduino and Tech oh where's you make a schematic for all your project? oh sorry for my bad english :)
can you give me the code? it doesnt open
plz do a video on relays connection to 12v dc motor and aurdiuno
Mert Arduino and Tech
can a 5v adaptor be used to run a 12v dc motor using relay using aurdiuno??...plz reply!!
wow, first time in my live i watched video that has no dislikes and more than 1k watches
Can I do it with atmega 8
can't we use virtual pins on Arduino Uno?? please reply!!
woah cool
hi , i have a question , can you make this tutorial on a protoboard ? i don't understand how to implement code to a protoboard :( . Please help me :D
please make a ir robot i learn many things with your tutorial
Circuit diagram
wow
can rgb led strip do this?
okay let me expplain what happened....i did everything like you said and i just needed to plug in the adapter to electricity....and guess what happened....booooom. Nothing happen3d to me but hole power brick is off and idk if my PC is dead cuz it was connected to it...
You created a short,because i guess you connected che NO and the NC instead NO and COM.
Ivan Dujić yeah my Pc just died that way
haha loser
what's about it's clap range??
where did u learn all this?
Sir how can i get the programing code pls emergency pls send me u link is not opening
int sound_sensor = 4;
int relay = 5;
int clap = 0;
long detection_range_start = 0;
long detection_range = 0;
boolean status_lights = false;
void setup() {
pinMode(sound_sensor, INPUT);
pinMode(relay, OUTPUT);
}
void loop() {
int status_sensor = digitalRead(sound_sensor);
if (status_sensor == 0)
{
if (clap == 0)
{
detection_range_start = detection_range = millis();
clap++;
}
}
if (millis()-detection_range_start >= 400)
{
if (clap == 2)
{
if (!status_lights)
{
status_lights = true;
digitalWrite(relay, HIGH);
}
else if (status_lights)
{
status_lights = false;
digitalWrite(relay, LOW);
}
}
clap = 0;
}
}
how can i solve the problem
Can that project work on electric fan? And will the codes change?
Relay can be used for any device.
Relay is like switch, so you can connect lights, fans and all other electric devices.
plz can you make a tutorial for keyboard instrument arduino plz sir plz plz plz plz plz plz i love you tuttorials plZ sir
Means sir that it is make up of mamy switches and when we press anyone of them switches the sounds comes different by pressing switches i have seen this on another chanel of youtube but i didn't understood i have requested from you because your tutorias are understandable that is why
please help me sir
Why is automatic off and on?
i use esp32 not working this coding
my relay has NC and NO labels, there is no COM
why put Battery? you connect with power
How to arduino programme for clap light???
can yoy reupload the old. video ...please. for my project
can i use arduino nano for this project?
Jes you can!
please send me the code
cause your link doesn't give the complete code
It's a great youtube canal and you're videos are great but I'm unsubscribing because you never reply to those who have issues.
arduino compiler is generating error on this code
Hey man! I would like to have the source code... The link isn´t working. Great channel!
source code:
int sound_sensor = 4;
int relay = 5;
int clap = 0;
long detection_range_start = 0;
long detection_range = 0;
boolean status_lights = false;
void setup() {
pinMode(sound_sensor, INPUT);
pinMode(relay, OUTPUT);
}
void loop() {
int status_sensor = digitalRead(sound_sensor);
if (status_sensor == 0)
{
if (clap == 0)
{
detection_range_start = detection_range = millis();
clap++;
}
else if (clap > 0&& millis()-detection_range >= 50)
{
detection_range = millis();
clap++;
}
}
if (millis()-detection_range_start >= 400)
{
if (clap == 2)
{
if (!status_lights)
{
status_lights = true;
digitalWrite(relay, HIGH);
}
else if (status_lights)
{
status_lights = false;
digitalWrite(relay, LOW);
}
}
clap = 0;
}
}
thats right, me too
@@haxorite1740 thanks