Laser Light Security System Using Arduino with Alarm

In this project, we used the Laser Diode Module KY-008 to construct a Laser Light Security System using Arduino with Alarm. The objective of the project is to build a security system. The buzzer alarm will begin to ring whenever any item blocks the LASER ray.

This project can be executed anywhere; in addition to buildings or other structures, it can also be used to secure other valuable commodities like jewels, diamonds, priceless antiques in museums, etc. With the LASER beam security system, many people secure their homes, offices, stores, warehouses, etc.

Components Required:

  • Arduino UNO Board
  • LASER Diode Module KY-008
  • Buzzer
  • LDR
  • Resistors (10k)
  • Push Button Switch
  • Breadboard
  • Connecting wires

Circuit Diagram:

Laser Light Security System Using Arduino wih Alarm

Laser Diode Module KY-008:

Laser Light Security System Using Arduino wih Alarm

A red laser beam in the dot shape is produced by the Laser Transmitter Module KY-008 for Arduino. A resistor and a red laser diode head with a wavelength of 650 nm make up the KY-008 Laser transmitter module. Use caution when handling the laser and avoid staring straight at its head.

The specification of Laser Transmitter Module KY-008 is as follows:

  • Operating Voltage – 5V
  • Output Power – 5mW
  • Wavelength – 650nm
  • Operating Current – less than 40mA
  • Working Temperature – -10°C ~ 40°C [14°F to 104°F]
  • Dimensions – 18.5mm x 15mm [0.728in x 0.591in]

Working on the Laser Light Security System Using Arduino

The project essentially operates on the interruption principle. If the LASER light is cut off in any way, the alarm will sound unless it is manually reset. The laser is a focused light source that emits a single-color, straight beam of light.

Laser Light Security System Using Arduino wih Alarm

Since the LDR is light-sensitive, when a laser beam strikes it, it produces a voltage. The voltage output of the LDR varies as the laser beam is blocked from reaching it, and eventually, the alarm will sound.

Source Code/Program:

int laserPin = 3;
int sensorPin = A0;
int buttonPin = 12;
int buzzerPin = 11;

int laserThreshold = 10;

void setup() {
pinMode(laserPin, OUTPUT);
pinMode(buttonPin, INPUT_PULLUP);

boolean alarmState = false;

void loop() {
if (! alarmState) {
digitalWrite(laserPin, HIGH);
unsigned long startTime = millis();
while (millis() – startTime < 1000) {
int sensorValue = analogRead(sensorPin);
if (sensorValue > laserThreshold) {
alarmState = true;
digitalWrite(laserPin, LOW);
} else {
tone(buzzerPin, 440);
if (! digitalRead(buttonPin)) {
alarmState = false;


I hope all of you understand how to design a Laser Light Security System Using Arduino with Alarm. We MATHA ELECTRONICS will be back soon with more informative blogs.

Leave a Reply

Your email address will not be published.