Introduction: Home Security With Embedded System

Picture of Home Security With Embedded System

Hello Readers,

This is an Instructables for constructing an Home Security System unlike every other Security system. This system has an improved feature TRAP and PANIC Mode Connecting Victim home's owner, neighbour and Police station over network.In this project I'm demonstrating the whole project over Intranet (Closed area Network) not over Internet its your wish if you want to do the same over Internet..

PANIC MODE: (Existing System) When Intruder is detected by the Ultrasonic Sensor. the lights of the home and the buzzer will be blown up resulting the intruder panic and send a SMS notification to the Victim home's owner and his/her neighbour and a Temporary web will be hosted which holds some information about the trespass like at what time the intruder trespassed, Time elapsed after the trespass and an input field. Where the home owner can enter PIN to deactivate the buzzer and home lights remotely.

TRAP MODE:(Proposed System) When the Intruder is detected Buzzer and Lights will not blow up like existing systems.instead a SMS notification containing IP Address will be sent to police station by clicking to the IP Address a web wage will open where police can get the information like Time of trespass, Elapsed time from trespass and address of the victim home and a static google map direction from police station to victim home.And a SMS notification to neighbor and home owner will also be sent.

Things you need to build:

Software Requirement

  1. Download Arduino IDE IDE Download page
  2. Download DS3231 library Download the library
  3. Download Bridge file Download file
  4. Download Source code Download Source code

Hardware Requirement

  1. Arduino Uno Mega ATmega1280
  2. Ethernet Shield
  3. Bread board
  4. LCD 16x2
  5. Basic Servo
  6. Jumper wire Male to Male 30 to 35
  7. Jumper wire Female to Female 20 to 25
  8. Jumper wire Female to Male 10-15
  9. 4x4 keypad matrix
  10. Ultrasonic Sensor - HC-SR04
  11. Buzzer piezo
  12. LED lights 2
  13. LAN Cable
  14. Arduino board power cable
  15. RTC ds3231 module

Credential Requirement

For Receiving SMS Notification from hardware:

  1. Account SID from Twilio API
  2. Auth Token from Twilio API
  3. Temboo App key from Temboo API
  4. Sender Number from Twilio API

First of all Mount your Ethernet Shield with Arduino Uno Mega as shown in the image.

Steps from 1 to 5 will explain separate connections of module with the main arduino board.and finally your board will look like whole project as show above.

Step 1: Line Up LCD 16x2 With Arduino Board

Picture of Line Up LCD 16x2 With Arduino Board

Requirements to complete this step

  1. Arduino Mega
  2. Ethernet shield
  3. LCD 16x2
  4. Jumper Wires Male to Male

This LCD 16x2 has 16 pins in it. follow the image and Connect LCD with the arduino board.you will need some male to male jumper wires to complete this step

Step 2: Line Up Ultrasonic Sensor - HC-SR04 With Arduino Board

Picture of Line Up Ultrasonic Sensor - HC-SR04 With Arduino Board

Requirements to complete this step

  1. Arduino Board
  2. Ethernet shield
  3. Ultrasonic Sensor - HC-SR04
  4. Jumper wires Male to Female

An Ultrasonic sensor is a device that can measure the distance to an object by using sound waves. It measures distance by sending out a sound wave at a specific frequency and listening for that sound wave to bounce back and we use this Sound wave technology as intruder detector.

To cover most area with Sensor for security and reduce the cost of installing this system in real world. the Ultrasonic sensor is fixed on a Basic Servo which rotates 180 degree and covers maximum area.

Step 3 shows Line up of Basic servo and combining Ultrasonic sensor and Basic Servo together in picture

Step 3: Line Up for Basic Servo With Arduino Board

Picture of Line Up for Basic Servo With Arduino Board

Requirements to complete this step

  1. Arduino Board
  2. Ethernet shield
  3. Basic Servo
  4. Jumper wires

This Basic Servo is used for rotating the UltraSonic Sensor in 180 degree to cover maximum area for security.and then i have attached Ultrasonic Sensor above it as shown in picture

Step 4: Line Up for 4x4 Keypad Matrix, LED and Buzzer With Arduino Board

Picture of Line Up for 4x4 Keypad Matrix, LED and Buzzer With Arduino Board

