Custom Search
 Hi
Featured Services
Tutorials on Embedded
System Design .
Tutorials on
Antenna Design.
Tutorials on
Image Processing Using
Open-CV.
read more

PROJECTS WITH CODE

HELP SHARE IDEAS.COM
Mail us at : info@helpshareideas.com

:Uploaded on Monday 24th OCT 2016

Zigbee Based Home Automation - Monitoring & Controlling using ARM7 LPC2148

The aim of home automation is to control home devices from a central control point. In this project, we present the design and implementation of a low cost but yet flexible and secure Zigbee based home automation system.The communication between the devices is wireless. The protocol between the units in the design is enhanced to be suitable for most of the appliances. The system is designed to be low cost and flexible with the increasing variety of devices to be controlled.

Automation is today’s fact, where more things are being completed every day automatically, usually the basic tasks of turning on or off certain devices and beyond, either remotely or in close proximity. The control of the devices when completely taken over by the machines, the process of monitoring and reporting becomes more important Depending on the location of its usage, automation differs in its name as industrial automation, home automation etc. With the development of low cost electronic components home automation migrated from being an industrial application to home automation. The home automation, our point of concern deals with the control of home appliances from a central location.

Development of data acquisition is the process of gathering signals from the remote sources and digitizing those signals for storage, transmission and analysis. Data logging, carried out by a data acquisition system (DAS), is used to measure real world parameters in real time. In this system data logging systems consists of measuring outputs (sensors). In this project microcontroller collects the data continuously, and sends to zigbee at other end data is received by zigbee receiver and sends to data at pc it continently updates the different sensors data and controls the devices connected to the arm 7 microcontroller.

The devices that are to be controlled are connected to the arm 7 microcontroller. The status of the device is sent via wireless network using zigbee that is being accessed by the user at the remote side. The commands given by the user at the remote client will be received by the microcontroller through zigbee at other end and get executed. This way control of the devices will take place.

Objective of the project

The main principle of this project is controlling and monitoring the devices in an industry using zigbee technology which is a wireless technology. Here we are using the zigbee transceivers which are used to send and receive the data. First of all, the ADC 0809 is connected to the three channels from the three sensors. Here the ADC is inbuilt in arm 7 microcontroller. The microcontroller sends the data to the zigbee transceiver at transmitter side and it is collected by the zigbee transceiver at the receiver side because it is a wireless network and then sent to arm cortex processor which is used as a serial to Ethernet converter and the values are displayed on the PC in the form of web page. Here the two devices are connected to the controller by the help of relays which are connected through the ULN 2003.The sensor values are displayed in the webpage and through this we can control and also monitor the devices.

About ARM 7- LPC 2148

The LPC2141/2/4/6/8 microcontrollers are based on a 32/16 bit ARM7TDMI-S CPU with real-time emulation and embedded trace support, that combines the microcontroller with embedded high speed flash memory ranging from 32 kB to 512 kB. A 128-bit wide memory interface and unique accelerator architecture enable 32-bit code execution at the maximum clock rate. For critical code size applications, the alternative 16-bit Thumb mode reduces code by more than 30 % with minimal performance penalty. Due to their tiny size and low power consumption, LPC2141/2/4/6/8 are ideal for applications where miniaturization is a key requirement, such as access control and point-of-sale. A blend of serial communications interfaces ranging from a USB 2.0 Full Speed device, multiple UARTS, SPI, SSP to I2Cs and on-chip SRAM of 8 kB up to 40 kB, Make these devices very well suited for communication gateways and protocol converters, Soft modems, voice recognition and low end imaging, providing both large buffer size and high processing power. Various 32-bit timers, single or dual 10-bit ADC(s), 10-bit DAC, PWM channels and 45 fast GPIO lines with up to nine edge or level sensitive external interrupt pins make these microcontrollers particularly suitable for industrial control and medical systems.

Zigbee Based Home Automation

In this project microcontroller collects the data continuously, and sends to zigbee at the other end data is received by zigbee receiver and sends to data at pc it continuosly updates the different sensors data and controls the devices connected to the arm 7 microcontroller.

The devices that are to be controlled are connected to the arm 7 microcontroller. The status of the device is sent via wireless network using zigbee that is being accessed by the user at the remote side. The commands given by the user at the remote client will be received by the microcontroller through zigbee at other end and get executed. This way control of the devices will take place. In our Project demo we are giving input as temperature to inbuilt ADC of LPC 2148 by using LM35 sensor. The Device we have selected is heater. Depending on the temperature above the ref or below the ref the device will be switched on or off.

Components required for the Project

    Below Components are used while designing the project
  • ARM 7 LPC 2148 - 1 no.
  • ZIGBEE TRANSRECEIVERS - 2 no.
  • Temperature Sensor LM35 - 1 no.
  • Humidity Sensor - 1 no.
  • LED Bulb - 1 no.
  • DC Motor - 1 no
  • ULN 2003 IC and L293D IC -1 no
  • Relay - 3
  • Breadboard and Connecting Wires

Block Diagram for the proposed Zigbee Based Home Automation - Monitoring & Controlling using ARM7 LPC2148

HelpShareideas- Project with Codes image
Fig 1: Receiver side of Zigbee based Home Automation

HelpShareideas- Project with Codes image
Fig 2: Transmitter side of Zigbee based Home Automation

Using Zigbee based home automation, the automatic control and monitoring of the home devices can be done. For example, in our demo we are using the Heater.

