Touchless Door Bell Using Arduino

by rayankiwan63 in Circuits > Arduino

713 Views, 1 Favorites, 0 Comments

Touchless Door Bell Using Arduino

touchless door bell.png

touchless door bell Arduino project

Circuit Diagram

touchless door bell.png

components needed

breadboard (optional)

arduino uno

pir sensor

peizo buzzer

wires

Coding Part

touchless door bell.png

// C++ code

// #include Servo servo1;

void setup() {

pinMode(8, INPUT);

pinMode(9, OUTPUT);

pinMode(7, OUTPUT);

servo1.attach(7);

servo1.write(90);

delay(2000); }

void loop()

{ if (digitalRead(8) == 1)

{ tone(9, 57079043007393, 1000); // play tone 500 (G#41 = 57079043007393 Hz)

servo1.write(90); }

else { noTone(9);

servo1.write(180); }

delay(10); // Delay a little bit to improve simulation performance }

you can check tinkercad simulation

https://www.tinkercad.com/things/1ipTqLTpU7F-copy-of-touchless-door-bell/editel?tenant=circuits

Output Results

the buzzer will begin ringing when pir sensor senses any motion near it