Hi Readers,
Today I would like to show you DIY doorbell or just hand controlled annoying buzzer.
What you need:
- Cheap buzzer which cost about 1-3 euro.
- Touch sensor another 3 euro
- Cables
- Nodemcu or any arduino board
Connections

Source code (PlatformIO & Arduino)
int returnValue = 0;
void setup() {
Serial.begin(115200);
pinMode(2, INPUT);
pinMode(4, OUTPUT);
delay(1000);
}
void loop() {
returnValue = analogRead(2);
Serial.println(“Sensor value: ” + String(returnValue));
delay(100);
if(returnValue > 500)
analogWrite(4,1);
else
analogWrite(4,0);
}
Complete project
This example is very practical. You can simply use it to other sensors. I have used it also with Passive infrared sensor – motion detector.
This post is initial post for future projects I will publish on GetToKnowTheBob blog.
Have fun!
Github repository: https://goo.gl/ii9xsz
Be positive and stay calm!
Cheers,
Radek