Requirements to complete this step

  1. Arduino Board
  2. Ethernet shield
  3. 4x4 Keypad Matrix
  4. LED
  5. Buzzer piezo

Note: 4x4 keypad matrix has 8 pins starting from right to left facing buttons,Buzzer is only used when the Security system is running in Panic mode, and here we assume a LED as lights of the home it is also used when the security system is running in Panic mode in order to make the intruder Panic..

Step 5: Line Up for RTC DS3231 With Arduino Board

Picture of Line Up for RTC DS3231 With Arduino Board

Requirements to complete this step

  1. Arduino Board
  2. Ethernet shield
  3. RTC DS3231
  4. Jumper wires Male to Male

Note: RTC (Real Time Clock) module takes care about the time as just like how our desktop or laptop takes care about time even when your laptop is off for a while.It will display the correct time when you power on your laptop.

In the same way RTC module functions. So to get started with RTC module for the first time you have to setup a time in the beginning. I will share a video on setting up Time in your RTC module and once to setup the time you need not have to do it again and again Getting Started With DS3231 RTC Module.

Step 6: Lets Configure Software Environment

Picture of Lets Configure Software Environment

As per the Requirements discussed in introduction you should download Arduino IDE, ds3231 library, the batch file and download the source code.

  1. After downloading Arduino IDE launch it. Click sketch > include library > Manage Libraries > Search for "Keypad" then select "Keypad by Mark Stanley" and click Install
  2. Again Click > sketch > include library > Add .ZIP library > Select for ds3231 Zip file and import it.

Step 7: Lets Get the Credentials Requirments

Picture of Lets Get the Credentials Requirments

As mentioned in the Introduction you require your own credential to run the project, like

  • Twilio Account SID
  • Twilio Auth Token
  • Temboo app key and
  • A sender number from Twilio.
  1. Sign up into Twilio website Twilio Site you will see your Account SID and Auth Token on your console page.
  2. then go to programmable SMS >click on build and learn click on "GET A NUMBER" where you can get your Unique Sender number and from this unique Sender number you will receive SMS Notification when Intruder is detected.
  3. Then you have to register your SMS receiving phone number in Twilio for that click "Phone Numbers" >click Verified Caller IDs > click plus button to add your mobile number to get the SMS notification.
  4. Copy this this credentials and then sign up into Temboo API website Temboo API site. In the Left hand side under Choreos click on Twilio > click SMS Messages > click SendSMS. Then you will see a Input fields for Account SID, Auth Token,Body, From and To.
  5. Enter all those credentials right there and enter that unique Sender number in "FROM" field
  6. Click "Run Now"

You will receive a notification.

NOTE: You should get a "FROM" unique Sender number and "TO" register your phone number to get the SMS notification.

Step 8: Lines of Code Where You Will Need to Enter Your Credentials.

Picture of Lines of Code Where You Will Need to Enter Your Credentials.

Here i will mention the lines where you need to Enter your credentials inside the source code.

  1. In Five places you will need to replace your "Account SID key" (Line no: 440,467,495,525,554)
  2. In Five places you will need to replace your "Auth Token key" (Line no: 432,459,487,517,546)
  3. In Five places you will need to replace your "TO" number (Line no: 434,461,489,519,548) Paste Your phone number which should be registered in "Verified caller IDs"
  4. In Five places you will need to replace your "FROM" number (Line no: 436,463,491,521,550) Paste Unique Sender number which you got from twilio.
  5. In TembooAccount.h file #define TEMBOO_APP_KEY "#Paste your App key here#" You can get your App key from your Temboo Account

Once you have pasted your credential in the given LOC (line of codes) you are good to execute your code.

Step 9: Bridge Connection

Picture of Bridge Connection

Now Select LAN adapter and the source of internet right click then click bridge connections. This will bridge a Intranet connection between your laptop and Ethernet shield constituting a closed network ( Intranet )

After bridging connections you should open and close Batch file which you downloaded at STEP 1.

Step 10: Final Instruction

Picture of Final Instruction

plug your Arduino power cable with your laptop and LAN cable from your laptop LAN port to Ethernet shield LAN port and then CLick "upload" it will take 5 mins to get uploaded.

