Design of smart home controller based on ARM and ZigBee technology

Publisher:天涯拾遗Latest update time:2012-04-10 Source: 维库开发网 Keywords:ARM Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

ZigBee is an emerging short-range, low-complexity, low-power, low-data-rate, low-cost wireless network technology that has broad application prospects in many fields.

Smart home is a multifunctional integrated technology system. It uses the family residence as a platform and utilizes advanced computer technology, communication technology, network technology, control technology, and information technology to organically connect various electrical appliances in the home through some form of network, conduct networked integrated management and regulation, and provide people with a comfortable, safe, convenient, environmentally friendly and efficient living environment.

The smart home controller introduced in this article uses ZigBee technology to connect many relatively independent household appliances in the home into a unified smart home system, so as to facilitate local operation of various electrical appliances in the home, and also to realize remote control of various electrical appliances through the Internet or GPRS system.

1 Introduction to ZigBee Technology

ZigBee technology is a wireless connection technology that has gradually developed in recent years and has great market potential. It was born to meet the requirements of low-power, low-data-volume and low-cost wireless networks. It is based on the 80211514 standard of the IEEE Wireless Personal Area Network (WPAN) Working Group and is called the ZigBee technology standard.

The complete ZigBee protocol consists of the application layer, application convergence layer, network layer, data link layer and physical layer, as shown in Figure 1.

Design of smart home controller based on ARM and ZigBee technology

The IEEE80211514 standard defines the physical layer (PHY) and the data link layer (MAC); the protocols above the network layer are developed by the ZigBee Alliance, and the application layer includes the application support sublayer (APS), ZigBee device object (ZDO) and application objects developed by manufacturers.

ZigBee relies on independent working nodes, uses wireless communication, and forms three network structures: star, mesh, and cluster through self-organization. Therefore, the functions of each node are not exactly the same. In order to reduce the cost of the system, IEEE80211514 defines two types of physical devices: full-function device FFD (Full Function Device) and reduced function device RFD (Reduced Function Device). FFD nodes have the functions of controllers, provide data exchange, can be used as network coordinators, routing nodes, and terminal nodes, and can communicate with any type of device in the network; RFD can only be used as a terminal node and can only communicate with FFD. Two RFD nodes cannot communicate with each other.

Zigbee, a wireless communication technology, has the characteristics of short distance, low complexity, low power consumption, low data rate, low cost, safety and reliability, large network capacity, self-organization, and strong self-healing ability. It can be widely used in multiple technical fields and has broad market prospects.

2 Design of smart home controller based on Zigbee technology

The network communication of the smart home system has the following characteristics:

① The amount of data transmitted is small, and a very fast transmission speed is not required; ② The network capacity is large to meet the needs of various household appliances in the home; ③ The information is real-time and has short delays.

ZigBee's technical features determine that it can well meet the above requirements of smart home networks, especially its self-organization and self-healing capabilities. Such wireless communication technology is an ideal communication method for smart home systems. [page]

2.1 Basic composition of energy-saving home system

The smart home system can realize information interconnection through GSM/GPRS/CDMA/network, ZigBee personal area network, Internet and community information network. Users can control home appliances and lighting devices through mobile phones outdoors, and can also get alarm information such as anti-theft, fire prevention, and gas leakage prevention in time; at home, they can control home appliances through remote controls. The controller also has the function of indoor host of the video intercom system, which can check various information released by the community and send alarm signals to community security when necessary. The system mainly consists of a smart home controller and several indoor monitoring ZigBee function modules. The system model is shown in Figure 2. The smart home controller realizes information interconnection with external facilities through two wireless communication networks, the Internet and two wired communication lines, so the smart home controller can also be regarded as a digital home gateway.

Design of smart home controller based on ARM and ZigBee technology

The smart home controller is equipped with a mobile phone module, which can send and receive two-way short messages with the user's mobile phone through the GSM (GPRS, CDMA) mobile communication network. Users can control the power switch, dimming and speed control of household appliances through mobile phone short messages; the controller sends alarm signals to the user's mobile phone in the form of mobile phone short messages for anti-theft, fire prevention, gas leakage prevention and home emergency alarm.

