ECE497 Project Home Control System

From eLinux.org
Revision as of 19:57, 8 November 2016 by Zhangb2 (talk | contribs) (Installation Instructions)
Jump to: navigation, search

thumb‎ Embedded Linux Class by Mark A. Yoder


Team members: Boyu Zhang, Bo Pang, (List all the team members here with link to their eLinux User page. Use my format.)

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

During an era of IoT(Internet of things). We thinks it is a good idea to use Beaglebone green (which works better with Grove sensors comparing to Beaglebone black)to build a home control system.

Currently, We have connected 3 Grove sensors (temperature sensor,air quality sensor and light sensor) to the Beaglebone, so that our Beaglebone can read temperature, air quality, and light intensity of its environment. We also implemented a web server base on the Work of Kervin-Lee to display all the sensor data on a webpage. Using Grove relays, We figured out how to use Beaglebone to turn on/off of a cooling pad and a heating pad which simulates controlling the cooler and heater in a house, so user now can control cooler and heater in the home remotely on a webpage. They can also set target temperature and let the Beaglebone control cooler and heater automatically.

Fortunately, we finished all our set tasks for this project before last week of this term, so there is no feature that is not working. There only problem we encountered with was when we booted the Beaglebone and run our program, the light intensity data got from the light sensor would always be 0. However, if we rerun the our program, the light sensor worked fine again.

Overall, the project is in good shape right now. Really thanks to all the demo codes that Grove Wiki provides to us. We learned a lot when making different sensors works and trying to write a web server on the beaglebone. This is a meaningful project.

Packaging

System wiring

Cape and Wiring

Because we have 7 Grove devices that are needed to connect to Beaglebone, so we decided to use a Grove Base Cape for connection. The picture on the right shows the wiring of our system.

All the names of Grove devices we used and port they connect on the cape are listed in the following table.

Grove Device Name Number of Devices Port used on Cape
Grove - Temperature Sensor 1 AIN0
Grove - Air Quality Sensor 1 AIN2
Grove - Light Sensor 1 I2C Bus2
Grove - OLED Display 1.12" 1 I2C Bus2
Grove - Chainable RGB LED 1 UART4
Grove - Relay 2 GPIO50, GPIO51

Cooling and heating system

There is no practical way that we can use the beaglebone to control an air conditioner in our home, so we chose to use a heating pad and a cooling pad to simulate the air conditioner. The following picture shows the circuit of our cooling and heating system. (Two relays in the picture are the same relays in the previous sections)

Heating and Cooling system.png

Installation Instructions

1. The python version on our bone is 2.7.9. Please first execute following command to verify python version.

bone$ python -V

You should see the following message:

bone$ Python 2.7.9

2. For this project, we use flask web framework for our web service. To install flask please execute following command.

bone$ pip install flask

3. Flask-SocketIO gives Flask applications access to low latency bi-directional communications between the clients and the server. To install it please execute following command.

bone$ pip install flask-socketio

4. The flask-socketio package relies on asynchronous services, in this project, we selected gevent. To install gevent please execute the following command. This step may takes about 10 minutes.

bone$ pip install gevent

5. In this project, we use Adafruit_BBIO and Adafruit_I2C python module for GPIO and I2C communication. Please execute the following command to install them.

bone$ sudo pip install Adafruit_BBIO
bone$ sudo pip install Adafruit_I2C

6. For controlling the LED


Give step by step instructions on how to install your project.

  • Include your github path as a link like this to the read-only git site: https://github.com/MarkAYoder/gitLearn.
  • Be sure your README.md is includes an up-to-date and clear description of your project so that someone who comes across you git repository can quickly learn what you did and how they can reproduce it.
  • Include a Makefile for you code.
  • Include any additional packages installed via opkg.
  • Include kernel mods.
  • If there is extra hardware needed, include links to where it can be obtained.

User Instructions

Once everything is installed, how do you use the program? Give details here, so if you have a long user manual, link to it here.

Highlights

Here is where you brag about what your project can do.

Include a YouTube demo.

Theory of Operation

Give a high level overview of the structure of your software. Are you using GStreamer? Show a diagram of the pipeline. Are you running multiple tasks? Show what they do and how they interact.

Work Breakdown

List the major tasks in your project and who did what.

Also list here what doesn't work yet and when you think it will be finished and who is finishing it.

Future Work

Suggest addition things that could be done with this project.

Conclusions

Give some concluding thoughts about the project. Suggest some future additions that could make it even more interesting.




thumb‎ Embedded Linux Class by Mark A. Yoder