Design Article
Home Automation: Access, automate, and secure with fewer chips
Akshat Gupta, Cypress Semiconductor
9/8/2011 3:04 PM EDT
The emerging market of home automation devices is encouraging application engineers to think of solutions that integrate number of features into a single system. Through their innovative ideas and forward thinking they try to come up with highly effective and reliable system. These system not only enable the user to access his home appliances remotely and automate his daily chores but also to think of a solution which addresses most of the his security concerns in minimum number of chips.

This article discusses such a solution and is divided broadly into 4 parts
1. Sensors:
Different sensors and their interfacing with the main controller is covered in this section
2. Communication between these sensors:
This section covers how to send signal over existing power lines and interfacing Bluetooth for wireless connectivity.
3. User Control and feedback:
Control through mobile phones using Mobile Application via Bluetooth, SMS and DTMF tones is covered in this section along with control via Internet. It also covers how the user will know whether device has started working or not once user gives ON/OFF command.
4. Security measures to prevent intrusion:
Security measures for intrusion prevention using existing sensors and surveillance cameras are covered under this section.
Sensors
Sensors are an inherent part of any system and they act as senses for that system. Let’s start with motion sensor.
Motion Sensor
This section covers motion sensing using pyro-electric sensors.
Human beings generate IR radiation. At normal body temperature, they radiate strongest in the infrared region, at a wavelength of 9.4µm. A pyro-electric sensor is made of ceramic material that generates a surface charge when exposed to infrared radiation. This property is used for the detection of motion. PIR sensor can also trigger false detection from vibration, radio interference, sunlight etc. To avoid this dual sensors are connected out of phase such that any excitation that is common to both the sensors cancels out. When a body passes in front of the sensors, it excites the first one and then the second sensor. Hence there is a change in sign of the differential output with the movement of the body from one side of the sensor to the other side. This change in sign can be used to detect motion Also to optimize for human detection, a filter window is added to limit the incoming radiation to a range of 8 µm to 14 µm range which is most sensitive to human body radiation. To improve the range and detection angle of the sensor, a Fresnel lens is used.
Fig1: Use of a Fresnel Lens
It concentrates the incoming IR radiation to the sensor. Fresnel lens has large aperture and short focal length. Figure 2 explains the interfacing circuit for PIR sensor.

Fig2: PIR sensor interface circuit
PIR sensor can be used for following purposes:
1. For controlling corridor light or any other area where light is not required continuously thus saving power.
2. Direction sensing by monitoring the differential output between the two sensing areas inside a PIR sensor
Door Sensors
Door sensor can be made using capacitive sensing; change in capacitance between two metal plates is detected and is converted into counts. The opening and the closing of the door are detected from the value of these counts.
Any conductive object has its own capacitance that is determined by its geometry and dimensions. When other conductive, non-charged objects are located close to the conductive object the electric field induces charges on these objects and increases the capacitance. The capacitance between two metal plates is calculated using the following formula:
C=A εr ε0/ D
Where
C is capacitance
A is surface area of the plates
D is the distance between two plates.
ε0 is permittivity of free space
εr is relative permittivity
Fig3: Door sensor using capacitive sensing
A small metal plate can be attached on the top portion of the door and a chip capable of sensing change in capacitance can be mounted on the wall with a close proximity to the door. When the door is closed, the capacitance will increase because of the close proximity with metallic strip. Using this method we can even detect very slight movement of opening the door.
The other method to detect whether door is open or closed is to use reed switches. Reed switch has 2 ferrous metal reeds in a hermetically sealed glass envelope. A complete wireless module can be made using a reed switch, micro-controller and a RF module. This complete module can be inserted in the door after drilling a hole. A magnet can be placed on the door such that it’s near to the sensor.
Fig 4: Door sensor using reed switch
Based upon the proximity of magnet and sensor, door position can be detected.
Glass break sensor
These sensors are used to detect any intrusion in the home through windows. There are many types of glass break sensors and they work on different principles, they can be selected based upon the cost and requirement. The basic sensor is mounted on the glass itself and they usually have a microphone, which monitors the noise and vibration coming from glass. These sensors trigger the output if the vibration exceeds a fixed threshold. Some sensors are tuned to glass shattering frequencies and some use complex algorithms to find out the glass break from one or multiple glasses. The thief because of their visibility to naked eyes can easily identify these sensors. To avoid this, other glass break sensors can be used which can be mounted anywhere on walls or ceiling and they process sound and shock in parallel and also check the duration to detect the glass break accurately.
Light intensity sensor
These sensors can be used to control the intensity of porch lights based upon the ambient light. Ambient light can be measured using a LDR. LDR is a light dependent resistor whose resistance will vary based upon the light falling upon it. In the circuit shown in figure 5, the voltage at input of ADC will vary according to incident light, thus after processing that value the intensity of porch light can be changed. If the light is LED based then it can be controlled using LED driver IC, in case of incandescent lamp the intensity can be controlled by changing the firing angle of thyristor. Generally a System on Chip with inbuilt FETs or a controller with external FETs is used to control LEDs in a lamp. The area enclosed within green line can be implemented in PPSoC, it a device with inbuilt FETs manufactured by Cypress for controlling LEDs.
Fig 5: Control of LED lamp intensity based upon ambient light
Next: Home Automation cont'd.


cAPLOCK
9/9/2011 9:41 AM EDT
Nice article. Great diagrams and concepts. Thanks, fb
Sign in to Reply
Sanjib.Acharya
9/9/2011 1:13 PM EDT
Can somebody let me know about a cheaper capacitive or some other kind of water level sensor which won't be in direct contact with water. I need to automate the pump to fill the water in the overhead water tank.
Sign in to Reply
le_snelson
9/9/2011 3:02 PM EDT
The use of visible sensors, specifically for glass break, is not necessarily a bad thing. Assuming they are tamper resistant from outside the protected area they can serve two purposes - detection and de-motivation at that point of entry. Aesthetics and connectivity costs are the more prevalent drivers for 'remote' sensing of the breakage.
Sign in to Reply
ErnieHorning
9/14/2011 10:47 AM EDT
This was a very informative article about this emerging technology. It got me excited about interconnecting devices throughout the home. Alas, there were no example circuits or links to pursue. Seeing how this is an Electrical Engineering site, it would have been very helpful if there were links to parts (maybe your own) or even just listing part numbers.
Sign in to Reply
MARCO23
9/23/2011 9:13 AM EDT
Very useful thanks
Sign in to Reply