The controller is equipped with a ZigBee module, which communicates with the monitoring devices in the home through the Zig2Bee wireless network and is used as a ZigBee network coordinator (FFD). It is responsible for establishing the smart home ZigBee network, receiving instructions sent by the system control center, and making corresponding processing. At the same time, it also sends the data received from the routing node (FFD) or the terminal node (RFD) to the system control center.

Indoor monitoring equipment can be divided into three categories according to their uses: the first category is switches and sockets. The simplest sockets realize the power switch control of household appliances (such as rice cookers, water dispensers, TVs, refrigerators, air conditioners, washing machines, electric curtains, and lamps that do not require dimming) by turning on and off small electronic switches; more complex intelligent switches and sockets have the function of adjustable output power, which is used for dimming of chandeliers, floor lamps or speed regulation of electric fans. The second category is sensor products, among which pyroelectric infrared sensors and door magnetic sensors are used for anti-theft, smoke sensors are used for fire prevention, gas sensors are used for gas leakage prevention, and manual alarm buttons are used for emergency alarms (such as sudden illness of lonely elderly people). These nodes are equipped with ZigBee modules as terminal nodes (RFD) of the network. The third category is handheld remote controls, which, in addition to realizing the switch control, dimming and speed control of household appliances, also have the functions of lighting scene setting and control.

If the community is equipped with a property management communication network and a door access intercom system, the controller also functions as the indoor host of the video door access intercom system.

The LCD screen on the controller can display the visitor's image and conduct intercom or unlocking operations with the visitor. In addition, the controller can receive various text messages sent by the community property management; when an accident occurs indoors, it can send an alarm signal to the community property management.

The controller is equipped with an Internet interface, which allows users to control the operation of home appliances through the Internet when they are away from home, and monitor events happening at home. The advent of the next generation of the Internet will provide great support for the application of this function. By then, each home appliance and the controller itself will have its own static IP address, thus becoming a member of the network.

ZigBee's cluster network combines the characteristics of star and mesh structures. In practical applications, we use smart home controllers and ZigBee sensor nodes to form a cluster network. It has good scalability. For users of large apartments or villas, the network coverage can be expanded by adding routing nodes; for users of small apartments, the network can be reduced to form a star network to save energy and speed up data transmission.

2.2 Hardware Design of Smart Home Controller

2.2.1 Introduction to Smart Home Controller

The core component of the smart home system is the smart home controller. Its block diagram is shown in Figure 3. It is centered on an embedded processor and consists of a mobile phone module, a ZigBee module, and necessary auxiliary interfaces. The smart home controller is the control center of the entire smart home system. Its hardware core is the central processing unit. All tasks such as device control, task scheduling, communication protocol conversion, data transmission and reception, and data management require the central processing unit. Considering the functions, scalability, operating system support, and power consumption, we choose the powerful 32-bit ARM9 microprocessor S3C2410X as the main processor, and the memory uses 64M NAND Flash and 64M SDRAM.

In terms of human-machine interface, a 5-inch TFT LCD screen is used and equipped with a corresponding touch screen. It can be used to display visitor images and various information sent by the community property management, and allows users to easily input data to control various home appliances. In addition, in order to make the control method more flexible, the keyboard interface is designed using the processor's I2C bus interface, so that various control and alarm methods can be expanded.

The controller has two communication modules: mobile phone module and ZigBee module. The mobile phone module consists of a host module, a SIM card interface, an audio part and a radio frequency part, and uses the SIM300 chip (GPRS module) produced by SIMCOM. The standard RS-232 interface is used for data transmission with ARM, and the module is operated by using AT commands to realize the sending and receiving of short messages. The Zigbee module collects the operating status of various household appliances and receives various fault alarm information, and transmits data with ARM through the RS-232 interface.

The controller is equipped with an Ethernet interface. With the Web server built on the controller, users can monitor the home environment and various home appliances through the Internet. The RS-485 interface in Figure 3 is used to communicate with the community property management (coordinated with the original community network. If it is a new community, the Ethernet interface can be used directly). Using MAX3232, the two USART transceivers of ARM9 are combined into two RS-232 ports and one RS-485 port.

