770 likes | 901 Views
The aLife Home System. The aLife Home System. Home automation with a different approach Market flooded The all take the same approach: GUI’s that wait for user input aLife is even driven based on Temperatures Security Energy. aLife Example Event. Project Goals And Objectives.
E N D
The aLife Home System • Home automation with a different approach • Market flooded • The all take the same approach: GUI’s that wait for user input • aLife is even driven based on • Temperatures • Security • Energy
Project Goals And Objectives • Create a “smart”, customizable, all-in-one system • Little to no learning curve • Focus on passive user control • Can integrate with most homes • Simple configurations • Easily integrates with existing smart home technologies • Low cost
Project Block Diagram Zigbee Base Base Station
Remote Modules - Communications • Module Communication Network– Wireless Zigbee • More reliable, robust than wired • Flexibility in module installation location • Acceptable data rate (up to 250kbps) • Acceptable transmission range (up to 75m) • Open source, abundance of cheap hardware and software available
Remote Modules – Power Supply • Power Supply Requirement Specifications • 3.3VDC output • 9-15VDC input range • Source >= 250mA • Output ripple <= 20mV peak to peak • Work off of both 120VAC and battery • Efficiency >= 80% • Transient protection
Remote Modules – Power Supply • Power Supply Implementation: • National Semi LM2841XMK-ADJL switching buck DC-DC converter • 3.3VDC output voltage • 4.5VDC – 42VDC input range • 2mV peak to peak output ripple (simulation) • 83% efficiency under simulation • 120VAC to 12VDC step down • SMBJ12A TVS, breakdown at 13.3VDC
Remote Modules – MCU • MCU Requirement Specifications: • Operate at >= 15MHz • Have >= 32kB built in FLASH, >= 2kB built in RAM • Have at least: 2ADC, 1 UART, 1 12C, 2 PWM, 2 digital inputs, 2 digital outputs • Built in ZigBee transceiver • Available ZigBee Consumer protocol stack
Remote Modules – MCU • MCU Design Implementation • Freescale MC13213R2 • 20 MHz • 60kB FLASH, 4kB RAM • Built in ZigBee transceiver • BeeStack Consumer RF4CE compliant ZigBee protocol stack available for free from Freescale • 8x ADC, 2x UART, 1x I2C, 5x PWM, 22x GPIO • Program firmware in C using CodeWarrior IDE
Remote Modules – Base Comms • Communication with Android Base Requirement Specs • Must use a standard that is compatible with both Android base and remote module hardware • Implementation • RS232 using TI SN65C3221EPWR transceiver • Up to 1M baud rate • 15kV ESD protection • No hardware handshaking
Remote Modules – Type 1 Functions • 120VAC Power Sensor Requirement Specifications • Measure up to 1800W (max power rating for a standard wall outlet) • Resolution down to 5W at 3% accuracy • Less that 0.1 Ohm impedance on AC line • Electrical isolation between AC and digital side • Surge protection on AC side • Simple firmware calculation of power
Remote Modules – Type 1 Functions • Power Sensor Design: • Allegro Micro ACS709LLFTR-20BB-T Hall effect based AC current sensor • Measures up to 3200W • 1.1 mOhm series AC impedance • AC isolation, 2100VAC surge protection • Theoretical resolution down to 3W at 2% accuracy (still needs to be tested)
Remote Modules – Type 1 Functions • AC peak detector circuit on output of power sensor makes power calculations in firmware simple • On Semi MC33072ADR2G instrumentation amplifier for precision performance • Gain controlled via ADI AD5241BRZ1M 1M Ohm, 256 step digital Pot for power ranging from 3W up to 1700W
Remote Modules – Type 1 Functions • Temperature Sensor Requirement Specs: • Accurate to within +/- 2 degrees Celsius • Range of -30 to +100 degrees Celsius • I2C interface • Remote temperature sensor loop • Implementation • NXP SA56004ED,118 temperature sensor • Meets the above requirements
Remote Modules – Type 2 Functions • Digital to Analog Converters Requirement Specs: • Be able to change from gnd to 3.3V in 5ms • Output can drive at least +/- 50mA • DAC Implementation - PWM fed into low pass op amp circuits using Micron MCP665-E/UN dual op amp chip • Can change from gnd to 3.3V in 3ms • Output can drive +/- 90mA
Remote Modules – Type 2 Functions • Terminal Block and Relay Requirement Specifications • PTC protection for all outputs and power • TVS protection for all I/O except relay • Relay that handle 10A • Implementation • 70mA hold, 130mA trip PTCs • 400W TVS, clamp at 7.3V • 10A relay
Remote Modules – ZigBee Transceiver • ZigBee Transceiver Requirement Specifications • Transmission range of >= 30m • ZigBee Consumer RF4CE compliant protocol • ZigBee Transceiver Design • Transmission range still unknown pending antenna development • Will use Freescale’s BeeStack Consumer RF4CE compliant protocol stack, specifically designed for this MCU • Single port antenna design to minimize components
Remote Modules – PCB • PCB implementation: • We will generate a layout from our schematic in Altium and manufacture our own custom PCBs with the following target specs: • 2-4 layer boards • 3”x3” or smaller outside dimensions • Double sided component placement
Remote Modules – Successes • Remote Module Successes: • Successfully simulated power supply design • Successfully tested DACs • I have experience successfully working with Freescale CodeWarrior IDE and HCS08 MCUs (same core as MC13213)
Remote Modules – Difficulties • Remote Module Difficulties: • Due to the size and complexity of the surface mount ICs, it is impossible to prototype the modules before ordering PCBs • Wanted to implement MCU controlled light dimmer, turned out not to be worth the time, effort, and cost • The current sensor may not have accurate output response at low power (<=100W) • Working with the ZigBee protocol stack is an unknown process
Design decision - Functionality • Need a board to be able to run the android operating system. • Has to be able to handle multiple clients accessing it at the same time (up to 5). • Supports serial communication to interact with the Zigbee devices on the network
Design decision - Practicality • It’s a wall mounted unit, so the overall weight should be less than 5 pounds • Dimensions should be less than 50 cm x 50 cm x 10 cm • Needs to be powered off a wall outlet • LCD should be bigger than 2 inches to be considered easy to interact with
Microcontroller • NXP LPC3250
NXP LPC3250 Specifications • Processor – ARM926EJ-S core • Runs at 266 MHz • Meets the minimum android system requirements of 200 MHz • Memory – **Find data** • Ethernet Connectivity • Serial Interfaces • 7xUART, 2xI2C, 2xSPI, 2xSSP, 2xI2S
Picture • Need to add dimensions • 66 x 48 mm • 3.15-3.3V powering
QVGA Base Board • Embedded Artists LPC3250 Base Board • 240 x 150 mm
LPC3250 Baseboard specifications • 3.2 inch QVGA TFT LCD with touch screen panel • Ethernet connector • Powering • Can be USB powered • 9-15V DC • Other random ones • Built in speaker
Serial Communication • Main way of transferring data from the base station to the network • Problem – native android doesn’t support the communication over serial ports • Had a few choices for solving the problem, using either C or Unix.
Serial Communication: C vs. Unix Final Decision: C, because we can make use of a program called JNI which can add C programs as libraries to a Java program and allows us to import the serial data directly into Java
Difficulties/Successes • Difficulties • Serial communication not native to android • Dealing with the Zigbee protocol stack formatting when reading and processing incoming data • Finding a way to case and mount the board • Successes • Our board contains a bootable version of android on it
Specifications and Requirements Functional: • Base station must be able to accept up to 5 simultaneous service request on a first come first serve basis • Multiple request to service the same notification must only be serviced once • Must be able to add/remove/update a row in database with 98% reliability Security: • All user must have unique login; Allowed 5 unsuccessful attempts before lockout • Only registered remote client devices may have service request fulfilled by the base station Notifications: • All notifications must have a unique notification ID • Users shall only receive notifications that they are registered to receive
Design Approach and Implementation • V-Model • Proven and well structured • Allows for redesign • Android Operation System • Supports notifications • Supports secure socket communication • Database support • Eclipse IDE w/ Android Development Tools (ADT) Plug-in • Free • Best support for Android Development V – Model
Research and Design DecisionsDatabase Management System (DBMS) IBM's DB2 Express-C • Free • XML database and relational database server system • Available for Linux (32/64 bit), Windows (32/64 bit), Solaris (64 bit Intel), and Mac OS X (64 bit Intel) • Allows your server to use up to 2 Cores on your computer (1 CPU), up to 2 Giga Bytes of RAM, places no database size limits, no connection limits, and no user limits