Make Arduino Based Laser Tripwire Security Alarm


Arduino laser tripwire security system

Hello once again welcome to our blog today in this tutorial, you will learn make Arduino laser tripwire security system

in this tutorial You will learn how to use a photo resistor. A tripwire is a device triggered by physical movements, you can use it to detect people, animals, cars or etc when they pass through an laser area.

First Thank You NextPCB

This project is successfully because of the help and support from NextPCB. Guys if you have a PCB project, please visit their website and get exciting discounts and coupons.

Free shipping 0$ PCB Prototype:…

Thanksgiving Christmas lucky draw 100% win:…

Required Material for this project

  1. Arduino Nano
  2. Buzzer
  3. Battery Holder
  4. Laser
  5. LDR Sensor
  6. wire

Arduino laser tripwire Security circuit

Here is the circuit diagram for arduino laser tripwire circuit is fairly simple. There are 3 parts of the circuit:

  • Laser
  • Buzzer
  • photoresistor receiver

I am choosing to use a Buzzer indicator as my actuator, but this could be an SMS text, alarm, call and door lock.

here is circuit diagram

First part of the circuit is the photoresistor, Photoresistors, also known as LDR (light-dependent resistors), are components made of semiconductors.

A photoresistor is sensitive to light shine . Its resistance decreases when lighting shining increases

Next, we will create our actuator (Buzzer indicator). The purpose of the actuator is to inform us that the laser diode beam has been broken

Assemble The Circuit for Arduino laser tripwire

Make the circuit by following the schematic diagram given in the above picture. I have already explained the connection details of each component and module.

Arduino / LDR

  • D2 – positive pin
  • GND – GND

Arduino / Buzzer

  • D8 – Red wire(+)
  • GND – GND (-)

Programming for Arduino laser tripwire Security

First, download the Arduino sketch from here

const int photo = 2;
const int Buzzer= 8;
void setup() {
pinMode(Buzzer, OUTPUT);
digitalWrite(Buzzer, LOW);
pinMode(photo, INPUT_PULLUP);
void loop() {
//if/else loop checks if photoresistor is high or low
digitalWrite(Buzzer, HIGH);
digitalWrite(Buzzer, LOW);

Plugin the USB cable into the Arduino Nano with your laptop or desktop PC.

Set the correct board and COM Port number and upload the code into the Arduino.


After the programming is uploaded, we come to the last step where we will test it. Before testing, we put two 18650 lithium batteries in its battery holder.

As you can see the working, if someone comes in the middle of it, if the combination of laser and photodiode is broken, then it will start making sound.

if you want to make it without arduino so follow this link :-

I hope you like this too, you can ask us anything in the comment 🙂



About Author

Leave A Reply