The audio interface is composed of the IIS bus interface inside the microprocessor and the external audio digital signal encoder chip (UDA1341TS).

The video interface uses SMIC's DSP chip to convert the video signal into a JPG file format or binary image stream that can be processed by the microprocessor, and then send it to the LCD screen for display after processing. [page]

Design of smart home controller based on ARM and ZigBee technology

2.2.2 Zigbee module in home controller

The ZigBee module adopts the full-function device (FFD) type. It plays the role of network coordinator in the smart home system and can provide two-way transmission of information to connect other reduced-function devices (RFD) in the smart home system.

This module uses Chipcon's CC2430 chip, which uses the architecture of the previous CC2420 chip and integrates the ZigBee radio frequency (RF) front end, memory and microcontroller on a single chip. It uses an 8-bit MCU (8051) with 128KB programmable flash memory and 8KB RAM, and also includes an analog-to-digital converter, 4 timers, AES-128 coprocessor, watchdog timer, sleep mode timer with 32kHz crystal oscillator, power-on reset circuit, power-off detection circuit, and 21 programmable I/O pins.

The CC2430 chip is produced using 0118μm CMOS technology, and the current consumption during operation is 27mA; in receive and transmit modes, the current consumption is less than 27mA or 25mA respectively. The CC2430's sleep mode and ultra-short time to switch to active mode are particularly suitable for applications that require very long battery life.

CC2430 has two powerful US2ART communication interfaces that support several protocols. Through one of these communication interfaces, the S3C2410X processor can write or read configuration information to CC2430, and can also send and receive data.

The CC2430 chip integrates functions such as CRC and data integrity check, which reduces the workload of programmers, speeds up communication, and reduces energy consumption. At the same time, the chip also uses CS2MA-CA technology to avoid competition and conflict when sending data, reducing some unnecessary energy consumption. Therefore, the CC2430 chip has ultra-low energy consumption, its service life can be calculated in years, and it is cheap, which meets the characteristics of sensor networks that require a large number of distributed nodes.

The controller uses the Zigbee module to collect the operating status of various household appliances and receive various fault alarm information through the RS-232 interface.

2.3 Functions of the home controller

The operating system of the smart home controller uses an open source embedded Linux operating system, which is ported to the controller hardware platform after being tailored. The smart home controller integrates Linux, ARM system, mobile phone module and ZigBee module into a whole, forming a fully functional embedded system, and using ZigBee technology to easily achieve wireless connection of multiple nodes within the home.

The functions of smart home controller are

(1) Using ARM architecture 32-bit embedded RISC processor and open source embedded Linux operating system;

(2) It is the control center of the smart home control system and the gateway of the information appliance platform in the home system;

(3) In case of theft or illness, press the emergency button to automatically report the incident to the management center;

(4) Configured on a family basis, using an LCD screen to display community notifications, the working status and data of each part of the system;

(5) Use ZigBee sensor nodes to monitor various fault alarm data (fire, gas leakage, etc.) and automatically send them to users or community management centers through mobile phone modules;

(6) Communicate with the community management center via Ethernet (or RS-485);

(7) Communicate with each sub-node in the home system through the wireless ZigBee module on the controller to control various home appliances accordingly;

(8) Users can remotely monitor various home devices at home via the Internet.

The smart home controller collects the operating status of various household appliances through the Zigbee module and stores various fault alarm data in the database; it gives priority to fault alarms, automatically sends short messages to the user's mobile phone or community property management through the mobile phone module, and stores the on-site data in real time in the database for further analysis and statistics of various information. Here, the database becomes the middleware connecting the front and back ends, storing status data for remote monitoring and local LCD display, while receiving browser and local keyboard input, and the communication program and CGI program complete the download of control commands and upload of operating status; at the same time, the database also needs to realize fault analysis, statistics and query. In this system design, we use the embedded database SQLite to meet the requirements of system remote control data transmission and data sharing.