In this demo we are first sensing the temperature level of the heater by using LM35 sensor , which it senses and then it is converted into analog output which is fed as input to the inbuilt ADC in LPC 2148. LPC 2148 sample it and converts to digital form which is in Hex form. The Digital value of the resulting value is compared with the predefined programmed reference value. Based on the result we decide Temperature is below the reference or it will be above the reference value. If the temperature is below the reference value we keep on sensing the temperature of the heater and heater is kept on, when the temperature is above the reference then the sensor senses it and a message is seen confirming the same. The Heater is turned off if it is required, that is if the temperature is above the reference value.

ADVANTAGES

    Home automation brings a variety of benefits, depending on the application areas.These potential benefits include:
  • Easier lifestyle
  • Convenience of flexible control and remote control
  • Increased safety around the home.
  • Improved security of the home.
  • Energy savings with associated cost savings and environmental benefits.

APPLICATIONS

    Home automation brings a variety of benefits, depending on the application areas.These potential applications include:
  • Lighting :
  • Lighting systems can be implemented with the following functionality:
    • Control lights from various points, including wall-switches, occupancy sensors, remote control units, smart phones, and computers
    • Control lights in terms of brightness and colour (for colour lamps) .
  • Heating, Ventilation and Air-Conditioning (HVAC) :
  • HVAC systems can be implemented with the following functionality:
    • Control heating and/or air-conditioning from various points, including wall mounted control units, thermostats, occupancy sensors, remote control units, smart phones and computers.
    • Control the heating and/or air-conditioning in individual rooms according to their use and/or occupancy.
    • Control a pre-defined group of heaters or fans by a single action.
  • Shades and Window Coverings :
  • The control of shades and window coverings (blinds and curtains) can be implemented with the following functionality:
    • Control shades and window coverings from various points, including wall mounted control units, remote control units, smart phones, and computers.
    • Open/close shades and window coverings, including partial opening/closing.
  • Security Systems :
  • Security systems can be implemented with the following functionality:
    • Control the security system from various points, including wall-mounted control units, remote control units, smart phones and computer.
    • Control a pre-defined group of security sensors or door locks by a single action Energy savings with associated cost savings and environmental benefits.

Zigbee Trans-receiver

ZigBee is a specification for a suite of high level communication protocols used to create personal area networks built from small, low-power digital radios. ZigBee is based on an IEEE 802.15 standard. Though low-powered, ZigBee devices can transmit data over long distances by passing data through intermediate devices to reach more distant ones, creating a mesh network; i.e., a network with no centralized control or high-power transmitter/receiver able to reach all of the networked devices. The decentralized nature of such wireless ad hoc networks make them suitable for applications where a central node can't be relied upon.

ZigBee is used in applications that require only a low data rate, long battery life, and secure networking. ZigBee has a defined rate of 250 kbit/s, best suited for periodic or intermittent data or a single signal transmission from a sensor or input device. Applications include wireless light switches, electrical meters with in-home-displays, traffic management systems, and other consumer and industrial equipment that requires short-range wireless transfer of data at relatively low rates. The technology defined by the ZigBee specification is intended to be simpler and less expensive than other WPANs, such as Bluetooth or Wi-Fi.

ZigBee networks are secured by 128 bit symmetric encryption keys. In home automation applications, transmission distances range from 10 to 100 meters line-of-sight, depending on power output and environmental characteristics.

ZigBee is a low-cost, low-power, wireless mesh network standard. The low cost allows the technology to be widely deployed in wireless control and monitoring applications. Low power usage allows longer life with smaller batteries. Mesh networking provides high reliability and more extensive range. ZigBee chip vendors typically sell integrated radios and microcontrollers with between 60 KB and 256 KB flash memory.

ZigBee operates in the industrial, scientific and medical (ISM) radio bands: 868 MHz in Europe, 915 MHz in the USA and Australia and 2.4 GHz in most jurisdictions worldwide. Data transmission rates vary from 20 kilobits/second in the 868 MHz frequency band to 250 kilobits/second in the 2.4 GHz frequency band.

Working of the project

The project working model is made by using the ARM7 Processor namely LPC 2148. And we have used KEIL software tool with Embedded C language to carry out the simulation of programs.

After the simulations of the programs, the code has been downloaded on to LPC kit using LPC flash utility Software. Similarly the Flash Magic software tool which is developed for NXP Semiconductors is used for checking the received messages from ZIGBEE transceiver which is connected to the PC. And also using the Flash Magic the data is sent from ZIGBEE transceiver to another ZIGBEE transceiver connected with LPC 2148. In below code, At present only temperature is sensed using LM35 data hence we are controlling the Heater .

HelpShareideas- Project with Codes image
Fig 3: Hardware Implementation of Zigbee based Home Automation (Tx part)

Code for the Implementation of the Project

We have given the code in the below attached page. We will discuss about how to create a project, debug it and create a Hex file. Once Hex file is generated , how to upload it to the Arm 7 board in Tutorials Section.

< Click the link ZIGBEE BASED HOME AUTOMATION to open the code for the Zigbee Based Home Automation - Monitoring & Controlling using ARM7 LPC2148 to access the codes Page:>

Note : We will soon update tutorial page. You Can Learn how to create a Project using Arm 7 - LPC 2148 using those demos.

Editor: HelpShareIdeas.com

For giving feedback on this article please mail us at : info@helpshareideas.com

<: Click the link PROJECTS with Code to access the Latest Projects with codes Page:>