Once its uploaded the program will start executing DHCP IP address will be obtained then it will ask for PIN to enter

  1. TRAP MODE PIN "A33333"
  2. PANIC MODE PIN "B66666"
  3. DEACTIVATE PIN "D00000"

According to the PIN entered the system will start running.

You can change PIN as your wish by editing the Source code.

Step 11: Panic Mode Results

Picture of Panic Mode Results

Once an Intruder is detected Buzzer and LED (as home lights) will blow up and SMS notification will be sent to Neighbour and Home owner as shown in picture, and a temporary web will be hosted only for home owner, The address of the web will be sent to home owner via the SMS notification

The Screenshots of web is posted above.

Step 12: Trap Mode Results

Picture of Trap Mode Results

Once an Intruder is detected no Buzzer and lights will blow up instead SMS notification will be sent to Neighbour, Home owner and Police Officer as shown in picture, and a temporary web will be hosted only for home owner and Police officer the information which the web holds is posted above as picture and also explained in introduction part, The address of the web will be sent to home owner and Police officer via SMS notification.

The SMS notification hold information like

  1. Address of webpage
  2. Google map direction link from police station to the victim home

The Screenshots of web is posted above.

Advantages of this System

  1. New way to secure your home, remotely with instant action of police and your neighbour
  2. Very less implementation cost
  3. Encourages Digital Security
  4. Gives no excuses for Police for not taking action against robbery because the record of robbery are digitally notified on the spot.
  5. Reduce rate of robbery.

Disadvantages of this System

  1. Figure out by yourself :)

Author's:

  1. Baseem-ud-din Hakeem
  2. Neha Tazeen

Comments

UncleEd (author)2017-11-27

You might check the laws in your area before implementing the proposed system. Some places don't allow burglar alarms and automated systems to contact the emergency services directly. The alarm is supposed to connect to an alarm company. They're supposed to verify it's a real alarm (call your cell phone or a neighbor or something) and then notify the emergency services.

Baseemu (author)UncleEd2017-11-28

You are right Mr.UncleEd but in my country emergency services are for emergencies.Yes lots of fake claim happens here for example in highway side SOS system to rescue accidents cases. we should think to minimize fake help claims..

Thank you.

UncleEd (author)Baseemu2017-11-28

I like the automated system and the way you implemented it. Where we differ is the agency it should call.

The problem has been that over the years less-sophisticated automatic systems tripped on power outages or powerline surges. Then the emergency phones would get saturated with automatic calls that were not emergencies.

Where I lived years ago, they had about a dozen operators to handle 50-60 incoming phone lines in an area with 50,000 people. During bad weather, the phone lines would get tied up with false alarms up so real emergencies calls could not get through. Worse yet, if the calling line did not hang up, it kept the line from becoming available for an extended period of time. They passed an ordinance prohibiting automatic dialing into the emergency number.

Before the prohibition, some automatic systems also reported one alarm when the alarm was for something else. I was a firefighter and one time we were sent to to a house with an alarm and were walking around looking for signs of a fire. Then the dispatcher told us to pull back because it was an error and was a burglar alarm. We would hope the alarm company would have a human to check the real nature of the alarm.

Famo12 (author)2017-11-23

Great Use Of Technology to Solve Real Problems as well as by applying new Innovative Solutions

Baseemu (author)Famo122017-11-24

thanks for your appreciation

JananiS13 (author)2017-11-23

Congrats...nice work Baseem

Baseemu (author)JananiS132017-11-24

thank you

nehataz (author)2017-11-23

Grt work and clearly explained !! it will be very helpful thanks:)

Baseemu (author)nehataz2017-11-24

Thanks a lot for your contribution.

RayeezK (author)2017-11-22

Very well done!

Baseemu (author)RayeezK2017-11-24

Thanks manh,

misterxp (author)2017-11-23

Great! Thanks!

Baseemu (author)misterxp2017-11-24

Welcome :)

khudsiyat1 (author)2017-11-22

well done !!! u have did exactly as i taugt you..good..

Swansong (author)2017-11-22

That's a neat setup :) Thanks for sharing!

About This Instructable

1,575views

34favorites

License:

More by Baseemu:Home Security With Embedded System
Add instructable to: