When I was young, I always have this kind of thought “Can I just switch off the light when I was about to sleep on the bed without going to the switch and turn it off?”. (I’m a bit scared when I sleep alone without my sibling) Hihi.. Then today, I found out that it’s actually doable to turn on and off the light by clapping my hand. Now, let’s have a look on how to do it!
This is the video for this project.
|Sound Sensor : VCC||Maker UNO: 5V|
|Sound Sensor : GND||Maker UNO: GND|
|Sound Sensor : Out||Maker UNO: pin 10|
|Yellow LED (+)||Maker UNO: pin 4|
|Yellow LED (-)||Maker UNO: GND with Resistor|
This is the sample code used for this tutorial. Try it!