Arduino Projects

Anti Theft Alarm system using Force sensor and Arduino

Learn how to built an Anti Theft Security Alarm system using Arduino with Force sensor.


In this simple and interesting Arduino project you will learn how to make an Anti theft Alarm system by interfacing a simple Force sensor with Arduino and display the values on 16X2 LCD display module. So, first lets learn about the concept and working of the Force sensor and then interface it with Arduino to and program it to work as an anti theft system.

In present situation you cannot trust anyone, people are strengthening their security systems to reduce burglary and theft. The use for safes and lockers had increased with the increase in assets, previously there are manual safes with keys to unlock which were easy to steal and break them without knowing to anyone. But as the technology increased the safes where added with motion sensors, GPS tags so even if someone wants to steal it they are caught easily.

high security systems with technology

So, taking it into consideration we are building a security system that alerts the owner with alarm sound when someone tries to touch or take the item placed on the sensor. You can even make this project IoT based or GSM based by adding notifications when the parameters are triggered. Lets see what are the required components for this project.

Suggested article: Password based solenoid door lock system

Required components:

Here are the required components along with Amazon buying links at best prices.
Product NameQuantityamazon logoamazon logo india
Arduino microcontroller1
Force sensor(Force Sensitive Resistor)1
10k ohm resistor1
16x2 LCD display with I2C adapter1
Tactile Push button1
1k ohm resistor1
Few connecting wires

Force sensitive Resistor Overview:

A force sensing resistor is an electrical component that changes its resistance with changes in pressure on the resistive material. It is used to detect touch, weight, and any entity characterized by a change in mechanical force.

force sensor FSR Force sensitive resistor product

The force sensitive resistor uses a polymer sandwiched between two plates with conductive materials suspended in a sort of regular formation. When pressure is applied, the conductive material moves closer together, resulting in less resistance. If the pressure is removed, the ability of the polymeric material to recover from temporary deformation will return the force sensing resistance to its initial state. This results in the rest position being high strength.

Related article : RFID based door lock system using Arduino

Applications for the force sensing resistor include contact sensing for safety applications, digital weighing scales, air and water pressure sensing for pumps, and proximity sensing by weight or contact. In automation, robotic equipment can partially emulate human touch or touch sensing. This feature allows touch sensors and variable force control to be applied to automatically handle items that are considered too fragile to be handled by machines and robots alone.

In this project, we are using 1.75×1.5″ inch FSR sensor which has a resistance of more than 1M ohms when no force is applied and can measure the force of weights from 100 grams to 10 kgs.

Technical specifications:

  • Non-Actuated Resistance: 10M Ohm
  • Actuation Force: 0.1 Newtons
  • Force Sensitivity Range: 0.1-10 Newtons
  • Device Rise Time: <3 microseconds
  • 32 KB Flash Memory
  • 16MHz Clock Speed

Circuit Diagram for Anti-theft alarm system using Force sensor

Connect all the required components according to the below circuit diagram.

Circuit Diagram for Anti-theft alarm system using Force sensor and Arduino

As you can see from the above image force sensor has 2 pins one is for 5V and another is for the analog output, output pin also connected to GND in series with 10K ohm resistor which is used to create voltage divider.

The LCD display with I2C adapter has 4 pin, 2 pins for power supply VCC and GND which are connected to 5V and GND of Arduino and Another 2 pins for I2C communication SDA and SCL which are connected to A4 and A5 respectively.

A tactile Push button is connected to 5V and GND(with 1k ohm resistor) and the signal pin is connected to digital pin 4 of Arduino.

Buzzer has 2 wires one wire is connected to digital pin 6 of Arduino and other is connected to GND pin.

After connecting everything its time to upload the program code.

Program code:

Connect the Arduino Uno board to the PC where Arduino IDE is installed through USB cable. Choose the correct port and board as Arduino UNO from Tools menu and install the required libraries from the Library manager or download from the below links and extract them in Arduino Libraries folder.

Required Libraries:

  • Download LiquidCrystal_I2C – Link

Next copy the below code and paste it in IDE workspace and press upload button. That’s it the code will be uploaded.

//Arduino project from Circuit Schools
//Force Sensor Anti-Theft Alarm System using Arduino
#include <LiquidCrystal_I2C.h>
LiquidCrystal_I2C lcd(0x27, 16, 2); // LCD I2C address 0x27
int Force_VAL = 0;
int temp = 0;
int btn = 0;
int buzz = 6;
void setup()
  pinMode(A0, INPUT);
  pinMode(4, INPUT);
  pinMode(buzz, OUTPUT);
  lcd.print("Force Sensor");
  digitalWrite(buzz, LOW); 

void loop()
  Force_VAL = analogRead(A0);
  btn = digitalRead(4);

 if ((Force_VAL < 550) || (Force_VAL > 650))  //Enter Force Value Range according to the item

 if (btn == 1)

 if (temp == 1)
    digitalWrite(buzz, HIGH);

 if (temp == 0)
    digitalWrite(buzz, LOW);

After uploading the code place the item on the force sensor and note the force vales range from the LCD display. Now change the Force values range in the code and upload the code again.

force sensor security alarm no item placed

Working of Anti theft Alarm System using Force sensor with Arduino

Now it time to test, Place the item and turn on the device(Arduino), when you touch or takeaway the item the buzzer starts immediately within the fraction of seconds. The Buzzer wont goes off even if you place the item again, because if the item is replaced with any fake one you will be scammed. You can reset the buzzer by pressing the push button.

force sensor security alarm item status on lcd display

If you like this project please subscribe to our YouTube Channel “Circuit Schools to encourage us to publish more interesting projects. If you have any doubts write to us from below comment section.

CircuitSchools Staff

We at CircuitSchools publish on basics of electronics and electric components and everything related to evolution of electrical technology with complete analysis of development boards and modules along with latest projects with innovative ideas.

Related Articles

Leave a Reply

Your email address will not be published. Required fields are marked *

Back to top button