The software of the controller is mainly divided into four modules: the communication program with the data acquisition interface, the fault alarm program, the local human-computer interaction program and the remote control program. In order to enable users to control the smart home network through a browser on the Internet, it is necessary to set up a Web server on the controller (digital home gateway) to communicate with the user and call the background CGI program through the CGI interface. The CGI program establishes a connection between the Web server and the control program, calls the specific control program, and implements the specified operation of the internal nodes of the smart home network. It monitors the network, knows the status of the devices in the network anytime and anywhere, and controls various devices in the network. Network monitoring is also very important in the home network, allowing users to understand the status of the network at any time, such as the entry and exit of devices, device failures, etc.

3 Conclusion

ZigBee technology fills the gap in the low-cost, low-power and low-rate wireless communication market. The smart home controller hardware consists of an advanced ARM9 embedded system, a mobile phone module and a ZigBee module; the operating system uses embedded Linux, and the home network uses a ZigBee wireless network, which has good security and complete system functions, and can meet the needs of future smart home development.

Keywords:ARM Reference address:Design of smart home controller based on ARM and ZigBee technology

Previous article:Design and implementation of remote wireless monitoring system based on ARM
Next article:Implementation and Application of MODBUS Protocol Based on ARM Cortex-M3

Recommended ReadingLatest update time:2024-11-16 17:54

ARM platform cross compilation | OpenSSL
Compilation steps Prepare Compilation platform OS: Ubunti16.04 Cross compiler Compiler: aarch64-linux-gnu-gcc Openssl: openssl-3.0.1 Compile Configuration ./Configure --prefix=/dir/to/install --cross-compile-prefix=aarch64-linux-gnu- -no-asm shared prefix: openssl installation directory –cross-compile-prefix: Cross
[Microcontroller]
Design of Reconfigurable CNC System Based on ARM
introduction     The openness, reconfigurable design, modularization, and networking of CNC systems are the hot topics in the current research of CNC technology. The technical essence of open CNC is standardization. Its goal is to separate the complex CNC technology product system and form recognized modular compone
[Microcontroller]
Design of Reconfigurable CNC System Based on ARM
Transplantation Method of ARM Linux Based on AT91RM9200
1. Introduction At present, embedded processors based on ARM micro-cores have become the mainstream of the market with their advantages of low power consumption and powerful functions. At the same time, the Linux operating system developed on the Internet is becoming more and more popular with its powerful fu
[Microcontroller]
Transplantation Method of ARM Linux Based on AT91RM9200
Design and implementation of network control system based on ARM development board + uCLinux
introduction With the development of network and communication technology, embedded systems have entered a stage of rapid development. And have been widely used in various fields of society. This paper introduces a method of using ARM+uCLinux as a development platform to achieve remote system monitoring based on TCP
[Microcontroller]
Design and implementation of network control system based on ARM development board + uCLinux
Talking about the mutual growth of myself and ARM
I came into contact with embedded development when I was a junior. At that time, ARM was not as popular as it is now. I knew it was awesome, but I didn't know how awesome it was. I always heard the teachers in class say so. They predicted that ARM would occupy many markets in the future. Now it seems that it is true.
[Microcontroller]
Let the x86 android emulator simulate the arm architecture system
There are three commonly used emulators introduced online, namely bluestacks, andy and Genymotion. The former supports ARM architecture, the middle one supports remote control, and the latter has a fast startup speed. Each has its own advantages and disadvantages. If you want to use genymotion to simulate arm, just gi
[Microcontroller]
Abnormalities of ARM embedded systems and bare metal development and design
1. ARM anomalies Exceptions are very common events in embedded development, and they are also very important events. Simply put, an exception is an event that interrupts the normal execution of a program. Exceptions are often called "interrupts". The types of exceptions can be roughly divided into the following cate
[Microcontroller]
Abnormalities of ARM embedded systems and bare metal development and design
ARM chip timer function: match output, capture input
Matching output: The match is "time/count". First, time/count, and when the preset time/number is reached, an action is triggered: output a certain pulse/generate an interrupt. Capturing input: What is captured is the "signal/pulse". After starting timing/counting, the pulse/signal is received first, and when th
[Microcontroller]
Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号