ECE434 Security Camera

Team members: Seun Ladipo and Ryan Oberlitner

Grading Template
I'm using the following template to grade. Each slot is 10 points. 0 = Missing, 5=OK, 10=Wow!

 00 Executive Summary 00 Installation Instructions 00 User Instructions 00 Highlights 00 Theory of Operation 00 Work Breakdown 00 Future Work 00 Conclusions 00 Demo 00 Late Comments: I'm looking forward to seeing this.

Score: 10/100

(Inline Comment)

Executive Summary
Picture that summarizes the project. For this project we created a security camera that can be used to monitor a determined area. This is implemented with a BeagleBone Black and a PlayStation eye as the main components. We also have a manual operation mode as well as a live video feed that goes directly to a Blynk controller. Alongside this, we are also registering motion and sending a recording to a repo whenever this motion is registered. The use of this project is to, whether manually or automatically, monitor a defined area similar to surveillance cameras that are used in many places around the world today. This could serve as a replacement to a Google Nest Camera(https://store.google.com/product/nest_cam_outdoor?gclid=CjwKCAiA_MPuBRB5EiwAHTTvMb3A4UzdK2UyQnRzqudefripDsK73L7J20r-08Z_Jn4a7763-2NOFRoCSEgQAvD_BwE&gclsrc=aw.ds) priced at about $199 while our solution is priced at the price of around $90 total. It is important that we for some reason could not use bonescript in the motion detection portion of the project meaning that we could not display motion detection alongside the manual control. We will instead use Two beagles in our demonstration to show both portion of the project.

Packaging
For packaging we decided to keep is very simple as the only device we have is the camera itself alongside the BeagleBone board. We did use a custom 3D printed housing to hold the camera in place with the servo.

Installation Instructions
Github: https://github.com/16oberryan/embeddedSecurityCam

You'll need to create a Blynk app and set up an ifttt application. There are tutorials for each online, and both are free (you'll need to make an account). Ifttt is used for notifications, and uses webhooks as the trigger for the event (I used it to trigger emails with Gmail). The Blynk app is used to control the program. For full functionality, you will need to add the following widgets: Video Streaming, Joystick, and 4 buttons (don't worry, you shouldn't have to buy more energy). The first button turns on and off Motion, and should be connected to virtual pin 0. The second button turns on and off video streaming, and is connected to virtual pin 1. The third button turns on ifttt notifications, and is connected to virtual pin 2. The fourth button filters the events that cause ifttt notifications (usually one movement caused multiple triggers), and is connected to virtual pin 3. All 4 buttons should be set to be switches. The video streaming widget should be set to the system's IP address, port 8081 (format: xxx.xxx.xxx.xxx:8081) Finally, the Joystick should be set to virtual pins 4 and 5.

Next, the program has to be authorized for Blynk and ifttt. The Blynk authentification key (sent via email) should be copied into the 'AUTH' variable. The ifttt key (found in settings) should be copied into the 'key' variable.

Now it should be ready to go, just make sure the system is connected to the internet, run the code with './security.js' (without the quotes), and you should see the device go online in the Blynk app.

User Instructions
As mentioned in the installation instructions, there are several Blynk widgets that control the program. * Button (V0): Starts and stops Motion, which records any motion detected by the camera * Button (V1): Toggles video streaming to the Video Streaming widget * Button (V2): Toggles on/off ifttt event triggering when motion is detected * Button (V3): Toggles filtering when ifttt events occur, you might just want to leave this on, as without it multiple triggers are often sent to ifttt in one motion event * Joystick (V4, V5): Controls the camera via servos * Video Streaming: Shows the video stream of the camera when streaming is turned on, although it doesn't seem to refresh well when you turn streaming on. If it doesn't notice the stream, you can force it to refresh by stopping and starting the Blynk project from the app.

Highlights
Our Solution ends up at a price of around $100 with most of the price being the BeagleBone itself. This means that someone could buy two of these to monitor their home from anywhere for the same price as one google nest camera.

Theory of Operation
We are using javascript, so all of our code is event-based. When the program starts running, it first connects to Blynk, where it can be controlled from a smartphone. Using different options in the Blynk app, the program can be instructed to start or stop Motion, stream video, and send email notifications of motion detection via ifttt.

Work Breakdown
List the major tasks in your project and who did what. * Blynk integration - both * ifttt integration - Ryan * Video Streaming - Ryan * Misc. settings - Ryan * Chokidar for event detection - Ryan * PWM Joystick control - Seun * 3D printing - Seun * CAD design - Seun * hackster.io documentation - Seun

Future Work
In the future we could implement a complete housing for this project and mabey implement all weather proofing to use this outside. We would also figure out the bonescript problem and get a succinct project.

Conclusions
This project was very gratifying to implement as many of the modules in embedded software exist rather using them in conjunction with each other is where the real work is. In the future we would work on optimization of this work as the Blynk video stream has a huge delay as of now. We could also create a housing that encompasses the whole project allowing outdoor use.