Arduino Tutorial - Laser Security System

Introduction: Arduino Tutorial - Laser Security System

In this tutorial, I show you, How To make a Simple laser Security System with Arduino.

Step 1: ​You Will Need:

Hardware

  • LED
  • Laser
  • Photoresistor
  • Piezo Buzzer
  • Breadboards
  • Arduino uno
  • Resistor 10Ω Resistor
  • 220Ω Resistor for led.
  • jumper wire

Software

  • Arduino IDE

Step 2: Watch the Video Tutorial

Step 3: Schematics

Breadboard:-----------Arduino Pins:---------Breadboard

Buzzer--------------------Pin9------------------------Gnd

Laser-----------------------5v--------------------------Gnd

Resistor------------------A0---------------------------Gnd,Photocell

Photocell-------------------5v-------------------------Resistor

Led----------------------Pin6,Pin7

Note:I've used 220 Ohm resistors in the past for all of my LEDs.

Step 4: Arduino Sketch

int sensorPin=A0;

int sensorValue=0; int piezoPin=9;

void setup(){ pinMode(sensorPin,INPUT); pinMode(7,OUTPUT); pinMode(6,OUTPUT); pinMode(piezoPin,OUTPUT); digitalWrite(7,HIGH); digitalWrite(6,LOW); }

void loop(){ sensorValue=analogRead(sensorPin); if(sensorValue<=1000) {digitalWrite(piezoPin,HIGH); {tone(9,3047,400); noTone(8); } digitalWrite(7,HIGH); } else {digitalWrite(piezoPin,LOW); digitalWrite(7,LOW); } sensorValue=1000; }

1 Person Made This Project!

Recommendations

  • Make it Glow Contest

    Make it Glow Contest
  • First Time Author Contest

    First Time Author Contest
  • PCB Challenge

    PCB Challenge

11 Discussions

0
Aurel222
Aurel222

Question 1 year ago on Step 1

Hi,

may I ask you which piezo buzzer you used and which light sensor and which laser?
Maybe you have links (ebay / amazon etc.) for me?
I would love to build this project - but I am a little overwhelmed because there are so many different buzzers etc. and I don‘t which one is right....

You would really help me a lot :-)
This will be my first Arduino project by the way :-)

Best regards

Aurel

0
GönlünüG

Comment je peux faire un code pour activer et désactivé le fonctionnement de la diode laser comme un programme merci beaucoup svp c urgent

0
None

Question 2 years ago

what is the part number for the 5v Laser unit...can anyone please mention that...

0
riyadhfenibd
riyadhfenibd

2 years ago

if i want to control mobile calling systems... when what procedure....

0
KuboP1
KuboP1

3 years ago

is it possible to make this led fading?

0
BlueMatter
BlueMatter

Reply 2 years ago

you can use LEDs or infrared LEDs, but the LEDs have some problems with strong light, ( Sun light)

0
julieanmarabilis18
julieanmarabilis18

3 years ago

if ever i am using a 220v buzzer and Ldr and a led i want to make an laser security system but i dont know can you please help me

0
Mayannk
Mayannk

Reply 3 years ago

use relay module

0
DhruboC
DhruboC

4 years ago

Can I use a Photodiode instead of an LDR?

0
Erwinv1
Erwinv1

Reply 4 years ago

Set the sensor value to 30 at both lines when I used a normal LDR (mostly in kits or as board)