Back to Parent

Outcome


Proposal

This project includes a motion sensor for home security system, and detects when someone is your home/room when they shouldn’t be. When a movement is detected, the alert is displayed through a LED flashing as an indicator of a threat. It also has an ON/OFF button which enables the user to turn the motion detector on when they want to activate it when leaving their room or vice versa. It is a personalized device because it enables notifications to be sent only to the user in alert cases.

Problem Statement

The project is designed for my best friend who is having problems with her house mate due to privacy issues. I've chosen this problem because I can empathize with my best friend since I also live with house mates. I think everybody deserves personal space, so I would like to make a house mate detector for her.

Goal

The goal is to build a room security system and detect when someone is your room when they shouldn’t be. When a movement is detected, the alert is displayed through a LED flashing as an indicator of a threat and a notification is sent to the user. This way the process of realizing if someone has entered your room is streamlined and invading one's room without permission is prevented to some extent.

Process

Components:

  1. Breadbord x1
  2. Particle Photon x1
  3. PIR Motion Sensor x1
  4. LED x1
  5. 1 kOhm resistor x1
  6. Push Button x1
  7. Jumper Cables x6
  8. Smartphone x1

Building Phase:

Steps:

1. I wired up an LED as an indicator for a motion detection.  The LED is used to show that the motion sensor is working.

2. I wired up a PIR sensor to detect any motion. 

3. I wired up a simple push button and used that as an ON/OFF button for the motion detector device. When the button is pushed, the device is OFF meaning that even though there is motion, it does not give any indication to the user. When it is not pushed, the device is ON, meaning that LED flashes and a notification is sent to the user when a motion is detected.

4. I enabled the product to publish an event to Particle Cloud every time a motion is detected. I needed to ensure that when the device is OFF (Push button is pressed), it shouldn't publish any event to the cloud. It should only publish when the device is ON. (Push button is not pressed.)

5. I downloaded IFTTT app to send notification to the user's phone every time motion is detected. I connected IFTTT with Particle Dev and built the IFTTT scenario. 

Start simulating
Show Advanced Options
Img 2976
Show Advanced Options
Img 2978
Show Advanced Options
Screen shot 2018 01 31 at 21.03.56
Show Advanced Options
Screen shot 2018 01 31 at 21.23.50
Show Advanced Options

Challenges

The PIR sensor I used was too sensitive, therefore it was difficult for me to test accurately and see if my code and circuit were working as I planned. I tried to reduce its sensitivity and reduce the field; however it was hard since I did not how much to reduce. 

It was also challenging for me to embed the code for the push button into my initial code. The Particle Dev gave me several errors until I found out how to write an if statement for the push button to operate correctly. 

Outcome

The device works successfully. After completing my fully-working device, I learned that IR sensor is better in terms of sensitivity than PIR sensor. I also learned thinking very basic and simple is better when writing a code. Drawing a flow chart of the tasks I want to accomplish with my code has helped me a lot to modify my code. Finally, I learned being patient and keeping myself motivated during coding! Public sources for codes has helped me a lot to build my code. 

Next steps:

1) Try with a IR sensor.

2) Try alternative ways to make the sensor less reactive to external factors, such as running the sensor through a tube (cardboard or PVC) to reduce the sensor to a narrowor beam of detection.

3) Add buzzer to put the house mate invading your personal space in panic.

Reflection

This was my first IOT project and I enjoyed it a lot! First, I thought it would be easier to create a connected device; however I think internet resources and collaboration makes it easier to build connected devices. Also, the project was very open-ended, so I could build it around a fun use case and make it personalized. 

One of my goals was to learn the fundamentals of code writing. However, I still feel like I need to spend more time to understand the basic structures behind coding. I need to work more on my coding skills in order to build codes truly on my own. However, I feel I have progressed to a great extent. 

Overall, I feel very happy about my project. I realized that with few wires and a small breadboard, many tasks and useful and fun scenarios can be accomplished. 

I am planning to integrate IOT more into my life and make my day-to-day life easier through pulling data from cloud and exposing them to my routine in certain situations. I'll brainstorm on creative use cases!

Show Advanced Options
Drop files here or click to select

You can upload files of up to 20MB using this form.