# Research on the Optimization Art Design of Internet Smart Home System Based on the New Era

Authors: Jinkun Li; Yiqing Liang; Li Liu
Journal: Security and Communication Networks
 (2022)

---

## Abstract

The rapid development of contemporary technology has subtly changed people’s way of life, and the quality of people’s life has been greatly improved. With great room for development and bright prospects for development, as the Internet develops, people are paying more and more attention to smart home experiences. However, the traditional household is increasingly ill-suited to today’s increasingly fast pace of life and there is an urgent need to develop a human smart home system. The aim of this paper is to explore the optimal design of an Internet-based smart home system for the new era. In this paper, we first present a general schematic diagram of an Internet-based smart home system. The system focuses on the main control module and uses a combination of wireless communication technologies in its design. Android will then be used as an adaptive platform, and the development of the system on the mobile side will be completed using Java and cloud services and other related technologies. The smart home system proposed in this paper actually creates a technology platform for smart home applications that monitor real-time changes in the indoor environment of the house, the security status of the house, and the remote control of the house’s electrical appliances. Finally, the experimental results obtained from testing the system proposed in this paper show that the system proposed in this paper is feasible. In this paper, the control commands of five nodes are sent 200 times cyclically, and the communication frequency of each node is more than 95%.


---

## Body

## 1. Introduction

The concept of smart home originated very early; at present the research of smart home and its products has been widely carried out, but there is still a distance from the real smart home. At the beginning, the smart home system connected the family devices and security devices in the home to a smart home system through the home bus technology (HBS). The wired connection mode made the setup and preparation of the smart home system cumbersome, and the high setting cost made many consumers shrink. Home furnishing is the environment in which people live. Smart home is based on housing as a platform, using integrated wiring technology, network communication technology, security technology, automatic control technology, audio and video technology to integrate the facilities related to home life to build an efficient residence, with amenities that enhance the safety, convenience, comfort, and artistry of your home.With the development of Internet technology, smart home technology has also developed rapidly. Home environment sensing devices, smart home control systems, and home security systems are gradually entering the smart home market. Every aspect of the home is perceived and controlled online, and the age of the smart home has arrived. Therefore, the combination of intelligent home system and Internet technology, endowing the learning ability of intelligent home system, can effectively improve the user’s comfort level and has significant practical value.Chen’s team is working on integrating smart homes and IoT to create a better living environment and improve people’s quality of life. They have designed and implemented a prototype of smart home 2.0. They found that the sensors located in the smart greenhouse continuously send data to the data center [1]. They have developed a prototype system with continuous data flow, but the performance of the system has not yet been addressed. Yang’s team views the development of Intelligent Transportation Systems (ITS) as a transition to the next phase with several new requirements and next generation wireless communication technologies. They extend the structured process-based system analysis to the existing ITS architecture to create a new generation of ITS based on wireless communication technology [2]. The intelligent transportation system they built combines wireless communication technology but needs to be more practical. Zhou et al. propose strategies to optimize the use of obsolete virtual machines to increase the reliability of cloud services. This method uses three algorithms. The first algorithm selects the appropriate server set for the virtual machine based on the communication network of a large number of potential servers. The second algorithm places the primary virtual machine and waits on the server with the security selected. Finally, heuristic methods are used to solve the redesign of the optimal task of the virtual machine. The proposed method is more practical than the other four representative methods regarding the use of network resources during the service recovery phase [3]. Although the network resource utilization of the proposed method is low, the accuracy of the algorithm still needs to be improved.In this paper, several methods of wireless communication technology, cloud service, and Internet of things platform and BP neural network are combined to design and realize an Internet-based intelligent home system. The system is built by combining wireless communication technology with the main control module as the center. In the experimental part, the performance test of the system designed in this paper is carried out, and the test results show that the system performance designed in this paper actually meets the requirements.


## 2. Overall Design Scheme of the Smart Home System

### 2.1. Overall Design Scheme of the Intelligent Home System

The intelligent home system designed in this paper mainly includes data acquisition, electrical control, state prediction, emergency alarm, main control center, and network server [4, 5]. The main center of the intelligent home system designed in this paper plays an important role in the whole system. The control center communicates with the remote terminal software through the network and controls and collects environmental data for the home network equipment through the internal ZigBee network [6, 7]. In addition, if gas leakage, fire, and PM2.5 exceeding the benchmark value are detected, an alarm will be given, so that users can be informed of the danger in advance. In addition, users can observe the changes of home environment information through the software of mobile terminal or carry out corresponding operation control. The main task of mobile phone software is to achieve complex functions on a simple operating interface, which plays an important role in user experience of intelligent home life. In addition, the change of family situation can be monitored by setting up monitoring, so as to achieve the purpose of family monitoring, and the changes of family environment can be grasped by mobile phone software whenever and wherever [8, 9]. The overall scheme design block diagram is shown in Figure 1.Figure 1
Block diagram of the overall scheme design.


### 2.2. Wireless Communication Technology

Wireless communication is a communication method that uses the characteristics that electromagnetic wave signals can propagate in free space for information exchange.Wireless communication mainly includes microwave communication and satellite communication. Microwave is a kind of radio wave, and its transmission distance is generally only tens of kilometers. But the microwave frequency band is very wide, and the communication capacity is very large. Microwave communication needs to build a microwave relay station every tens of kilometers. Satellite communication is to use communication satellites as relay stations to establish microwave communication links between two or more Earth stations on the ground or between mobile bodies.


#### 2.2.1. Wireless LAN

WLAN is the most widely used technology in wireless communication. It is a technology that uses radio waves to provide wireless access and high-speed Internet [10]. Wireless LAN is mainly composed of wireless network card and bridge. The main function of wireless network card is signal conversion. The bridge plays the role of wired LAN and wireless workstation in the media access control layer and can only be connected to the network through the bridge. Compared with mobile communication technology, the cost performance of mobile communication technology is low because mobile operators charge for their communication services. Communication technology is mostly used in mobile devices such as mobile phones, and the transmission distance is almost unlimited. Users can use services such as calling, mail, and video. However, when users use video, there will be a large communication cost. In this case, telecommunications, such as mobile, have great advantages but do not provide high cost performance. Therefore, this paper designs the intelligent home system network, with the choice of wireless LAN technology.


#### 2.2.2. ZigBee

ZigBee is a wireless network protocol for short distance transmission and slow connections. The base layer is the media access layer and the physical layer is the IEEE 802.15.4 standard [11]. The main features include low power consumption, low transmission speed, low complexity, low cost, support for a large number of networks, support for multiple networks, speed, security, and reliability. ZigBee network device types can be divided into three types: ZigBee Coordinator, ZigBee Router, and ZigBee Terminal, supporting three network systems: star, tree, and grid. The physical layer and the media access layer are mainly responsible for the background work of the wireless transmitter. In applications, this section is usually unchanged and does not change the network layer and application layer logic for the most part. The network layer is responsible for managing the nodes that create or leave the ZigBee network, by encrypting packets and other means to secure operations. Find the best path to send data and send packets to the target node. Find adjacent device nodes and save relevant node information so that you can find the best path mentioned above. A ZigBee network must have a controller primarily responsible for configuring the new network and setting various network parameters, such as the Personal Area Network (PAN) communication channel ID. Administrators are responsible for setting up e-mail addresses when new devices are added to the network.The application of ZigBee is divided into three modes according to the transmission characteristics of the data stream. The first is continuous data transmission, the second is periodic data transmission, and the third is intermittent data transmission [12]. The first mode is mainly used for low-latency data transmission business, and the second mode is mainly a mode of low-rate data transmission within a fixed time interval; for example, sensor networks are typical. The third type of data is very different from the first two, mainly in discrete data modes based on different activation rules. In real life, indoor lighting switches and intelligent control of electrical appliances are such typical modes.Compared with other wireless communication protocols, ZigBee protocol has the lowest power consumption and moderate communication distance and supports a large number of nodes in the network. Although the transmission rate is low, ZigBee protocol is quite appropriate in some situations with low data throughput, such as the Internet of things.ZigBee technical characteristics: long transmission distance: ZigBee wireless transmission distance is 100–500 m, which can solve the disadvantage of other wireless technologies that the transmission distance is too short, and has great transmission advantages in smart home systems; low power consumption: ZigBee communication nodes are generally powered by batteries. Under normal circumstances, the power consumption of the node for one year is equal to the power of four AA batteries, so its low power consumption also greatly expands the application field of ZigBee technology; safety high performance: the equipment used in the system manages access through the ACL control table, and a special symmetric key algorithm is designed for the data to make it highly secure; low cost: the ZigBee transmission protocol is simple and does not charge protocol patent fees, which greatly reduces the application development cost of ZigBee, making it more cost-competitive with other technologies.ZigBee has low energy consumption and is suitable for equipment systems that do not require frequent power replacement or are inconvenient to replace power supplies; ZigBee technology does not require the purchase of patents and can achieve system signal transmission, which can greatly reduce the cost of general technology and has high reliability; ZigBee technology has rapid networking and large networking scale. If the network construction under the same conditions is realized, ZigBee technology has many advantages.


#### 2.2.3. Bluetooth

Bluetooth is a wireless communication protocol [13]. Since Bluetooth is a protocol, it can communicate with other Bluetooth devices, including computers, phones, and other Bluetooth devices. In this sense, Bluetooth capabilities are as robust, low-complexity, low cost, and low-usability as any other protocols we use on a daily basis (HTTP, FTP, SMTP, and IMAP). Bluetooth technology recognizes point-to-point communication. The technology used in Bluetooth is a type of radio technology called bounce rate. The technology initially shares the data to be sent and transmits it over a configured Bluetooth network. Each channel has 1 MHz bandwidth. The channel operates at a frequency of 2402 megahertz, with a range of 1 megahertz per step, and typically performs 1,600 jumps per second to ensure a jump to the same frequency with allowable errors. Initially used modulation method is Gaussian frequency shift keying (GFSK). It is a method of frequency modulation of the bluetooth signal. In order to achieve good separation and demodulation at the receiving end and restore the original signal, it is necessary to perform frequency modulation on the bluetooth to ensure the safety of the bluetooth communication. With the introduction of Bluetooth 2.0 + EDR EDR means better data transfer speeds and you can also use Bluetooth with 8 DIFF and 4 DQPSK compatible devices [12, 14].


#### 2.2.4. RF Technology

Radio communication technology is one of the most widely used technical means. It has a strong ability to block interference, even in the case of interference and signal blocking, the system can receive high-sensitivity shape signals. Radio frequency communication has different operating frequency ranges such as 315MHz, 433MHz, 868MHz, and 915MHz. Due to its low cost, low power consumption, long transmission distance, high penetration rate, mature technology system, and short product development cycle, it has been widely used in smart home, automatic control, logistics management, and other fields.The most basic RFID system consists of three parts: 1. Tag: composed of coupling elements and chips, the tag contains a built-in antenna, which is used to communicate with the radio frequency antenna; 2. A device that writes tag information; 3. Antenna: transmits radio frequency signals between the tag and the reader. Some systems are also connected with an external computer (host computer host system) through the RS232 or RS485 interface of the reader for data exchange.


### 2.3. Cloud Services and Internet of Things Platform

Cloud computing is a type of distributed computing, which refers to decomposing huge data computing processing programs into countless small programs through the network “cloud” and then processing and analyzing these small programs through a system composed of multiple servers to obtain results and returned to the user. In the early days of cloud computing, simply put, it was simply distributed computing, solving task distribution and merging computing results. Therefore, cloud computing is also called grid computing. Through this technology, the processing of tens of thousands of data can be completed in a very short period of time, so as to achieve powerful network services.


#### 2.3.1. Cloud Computing

Cloud computing provides services to a large number of users through the integration, management, and distribution of distributed IT resources over a network [15]. Cloud computing provides an application-level data processing platform for the Internet of things, enabling the Internet of things to share information resources. As a representation of cloud computing deployment, NIST proposes four common methods of cloud computing deployment: private cloud, public cloud, hybrid cloud, and community cloud. Private cloud is a complete cloud infrastructure for an organization where data center resources are shared across the enterprise. Cloud services for the public cloud are available to the public as a large industry group, such as rental [16]. In general, service providers of public clouds own and operate the infrastructure of their data centers. The cloud infrastructure of a hybrid cloud consists of more than two cloud systems in any form. Each cloud system is independent but integrated through standardized management techniques. The community cloud is used exclusively by a specific community that consists of multiple organizations with common concerns such as tasks, security requirements, policies, and so on.Cloud computing is mainly concentrated on the service and management; the service module mainly has three levels: (1) The Software as a Service (SaaS): this cloud computing service refers to the Software as a Service’s resources according to the needs and provides services to consumers through the network; users no longer need to purchase on-demand application software resources; users need only the browser network interface to access cloud computing SaaS services on demand. (2) Platform as a Service (PaaS): this kind of cloud computing service is similar to SaaS, which provides software to users as a service resource. However, cloud computing service provides a whole set of software development platform or customized application, which supports various functional libraries, tools, and programming languages for users. (3) Infrastructure as a Service (IaaS): these cloud computing services provide users with a variety of storage resources as well as related processors, networks, and IO devices. These resources are called virtualized resource pools. Users do not need to manage the underlying operations associated with the infrastructure, but cloud infrastructure services can be used to control the operating system, deploy applications, and store data.


#### 2.3.2. Cloud Storage

Cloud storage refers to the computer data storage model that stores data in the cloud [17, 18]. Physical storage spans multiple servers, and physical environments are often owned and managed by hosting companies. These cloud storage providers are responsible for making the data available and accessible and for maintaining and running the physical environment. Users purchase or lease storage space through vendors to store, organize, and manage application data. Cloud storage is a new type of storage service emerging in recent years. Compared with traditional storage, cloud storage is not only a hardware device, but also a large and complex system composed of many parts, including integrated network management device, storage service device, computing server, management application software, various access interfaces, network connections, and applications. The whole system takes storage as the core and provides data storage and business access services through the application interface. Cloud storage structure is divided into data access layer, application interface layer, basic management layer, and storage layer. The layers cooperate with each other to realize business functions such as data storage and access.


#### 2.3.3. Cloud Service Platform

Cloud service platforms include virtualization, distributed computing, resource planning, and other technologies [19]. Virtual server technology focuses on managing server hardware resources, such as operating system, hard drives, and memory resources, and recognizing system stability and resilience through solid resource creation and allocation. A virtual machine is a technology that uses a virtual machine screen display, also known as a virtual machine (VMS), to run a physical machine on multiple logical machines. Each virtual machine has independent hardware virtualization that results from virtualizing the machine’s physical resources. Aliyun has implemented a core-based virtual machine (KVM) architecture. Often called KVM, it is a combination of Qemu technology and KVM technology. Qemu mimics the brain with two powerful transformations, and Qemu can translate GuestOS-compliant instructions to hardware. In this mode, GuestOS interacts with the hard drive, processor, and other host devices. However, since all instructions have to go through Qemu, the performance is not great. KVM provides a virtual architecture for the Linux kernel.


#### 2.3.4. OneNET Internet of Things Platform

Compared with other Internet of things platforms, OneNET Internet of things platform has its own advantages. First, Internet of things platform can choose different network protocols to access various sensors and intelligent hardware systems. Second, users can use big data services. Third, users or enterprises can develop their own applications, because of the official provision of a rich API. The OneNET platform supports a variety of functional networks and protocols to address the common needs of the Internet of things, as well as manage and monitor the various states of the hardware. OneNET has obvious advantages in Internet of things platform. All kinds of software and hardware can be connected to the platform. OneNET ensures users’ privacy through relevant technologies, especially the use of RESTAPI and SOCKET communication. The OneNET platform is very stable, and it also provides the monitoring function and the corresponding trigger mechanism. As an Internet of things platform, OneNET has a very rich variety of hardware, which can not only realize the rapid access of various terminal devices, but also provide corresponding services. OneNET provides three communication modes: Ethernet communication, GPRS data traffic communication, and wi-fi wireless communication.Compared with the traditional network application model, it has the following advantages and characteristics: it must be emphasized that virtualization breaks through the boundaries of time and space, which is the most significant feature of cloud computing, and virtualization technology includes application virtualization and resource virtualization. As we all know, there is no spatial relationship between the physical platform and the environment in which the application is deployed. It is through the virtual platform that the corresponding terminal operations are performed to complete data backup, migration, and expansion. Cloud computing has efficient computing power. Adding cloud computing functions to the original server can rapidly increase the computing speed and finally achieve the purpose of expanding the application by dynamically expanding the level of virtualization.


### 2.4. BP Neural Network Prediction Model

The basic BP nervous system algorithm also includes continuous data calculation and reverse error correction; e.g., the actual output of the neural network is calculated from input to output based on the direction and the weight and polarization are adjusted. According to the direction of the exit to the entrance [20, 21], the process of calculating the nervous system of blood pressure is as follows.


#### 2.4.1. Forward Calculation of the Signal

The inputneti of the i-th neuron in the hidden layer is(1)neti=∑j=1mwi,jxj+θi.The outputoi of the i-th node of the hidden layer is(2)oi=Φneti=Φ∑j=1mwi,jxj+θi.The inputnetk of the kth node in the output layer is(3)netk=∑i=1qwk,iyi+ak=∑i=1qwk,iΦ∑j=1mwi,jxj+θi+ak.The outputok of the kth node in the output layer is(4)ok=ϕnetk=ϕ∑i=1qwk,iΦ∑j=1mwi,jxj+θi+ak.


#### 2.4.2. Reverse Error Correction Process

Calculate the inverse error correction process, i.e., the output error of the neurons in the output layer, and use the gradient descent algorithm to adjust the weights and slopes of the neurons in each layer to achieve the desired result [22, 23]. The most commonly used error function in BP neural networks is the mean squared error function. Assuming the expected output of the function network, the error p of each model is(5)EP=12∑k=11Tkp−ok2.Then the total error function ofP training samples is(6)EP=12∑p=1p∑k=11Tkp−ok2.E is a neural network with weights connecting vij and wij. The weights of each layer can continuously reduce the error E. At this time, the adjustment of weights is proportional to the negative gradient of the error, as shown in(7)Δvij=−η∂E∂viji=1,2,…,n.(8)Δwij=−η∂E∂wijj=1,2,…,n.The formula for weight adjustment is as follows: according to the properties of partial derivatives, equations (9) and (10) can be rewritten as(9)Δvij=−η∂E∂vij=−η∂E∂netj∂netj∂vij.(10)Δwij=−η∂E∂wij=−η∂E∂netk∂netk∂vjk.According to formula (6),(11)E=12D−O2=12∑k=1mdk−f∑j=1hwjkyj2.Then, the output layer has the following formula:(12)∂E∂netk=∂E∂ok∂ok∂netk=∂E∂okfnetk,∂E∂ok=−dk−ok.Because of its advantages of simple structure, strong parallelism, and small amount of computation, BP algorithm is one of the most mature neural network training methods. The essence of algorithm training is to solve the minimum value of error function. However, because the BP neural network algorithm uses lean methods to increase weights and distances, the traditional BP neural network algorithms also have the drawbacks of lean methods. At present, the method for additional torque, the study frequency adjustment method, the momentum adjustment method, and other algorithms can be used for improvement. The improved algorithm has excellent performance in data fitting, data prediction, and function approximation.BP network is mainly used in the following four aspects. (1) Function Approximation: train a network to approximate a function with input vectors and corresponding output vectors. (2) Pattern Recognition: use a pending output vector to associate it with the input vector. (3) Classification: classify the appropriate way defined by the input vector. (4) Data compression: reduce the dimension of the output vector for transmission or storage.The basic BP algorithm includes two processes of signal forward propagation and error backward propagation. That is, the calculation of the error output is performed in the direction from input to output, while the adjustment of weights and thresholds is performed in the direction from output to input. During forward propagation, the input signal acts on the output node through the hidden layer, and after nonlinear transformation, the output signal is generated. Error backpropagation is to backpropagate the output error layer by layer to the input layer through the hidden layer and distribute the error to all units in each layer and use the error signal obtained from each layer as the basis for adjusting the weights of each unit. By adjusting the connection strength between the input node and the hidden layer node, the connection strength between the hidden layer node and the output node, and the threshold, the error decreases along the gradient direction. After repeated learning and training, the network parameters (weights and thresholds) corresponding to the minimum error are determined; the training stops. At this time, the trained neural network can automatically process the nonlinearly transformed information with the smallest output error for the input information of similar samples.BP neural network also has the following major defects. The learning speed is slow, and even a simple problem generally requires hundreds or even thousands of times of learning to converge. It is easy to fall into local minima. There is no corresponding theoretical guidance for the selection of the number of network layers and neurons. Network promotion capabilities are limited.


## 2.1. Overall Design Scheme of the Intelligent Home System

The intelligent home system designed in this paper mainly includes data acquisition, electrical control, state prediction, emergency alarm, main control center, and network server [4, 5]. The main center of the intelligent home system designed in this paper plays an important role in the whole system. The control center communicates with the remote terminal software through the network and controls and collects environmental data for the home network equipment through the internal ZigBee network [6, 7]. In addition, if gas leakage, fire, and PM2.5 exceeding the benchmark value are detected, an alarm will be given, so that users can be informed of the danger in advance. In addition, users can observe the changes of home environment information through the software of mobile terminal or carry out corresponding operation control. The main task of mobile phone software is to achieve complex functions on a simple operating interface, which plays an important role in user experience of intelligent home life. In addition, the change of family situation can be monitored by setting up monitoring, so as to achieve the purpose of family monitoring, and the changes of family environment can be grasped by mobile phone software whenever and wherever [8, 9]. The overall scheme design block diagram is shown in Figure 1.Figure 1
Block diagram of the overall scheme design.


## 2.2. Wireless Communication Technology

Wireless communication is a communication method that uses the characteristics that electromagnetic wave signals can propagate in free space for information exchange.Wireless communication mainly includes microwave communication and satellite communication. Microwave is a kind of radio wave, and its transmission distance is generally only tens of kilometers. But the microwave frequency band is very wide, and the communication capacity is very large. Microwave communication needs to build a microwave relay station every tens of kilometers. Satellite communication is to use communication satellites as relay stations to establish microwave communication links between two or more Earth stations on the ground or between mobile bodies.


### 2.2.1. Wireless LAN

WLAN is the most widely used technology in wireless communication. It is a technology that uses radio waves to provide wireless access and high-speed Internet [10]. Wireless LAN is mainly composed of wireless network card and bridge. The main function of wireless network card is signal conversion. The bridge plays the role of wired LAN and wireless workstation in the media access control layer and can only be connected to the network through the bridge. Compared with mobile communication technology, the cost performance of mobile communication technology is low because mobile operators charge for their communication services. Communication technology is mostly used in mobile devices such as mobile phones, and the transmission distance is almost unlimited. Users can use services such as calling, mail, and video. However, when users use video, there will be a large communication cost. In this case, telecommunications, such as mobile, have great advantages but do not provide high cost performance. Therefore, this paper designs the intelligent home system network, with the choice of wireless LAN technology.


### 2.2.2. ZigBee

ZigBee is a wireless network protocol for short distance transmission and slow connections. The base layer is the media access layer and the physical layer is the IEEE 802.15.4 standard [11]. The main features include low power consumption, low transmission speed, low complexity, low cost, support for a large number of networks, support for multiple networks, speed, security, and reliability. ZigBee network device types can be divided into three types: ZigBee Coordinator, ZigBee Router, and ZigBee Terminal, supporting three network systems: star, tree, and grid. The physical layer and the media access layer are mainly responsible for the background work of the wireless transmitter. In applications, this section is usually unchanged and does not change the network layer and application layer logic for the most part. The network layer is responsible for managing the nodes that create or leave the ZigBee network, by encrypting packets and other means to secure operations. Find the best path to send data and send packets to the target node. Find adjacent device nodes and save relevant node information so that you can find the best path mentioned above. A ZigBee network must have a controller primarily responsible for configuring the new network and setting various network parameters, such as the Personal Area Network (PAN) communication channel ID. Administrators are responsible for setting up e-mail addresses when new devices are added to the network.The application of ZigBee is divided into three modes according to the transmission characteristics of the data stream. The first is continuous data transmission, the second is periodic data transmission, and the third is intermittent data transmission [12]. The first mode is mainly used for low-latency data transmission business, and the second mode is mainly a mode of low-rate data transmission within a fixed time interval; for example, sensor networks are typical. The third type of data is very different from the first two, mainly in discrete data modes based on different activation rules. In real life, indoor lighting switches and intelligent control of electrical appliances are such typical modes.Compared with other wireless communication protocols, ZigBee protocol has the lowest power consumption and moderate communication distance and supports a large number of nodes in the network. Although the transmission rate is low, ZigBee protocol is quite appropriate in some situations with low data throughput, such as the Internet of things.ZigBee technical characteristics: long transmission distance: ZigBee wireless transmission distance is 100–500 m, which can solve the disadvantage of other wireless technologies that the transmission distance is too short, and has great transmission advantages in smart home systems; low power consumption: ZigBee communication nodes are generally powered by batteries. Under normal circumstances, the power consumption of the node for one year is equal to the power of four AA batteries, so its low power consumption also greatly expands the application field of ZigBee technology; safety high performance: the equipment used in the system manages access through the ACL control table, and a special symmetric key algorithm is designed for the data to make it highly secure; low cost: the ZigBee transmission protocol is simple and does not charge protocol patent fees, which greatly reduces the application development cost of ZigBee, making it more cost-competitive with other technologies.ZigBee has low energy consumption and is suitable for equipment systems that do not require frequent power replacement or are inconvenient to replace power supplies; ZigBee technology does not require the purchase of patents and can achieve system signal transmission, which can greatly reduce the cost of general technology and has high reliability; ZigBee technology has rapid networking and large networking scale. If the network construction under the same conditions is realized, ZigBee technology has many advantages.


### 2.2.3. Bluetooth

Bluetooth is a wireless communication protocol [13]. Since Bluetooth is a protocol, it can communicate with other Bluetooth devices, including computers, phones, and other Bluetooth devices. In this sense, Bluetooth capabilities are as robust, low-complexity, low cost, and low-usability as any other protocols we use on a daily basis (HTTP, FTP, SMTP, and IMAP). Bluetooth technology recognizes point-to-point communication. The technology used in Bluetooth is a type of radio technology called bounce rate. The technology initially shares the data to be sent and transmits it over a configured Bluetooth network. Each channel has 1 MHz bandwidth. The channel operates at a frequency of 2402 megahertz, with a range of 1 megahertz per step, and typically performs 1,600 jumps per second to ensure a jump to the same frequency with allowable errors. Initially used modulation method is Gaussian frequency shift keying (GFSK). It is a method of frequency modulation of the bluetooth signal. In order to achieve good separation and demodulation at the receiving end and restore the original signal, it is necessary to perform frequency modulation on the bluetooth to ensure the safety of the bluetooth communication. With the introduction of Bluetooth 2.0 + EDR EDR means better data transfer speeds and you can also use Bluetooth with 8 DIFF and 4 DQPSK compatible devices [12, 14].


### 2.2.4. RF Technology

Radio communication technology is one of the most widely used technical means. It has a strong ability to block interference, even in the case of interference and signal blocking, the system can receive high-sensitivity shape signals. Radio frequency communication has different operating frequency ranges such as 315MHz, 433MHz, 868MHz, and 915MHz. Due to its low cost, low power consumption, long transmission distance, high penetration rate, mature technology system, and short product development cycle, it has been widely used in smart home, automatic control, logistics management, and other fields.The most basic RFID system consists of three parts: 1. Tag: composed of coupling elements and chips, the tag contains a built-in antenna, which is used to communicate with the radio frequency antenna; 2. A device that writes tag information; 3. Antenna: transmits radio frequency signals between the tag and the reader. Some systems are also connected with an external computer (host computer host system) through the RS232 or RS485 interface of the reader for data exchange.


## 2.2.1. Wireless LAN

WLAN is the most widely used technology in wireless communication. It is a technology that uses radio waves to provide wireless access and high-speed Internet [10]. Wireless LAN is mainly composed of wireless network card and bridge. The main function of wireless network card is signal conversion. The bridge plays the role of wired LAN and wireless workstation in the media access control layer and can only be connected to the network through the bridge. Compared with mobile communication technology, the cost performance of mobile communication technology is low because mobile operators charge for their communication services. Communication technology is mostly used in mobile devices such as mobile phones, and the transmission distance is almost unlimited. Users can use services such as calling, mail, and video. However, when users use video, there will be a large communication cost. In this case, telecommunications, such as mobile, have great advantages but do not provide high cost performance. Therefore, this paper designs the intelligent home system network, with the choice of wireless LAN technology.


## 2.2.2. ZigBee

ZigBee is a wireless network protocol for short distance transmission and slow connections. The base layer is the media access layer and the physical layer is the IEEE 802.15.4 standard [11]. The main features include low power consumption, low transmission speed, low complexity, low cost, support for a large number of networks, support for multiple networks, speed, security, and reliability. ZigBee network device types can be divided into three types: ZigBee Coordinator, ZigBee Router, and ZigBee Terminal, supporting three network systems: star, tree, and grid. The physical layer and the media access layer are mainly responsible for the background work of the wireless transmitter. In applications, this section is usually unchanged and does not change the network layer and application layer logic for the most part. The network layer is responsible for managing the nodes that create or leave the ZigBee network, by encrypting packets and other means to secure operations. Find the best path to send data and send packets to the target node. Find adjacent device nodes and save relevant node information so that you can find the best path mentioned above. A ZigBee network must have a controller primarily responsible for configuring the new network and setting various network parameters, such as the Personal Area Network (PAN) communication channel ID. Administrators are responsible for setting up e-mail addresses when new devices are added to the network.The application of ZigBee is divided into three modes according to the transmission characteristics of the data stream. The first is continuous data transmission, the second is periodic data transmission, and the third is intermittent data transmission [12]. The first mode is mainly used for low-latency data transmission business, and the second mode is mainly a mode of low-rate data transmission within a fixed time interval; for example, sensor networks are typical. The third type of data is very different from the first two, mainly in discrete data modes based on different activation rules. In real life, indoor lighting switches and intelligent control of electrical appliances are such typical modes.Compared with other wireless communication protocols, ZigBee protocol has the lowest power consumption and moderate communication distance and supports a large number of nodes in the network. Although the transmission rate is low, ZigBee protocol is quite appropriate in some situations with low data throughput, such as the Internet of things.ZigBee technical characteristics: long transmission distance: ZigBee wireless transmission distance is 100–500 m, which can solve the disadvantage of other wireless technologies that the transmission distance is too short, and has great transmission advantages in smart home systems; low power consumption: ZigBee communication nodes are generally powered by batteries. Under normal circumstances, the power consumption of the node for one year is equal to the power of four AA batteries, so its low power consumption also greatly expands the application field of ZigBee technology; safety high performance: the equipment used in the system manages access through the ACL control table, and a special symmetric key algorithm is designed for the data to make it highly secure; low cost: the ZigBee transmission protocol is simple and does not charge protocol patent fees, which greatly reduces the application development cost of ZigBee, making it more cost-competitive with other technologies.ZigBee has low energy consumption and is suitable for equipment systems that do not require frequent power replacement or are inconvenient to replace power supplies; ZigBee technology does not require the purchase of patents and can achieve system signal transmission, which can greatly reduce the cost of general technology and has high reliability; ZigBee technology has rapid networking and large networking scale. If the network construction under the same conditions is realized, ZigBee technology has many advantages.


## 2.2.3. Bluetooth

Bluetooth is a wireless communication protocol [13]. Since Bluetooth is a protocol, it can communicate with other Bluetooth devices, including computers, phones, and other Bluetooth devices. In this sense, Bluetooth capabilities are as robust, low-complexity, low cost, and low-usability as any other protocols we use on a daily basis (HTTP, FTP, SMTP, and IMAP). Bluetooth technology recognizes point-to-point communication. The technology used in Bluetooth is a type of radio technology called bounce rate. The technology initially shares the data to be sent and transmits it over a configured Bluetooth network. Each channel has 1 MHz bandwidth. The channel operates at a frequency of 2402 megahertz, with a range of 1 megahertz per step, and typically performs 1,600 jumps per second to ensure a jump to the same frequency with allowable errors. Initially used modulation method is Gaussian frequency shift keying (GFSK). It is a method of frequency modulation of the bluetooth signal. In order to achieve good separation and demodulation at the receiving end and restore the original signal, it is necessary to perform frequency modulation on the bluetooth to ensure the safety of the bluetooth communication. With the introduction of Bluetooth 2.0 + EDR EDR means better data transfer speeds and you can also use Bluetooth with 8 DIFF and 4 DQPSK compatible devices [12, 14].


## 2.2.4. RF Technology

Radio communication technology is one of the most widely used technical means. It has a strong ability to block interference, even in the case of interference and signal blocking, the system can receive high-sensitivity shape signals. Radio frequency communication has different operating frequency ranges such as 315MHz, 433MHz, 868MHz, and 915MHz. Due to its low cost, low power consumption, long transmission distance, high penetration rate, mature technology system, and short product development cycle, it has been widely used in smart home, automatic control, logistics management, and other fields.The most basic RFID system consists of three parts: 1. Tag: composed of coupling elements and chips, the tag contains a built-in antenna, which is used to communicate with the radio frequency antenna; 2. A device that writes tag information; 3. Antenna: transmits radio frequency signals between the tag and the reader. Some systems are also connected with an external computer (host computer host system) through the RS232 or RS485 interface of the reader for data exchange.


## 2.3. Cloud Services and Internet of Things Platform

Cloud computing is a type of distributed computing, which refers to decomposing huge data computing processing programs into countless small programs through the network “cloud” and then processing and analyzing these small programs through a system composed of multiple servers to obtain results and returned to the user. In the early days of cloud computing, simply put, it was simply distributed computing, solving task distribution and merging computing results. Therefore, cloud computing is also called grid computing. Through this technology, the processing of tens of thousands of data can be completed in a very short period of time, so as to achieve powerful network services.


### 2.3.1. Cloud Computing

Cloud computing provides services to a large number of users through the integration, management, and distribution of distributed IT resources over a network [15]. Cloud computing provides an application-level data processing platform for the Internet of things, enabling the Internet of things to share information resources. As a representation of cloud computing deployment, NIST proposes four common methods of cloud computing deployment: private cloud, public cloud, hybrid cloud, and community cloud. Private cloud is a complete cloud infrastructure for an organization where data center resources are shared across the enterprise. Cloud services for the public cloud are available to the public as a large industry group, such as rental [16]. In general, service providers of public clouds own and operate the infrastructure of their data centers. The cloud infrastructure of a hybrid cloud consists of more than two cloud systems in any form. Each cloud system is independent but integrated through standardized management techniques. The community cloud is used exclusively by a specific community that consists of multiple organizations with common concerns such as tasks, security requirements, policies, and so on.Cloud computing is mainly concentrated on the service and management; the service module mainly has three levels: (1) The Software as a Service (SaaS): this cloud computing service refers to the Software as a Service’s resources according to the needs and provides services to consumers through the network; users no longer need to purchase on-demand application software resources; users need only the browser network interface to access cloud computing SaaS services on demand. (2) Platform as a Service (PaaS): this kind of cloud computing service is similar to SaaS, which provides software to users as a service resource. However, cloud computing service provides a whole set of software development platform or customized application, which supports various functional libraries, tools, and programming languages for users. (3) Infrastructure as a Service (IaaS): these cloud computing services provide users with a variety of storage resources as well as related processors, networks, and IO devices. These resources are called virtualized resource pools. Users do not need to manage the underlying operations associated with the infrastructure, but cloud infrastructure services can be used to control the operating system, deploy applications, and store data.


### 2.3.2. Cloud Storage

Cloud storage refers to the computer data storage model that stores data in the cloud [17, 18]. Physical storage spans multiple servers, and physical environments are often owned and managed by hosting companies. These cloud storage providers are responsible for making the data available and accessible and for maintaining and running the physical environment. Users purchase or lease storage space through vendors to store, organize, and manage application data. Cloud storage is a new type of storage service emerging in recent years. Compared with traditional storage, cloud storage is not only a hardware device, but also a large and complex system composed of many parts, including integrated network management device, storage service device, computing server, management application software, various access interfaces, network connections, and applications. The whole system takes storage as the core and provides data storage and business access services through the application interface. Cloud storage structure is divided into data access layer, application interface layer, basic management layer, and storage layer. The layers cooperate with each other to realize business functions such as data storage and access.


### 2.3.3. Cloud Service Platform

Cloud service platforms include virtualization, distributed computing, resource planning, and other technologies [19]. Virtual server technology focuses on managing server hardware resources, such as operating system, hard drives, and memory resources, and recognizing system stability and resilience through solid resource creation and allocation. A virtual machine is a technology that uses a virtual machine screen display, also known as a virtual machine (VMS), to run a physical machine on multiple logical machines. Each virtual machine has independent hardware virtualization that results from virtualizing the machine’s physical resources. Aliyun has implemented a core-based virtual machine (KVM) architecture. Often called KVM, it is a combination of Qemu technology and KVM technology. Qemu mimics the brain with two powerful transformations, and Qemu can translate GuestOS-compliant instructions to hardware. In this mode, GuestOS interacts with the hard drive, processor, and other host devices. However, since all instructions have to go through Qemu, the performance is not great. KVM provides a virtual architecture for the Linux kernel.


### 2.3.4. OneNET Internet of Things Platform

Compared with other Internet of things platforms, OneNET Internet of things platform has its own advantages. First, Internet of things platform can choose different network protocols to access various sensors and intelligent hardware systems. Second, users can use big data services. Third, users or enterprises can develop their own applications, because of the official provision of a rich API. The OneNET platform supports a variety of functional networks and protocols to address the common needs of the Internet of things, as well as manage and monitor the various states of the hardware. OneNET has obvious advantages in Internet of things platform. All kinds of software and hardware can be connected to the platform. OneNET ensures users’ privacy through relevant technologies, especially the use of RESTAPI and SOCKET communication. The OneNET platform is very stable, and it also provides the monitoring function and the corresponding trigger mechanism. As an Internet of things platform, OneNET has a very rich variety of hardware, which can not only realize the rapid access of various terminal devices, but also provide corresponding services. OneNET provides three communication modes: Ethernet communication, GPRS data traffic communication, and wi-fi wireless communication.Compared with the traditional network application model, it has the following advantages and characteristics: it must be emphasized that virtualization breaks through the boundaries of time and space, which is the most significant feature of cloud computing, and virtualization technology includes application virtualization and resource virtualization. As we all know, there is no spatial relationship between the physical platform and the environment in which the application is deployed. It is through the virtual platform that the corresponding terminal operations are performed to complete data backup, migration, and expansion. Cloud computing has efficient computing power. Adding cloud computing functions to the original server can rapidly increase the computing speed and finally achieve the purpose of expanding the application by dynamically expanding the level of virtualization.


## 2.3.1. Cloud Computing

Cloud computing provides services to a large number of users through the integration, management, and distribution of distributed IT resources over a network [15]. Cloud computing provides an application-level data processing platform for the Internet of things, enabling the Internet of things to share information resources. As a representation of cloud computing deployment, NIST proposes four common methods of cloud computing deployment: private cloud, public cloud, hybrid cloud, and community cloud. Private cloud is a complete cloud infrastructure for an organization where data center resources are shared across the enterprise. Cloud services for the public cloud are available to the public as a large industry group, such as rental [16]. In general, service providers of public clouds own and operate the infrastructure of their data centers. The cloud infrastructure of a hybrid cloud consists of more than two cloud systems in any form. Each cloud system is independent but integrated through standardized management techniques. The community cloud is used exclusively by a specific community that consists of multiple organizations with common concerns such as tasks, security requirements, policies, and so on.Cloud computing is mainly concentrated on the service and management; the service module mainly has three levels: (1) The Software as a Service (SaaS): this cloud computing service refers to the Software as a Service’s resources according to the needs and provides services to consumers through the network; users no longer need to purchase on-demand application software resources; users need only the browser network interface to access cloud computing SaaS services on demand. (2) Platform as a Service (PaaS): this kind of cloud computing service is similar to SaaS, which provides software to users as a service resource. However, cloud computing service provides a whole set of software development platform or customized application, which supports various functional libraries, tools, and programming languages for users. (3) Infrastructure as a Service (IaaS): these cloud computing services provide users with a variety of storage resources as well as related processors, networks, and IO devices. These resources are called virtualized resource pools. Users do not need to manage the underlying operations associated with the infrastructure, but cloud infrastructure services can be used to control the operating system, deploy applications, and store data.


## 2.3.2. Cloud Storage

Cloud storage refers to the computer data storage model that stores data in the cloud [17, 18]. Physical storage spans multiple servers, and physical environments are often owned and managed by hosting companies. These cloud storage providers are responsible for making the data available and accessible and for maintaining and running the physical environment. Users purchase or lease storage space through vendors to store, organize, and manage application data. Cloud storage is a new type of storage service emerging in recent years. Compared with traditional storage, cloud storage is not only a hardware device, but also a large and complex system composed of many parts, including integrated network management device, storage service device, computing server, management application software, various access interfaces, network connections, and applications. The whole system takes storage as the core and provides data storage and business access services through the application interface. Cloud storage structure is divided into data access layer, application interface layer, basic management layer, and storage layer. The layers cooperate with each other to realize business functions such as data storage and access.


## 2.3.3. Cloud Service Platform

Cloud service platforms include virtualization, distributed computing, resource planning, and other technologies [19]. Virtual server technology focuses on managing server hardware resources, such as operating system, hard drives, and memory resources, and recognizing system stability and resilience through solid resource creation and allocation. A virtual machine is a technology that uses a virtual machine screen display, also known as a virtual machine (VMS), to run a physical machine on multiple logical machines. Each virtual machine has independent hardware virtualization that results from virtualizing the machine’s physical resources. Aliyun has implemented a core-based virtual machine (KVM) architecture. Often called KVM, it is a combination of Qemu technology and KVM technology. Qemu mimics the brain with two powerful transformations, and Qemu can translate GuestOS-compliant instructions to hardware. In this mode, GuestOS interacts with the hard drive, processor, and other host devices. However, since all instructions have to go through Qemu, the performance is not great. KVM provides a virtual architecture for the Linux kernel.


## 2.3.4. OneNET Internet of Things Platform

Compared with other Internet of things platforms, OneNET Internet of things platform has its own advantages. First, Internet of things platform can choose different network protocols to access various sensors and intelligent hardware systems. Second, users can use big data services. Third, users or enterprises can develop their own applications, because of the official provision of a rich API. The OneNET platform supports a variety of functional networks and protocols to address the common needs of the Internet of things, as well as manage and monitor the various states of the hardware. OneNET has obvious advantages in Internet of things platform. All kinds of software and hardware can be connected to the platform. OneNET ensures users’ privacy through relevant technologies, especially the use of RESTAPI and SOCKET communication. The OneNET platform is very stable, and it also provides the monitoring function and the corresponding trigger mechanism. As an Internet of things platform, OneNET has a very rich variety of hardware, which can not only realize the rapid access of various terminal devices, but also provide corresponding services. OneNET provides three communication modes: Ethernet communication, GPRS data traffic communication, and wi-fi wireless communication.Compared with the traditional network application model, it has the following advantages and characteristics: it must be emphasized that virtualization breaks through the boundaries of time and space, which is the most significant feature of cloud computing, and virtualization technology includes application virtualization and resource virtualization. As we all know, there is no spatial relationship between the physical platform and the environment in which the application is deployed. It is through the virtual platform that the corresponding terminal operations are performed to complete data backup, migration, and expansion. Cloud computing has efficient computing power. Adding cloud computing functions to the original server can rapidly increase the computing speed and finally achieve the purpose of expanding the application by dynamically expanding the level of virtualization.


## 2.4. BP Neural Network Prediction Model

The basic BP nervous system algorithm also includes continuous data calculation and reverse error correction; e.g., the actual output of the neural network is calculated from input to output based on the direction and the weight and polarization are adjusted. According to the direction of the exit to the entrance [20, 21], the process of calculating the nervous system of blood pressure is as follows.


### 2.4.1. Forward Calculation of the Signal

The inputneti of the i-th neuron in the hidden layer is(1)neti=∑j=1mwi,jxj+θi.The outputoi of the i-th node of the hidden layer is(2)oi=Φneti=Φ∑j=1mwi,jxj+θi.The inputnetk of the kth node in the output layer is(3)netk=∑i=1qwk,iyi+ak=∑i=1qwk,iΦ∑j=1mwi,jxj+θi+ak.The outputok of the kth node in the output layer is(4)ok=ϕnetk=ϕ∑i=1qwk,iΦ∑j=1mwi,jxj+θi+ak.


### 2.4.2. Reverse Error Correction Process

Calculate the inverse error correction process, i.e., the output error of the neurons in the output layer, and use the gradient descent algorithm to adjust the weights and slopes of the neurons in each layer to achieve the desired result [22, 23]. The most commonly used error function in BP neural networks is the mean squared error function. Assuming the expected output of the function network, the error p of each model is(5)EP=12∑k=11Tkp−ok2.Then the total error function ofP training samples is(6)EP=12∑p=1p∑k=11Tkp−ok2.E is a neural network with weights connecting vij and wij. The weights of each layer can continuously reduce the error E. At this time, the adjustment of weights is proportional to the negative gradient of the error, as shown in(7)Δvij=−η∂E∂viji=1,2,…,n.(8)Δwij=−η∂E∂wijj=1,2,…,n.The formula for weight adjustment is as follows: according to the properties of partial derivatives, equations (9) and (10) can be rewritten as(9)Δvij=−η∂E∂vij=−η∂E∂netj∂netj∂vij.(10)Δwij=−η∂E∂wij=−η∂E∂netk∂netk∂vjk.According to formula (6),(11)E=12D−O2=12∑k=1mdk−f∑j=1hwjkyj2.Then, the output layer has the following formula:(12)∂E∂netk=∂E∂ok∂ok∂netk=∂E∂okfnetk,∂E∂ok=−dk−ok.Because of its advantages of simple structure, strong parallelism, and small amount of computation, BP algorithm is one of the most mature neural network training methods. The essence of algorithm training is to solve the minimum value of error function. However, because the BP neural network algorithm uses lean methods to increase weights and distances, the traditional BP neural network algorithms also have the drawbacks of lean methods. At present, the method for additional torque, the study frequency adjustment method, the momentum adjustment method, and other algorithms can be used for improvement. The improved algorithm has excellent performance in data fitting, data prediction, and function approximation.BP network is mainly used in the following four aspects. (1) Function Approximation: train a network to approximate a function with input vectors and corresponding output vectors. (2) Pattern Recognition: use a pending output vector to associate it with the input vector. (3) Classification: classify the appropriate way defined by the input vector. (4) Data compression: reduce the dimension of the output vector for transmission or storage.The basic BP algorithm includes two processes of signal forward propagation and error backward propagation. That is, the calculation of the error output is performed in the direction from input to output, while the adjustment of weights and thresholds is performed in the direction from output to input. During forward propagation, the input signal acts on the output node through the hidden layer, and after nonlinear transformation, the output signal is generated. Error backpropagation is to backpropagate the output error layer by layer to the input layer through the hidden layer and distribute the error to all units in each layer and use the error signal obtained from each layer as the basis for adjusting the weights of each unit. By adjusting the connection strength between the input node and the hidden layer node, the connection strength between the hidden layer node and the output node, and the threshold, the error decreases along the gradient direction. After repeated learning and training, the network parameters (weights and thresholds) corresponding to the minimum error are determined; the training stops. At this time, the trained neural network can automatically process the nonlinearly transformed information with the smallest output error for the input information of similar samples.BP neural network also has the following major defects. The learning speed is slow, and even a simple problem generally requires hundreds or even thousands of times of learning to converge. It is easy to fall into local minima. There is no corresponding theoretical guidance for the selection of the number of network layers and neurons. Network promotion capabilities are limited.


## 2.4.1. Forward Calculation of the Signal

The inputneti of the i-th neuron in the hidden layer is(1)neti=∑j=1mwi,jxj+θi.The outputoi of the i-th node of the hidden layer is(2)oi=Φneti=Φ∑j=1mwi,jxj+θi.The inputnetk of the kth node in the output layer is(3)netk=∑i=1qwk,iyi+ak=∑i=1qwk,iΦ∑j=1mwi,jxj+θi+ak.The outputok of the kth node in the output layer is(4)ok=ϕnetk=ϕ∑i=1qwk,iΦ∑j=1mwi,jxj+θi+ak.


## 2.4.2. Reverse Error Correction Process

Calculate the inverse error correction process, i.e., the output error of the neurons in the output layer, and use the gradient descent algorithm to adjust the weights and slopes of the neurons in each layer to achieve the desired result [22, 23]. The most commonly used error function in BP neural networks is the mean squared error function. Assuming the expected output of the function network, the error p of each model is(5)EP=12∑k=11Tkp−ok2.Then the total error function ofP training samples is(6)EP=12∑p=1p∑k=11Tkp−ok2.E is a neural network with weights connecting vij and wij. The weights of each layer can continuously reduce the error E. At this time, the adjustment of weights is proportional to the negative gradient of the error, as shown in(7)Δvij=−η∂E∂viji=1,2,…,n.(8)Δwij=−η∂E∂wijj=1,2,…,n.The formula for weight adjustment is as follows: according to the properties of partial derivatives, equations (9) and (10) can be rewritten as(9)Δvij=−η∂E∂vij=−η∂E∂netj∂netj∂vij.(10)Δwij=−η∂E∂wij=−η∂E∂netk∂netk∂vjk.According to formula (6),(11)E=12D−O2=12∑k=1mdk−f∑j=1hwjkyj2.Then, the output layer has the following formula:(12)∂E∂netk=∂E∂ok∂ok∂netk=∂E∂okfnetk,∂E∂ok=−dk−ok.Because of its advantages of simple structure, strong parallelism, and small amount of computation, BP algorithm is one of the most mature neural network training methods. The essence of algorithm training is to solve the minimum value of error function. However, because the BP neural network algorithm uses lean methods to increase weights and distances, the traditional BP neural network algorithms also have the drawbacks of lean methods. At present, the method for additional torque, the study frequency adjustment method, the momentum adjustment method, and other algorithms can be used for improvement. The improved algorithm has excellent performance in data fitting, data prediction, and function approximation.BP network is mainly used in the following four aspects. (1) Function Approximation: train a network to approximate a function with input vectors and corresponding output vectors. (2) Pattern Recognition: use a pending output vector to associate it with the input vector. (3) Classification: classify the appropriate way defined by the input vector. (4) Data compression: reduce the dimension of the output vector for transmission or storage.The basic BP algorithm includes two processes of signal forward propagation and error backward propagation. That is, the calculation of the error output is performed in the direction from input to output, while the adjustment of weights and thresholds is performed in the direction from output to input. During forward propagation, the input signal acts on the output node through the hidden layer, and after nonlinear transformation, the output signal is generated. Error backpropagation is to backpropagate the output error layer by layer to the input layer through the hidden layer and distribute the error to all units in each layer and use the error signal obtained from each layer as the basis for adjusting the weights of each unit. By adjusting the connection strength between the input node and the hidden layer node, the connection strength between the hidden layer node and the output node, and the threshold, the error decreases along the gradient direction. After repeated learning and training, the network parameters (weights and thresholds) corresponding to the minimum error are determined; the training stops. At this time, the trained neural network can automatically process the nonlinearly transformed information with the smallest output error for the input information of similar samples.BP neural network also has the following major defects. The learning speed is slow, and even a simple problem generally requires hundreds or even thousands of times of learning to converge. It is easy to fall into local minima. There is no corresponding theoretical guidance for the selection of the number of network layers and neurons. Network promotion capabilities are limited.


## 3. Smart Home System Function and Performance Testing

### 3.1. Data Collection

The test data in this article comes from the UMass Trace Repository Smart∗ project distribution for home data. The Smart Project∗ brings together real-world home environments and device information from three families to help build smart homes. Environmental datasets include indoor and outdoor temperature and humidity, wind speed, and direction. Data are collected every 300 seconds, and data are collected and uploaded by sensors every day. In the experiment of this paper, the data of the living room fan of the equipment data set is trained as the object data.


### 3.2. System Architecture

When users use the system designed in this paper, they first use the mobile phone APP to obtain data from the server through the network, the server communicates with the main center through the network, and the main center communicates with each terminal node in the home environment through the ZigBee network, so as to realize data exchange and control of electrical equipment. The architecture of the system is shown in Figure2.Figure 2
System architecture diagram.According to the market demand and future development, the adaptor system of mobile phone client chooses Android. Through the design of the mobile phone software interface, the user’s operation is easier; users can operate at any time. The system mainly includes three modules: home information and equipment management, home emergency alarm, and home security monitoring, being simple and practical, easy to operate, and very in line with the basic needs of our family life.


### 3.3. Experimental Environment

#### 3.3.1. Development Environment

(1)Java Development Environment. JDK is the software development kit for the entire Java development, and it is an indispensable development kit for Android program development and WEB server development. (2) Cloud Platform and Its Services. Cloud platform and its services are provided by cloud servers of multiple cloud service platforms. Hadoop platform is installed in the Linux environment to realize the distributed system. When the cloud platform server is configured to Hadoop, all ports are released. (3) Tomcat. Tomcat is one of the popular web application servers, which is free, open source, and stable. (4) IDEA. IDEA can develop Java-based servers, websites, and Android applications.


#### 3.3.2. Test Environment

The hardware equipment of this paper is arranged in the laboratory, including spectrometer, intelligent home gateway, home appliance controller, and home appliance equipment. The service software of the smart home management system is executed on the cloud server, with 1 GB of memory and 1 Mb/s of network bandwidth. The user terminal can choose multiple smart phones and can choose wireless LAN or 4G network for network access.


### 3.4. System Functional Module Test

#### 3.4.1. Main Control Module of the System

In the system designed in this paper, the most core function is the control and monitoring of household electrical equipment. When we click the interface icon to update, the Android client will send this action to the main controller, which will return the acquired data to the Android client after obtaining the real-time on-off status of the household device connected with the main device. The design uses lighting control and fan control instead of other household devices. The main control module of the smart home system is shown in Figure3.Figure 3
Main control module of the system.As we can see from Figure3, the functions of the main module are implemented by the home information or device management module. This module integrates the electrical control in the home, including the electric control of the light, the master switch of the power supply, the air purifier, the ventilator fan, and so on. It also includes the monitoring of the home environment information data, which shows that the user of the smart home system can control the corresponding electrical equipment switch simply by clicking the button of the electrical equipment switch. The home device status is displayed in the home information and device management interface, and the user can know the device status at any time, making it easier for the user to conduct relevant operations.


#### 3.4.2. System Data Prediction Module

Intelligent home detection data are usually home environment data and device status data collected by various sensors. The input data of prediction module can be obtained by combining the environmental data at the same time with the device status data. In this experiment, environmental data and electrical state data at the same time point are combined as one input data. The environmental data set is collected every 300 seconds during the day, and the collection time point of the equipment state data set is relatively random. Therefore, when sorting the data, it is necessary to find the equipment state that is relatively close to the environmental data collection time point, so as to obtain the training sample set. The prediction results of sample data are shown in Figure4.Figure 4
Sample data prediction results.As can be seen from Figure4, 0 and 1, respectively, represent the state of the device switch. When the time period is from 0 to 10, from 12 to 20, and from 22 to 24, the predicted result is consistent with the actual state of the switch. The switching state prediction results of the prediction model proposed in this paper have a high coincidence rate with the original data curves.


### 3.5. System Performance Test

#### 3.5.1. Communication Effect Test of the Smart Home System

The communication effects of the smart home system affect whether the user’s commands are correctly sent to the home gateway. In the communication test of intelligent home system in this paper, the home gateway and five intelligent home controller nodes are arranged in the indoor environment with many obstacles. The network is connected to the home gateway, and the intelligent home controller node and the home gateway form a star network. Make a test program to send control commands and record the status of the node of the home appliance controller. Each node sends control commands 200 times repeatedly, recording the packet loss rate of test cases. The test results of communication effect are shown in Table1 and Figure 5.Table 1
Communication effect test results.
Control node numberNode status update timesSuccess rate (%)119496219898319797.8419898.2519998.7Figure 5
Communication effect test results.As can be seen from Table1 and Figure 5, the test results show that when the number of instructions is 200, the system communication success rate of the five smart home appliance controller nodes is above 96%. At the same time, when the node status updates more times, the communication success rate is higher. Therefore, we can see that the intelligent home system designed in this paper has a good communication effect and can meet the needs of users.


#### 3.5.2. Smart Home System Response Time Test

In the response time test of the smart home system, a test software was created to simulate the performance of the smart home system by continuously sending different request information and recording the response time of the system. The test commands have order commands and control commands. Set 100 test commands to be sent per test cycle, and calculate the response time of the system communication by recording the time of sending the command and the response time of the command. The authentication command means that the user terminal sends a login request to the intelligent home management system that only contains the communication between the user terminal and the management system. The test software simulates the sending gateway name, user name, and user password of the user terminal. Only when the intelligent home management system verifies the information successfully can the login operation be completed. The test results for command response times are shown in Table2 and Figure 6.Table 2
Test results for command response time.
Minimum delayMaximum delayAverage delayFirst testSecond testFirst testSecond testFirst testSecond testAuthentication command110130300320190200Control command200230600580270280Figure 6
Test results of command response time.As can be seen from Table2 and Figure 6, the test results record the maximum wait time, minimum time delay, and average wait time for the response time of each test, respectively. As can be seen from the test results, the authentication command response time is about 195 ms, and the control command response time is about 275 ms. It can be seen from the performance test results of the smart home system that the system designed in this paper responds quickly and the user experience is good.


## 3.1. Data Collection

The test data in this article comes from the UMass Trace Repository Smart∗ project distribution for home data. The Smart Project∗ brings together real-world home environments and device information from three families to help build smart homes. Environmental datasets include indoor and outdoor temperature and humidity, wind speed, and direction. Data are collected every 300 seconds, and data are collected and uploaded by sensors every day. In the experiment of this paper, the data of the living room fan of the equipment data set is trained as the object data.


## 3.2. System Architecture

When users use the system designed in this paper, they first use the mobile phone APP to obtain data from the server through the network, the server communicates with the main center through the network, and the main center communicates with each terminal node in the home environment through the ZigBee network, so as to realize data exchange and control of electrical equipment. The architecture of the system is shown in Figure2.Figure 2
System architecture diagram.According to the market demand and future development, the adaptor system of mobile phone client chooses Android. Through the design of the mobile phone software interface, the user’s operation is easier; users can operate at any time. The system mainly includes three modules: home information and equipment management, home emergency alarm, and home security monitoring, being simple and practical, easy to operate, and very in line with the basic needs of our family life.


## 3.3. Experimental Environment

### 3.3.1. Development Environment

(1)Java Development Environment. JDK is the software development kit for the entire Java development, and it is an indispensable development kit for Android program development and WEB server development. (2) Cloud Platform and Its Services. Cloud platform and its services are provided by cloud servers of multiple cloud service platforms. Hadoop platform is installed in the Linux environment to realize the distributed system. When the cloud platform server is configured to Hadoop, all ports are released. (3) Tomcat. Tomcat is one of the popular web application servers, which is free, open source, and stable. (4) IDEA. IDEA can develop Java-based servers, websites, and Android applications.


### 3.3.2. Test Environment

The hardware equipment of this paper is arranged in the laboratory, including spectrometer, intelligent home gateway, home appliance controller, and home appliance equipment. The service software of the smart home management system is executed on the cloud server, with 1 GB of memory and 1 Mb/s of network bandwidth. The user terminal can choose multiple smart phones and can choose wireless LAN or 4G network for network access.


## 3.3.1. Development Environment

(1)Java Development Environment. JDK is the software development kit for the entire Java development, and it is an indispensable development kit for Android program development and WEB server development. (2) Cloud Platform and Its Services. Cloud platform and its services are provided by cloud servers of multiple cloud service platforms. Hadoop platform is installed in the Linux environment to realize the distributed system. When the cloud platform server is configured to Hadoop, all ports are released. (3) Tomcat. Tomcat is one of the popular web application servers, which is free, open source, and stable. (4) IDEA. IDEA can develop Java-based servers, websites, and Android applications.


## 3.3.2. Test Environment

The hardware equipment of this paper is arranged in the laboratory, including spectrometer, intelligent home gateway, home appliance controller, and home appliance equipment. The service software of the smart home management system is executed on the cloud server, with 1 GB of memory and 1 Mb/s of network bandwidth. The user terminal can choose multiple smart phones and can choose wireless LAN or 4G network for network access.


## 3.4. System Functional Module Test

### 3.4.1. Main Control Module of the System

In the system designed in this paper, the most core function is the control and monitoring of household electrical equipment. When we click the interface icon to update, the Android client will send this action to the main controller, which will return the acquired data to the Android client after obtaining the real-time on-off status of the household device connected with the main device. The design uses lighting control and fan control instead of other household devices. The main control module of the smart home system is shown in Figure3.Figure 3
Main control module of the system.As we can see from Figure3, the functions of the main module are implemented by the home information or device management module. This module integrates the electrical control in the home, including the electric control of the light, the master switch of the power supply, the air purifier, the ventilator fan, and so on. It also includes the monitoring of the home environment information data, which shows that the user of the smart home system can control the corresponding electrical equipment switch simply by clicking the button of the electrical equipment switch. The home device status is displayed in the home information and device management interface, and the user can know the device status at any time, making it easier for the user to conduct relevant operations.


### 3.4.2. System Data Prediction Module

Intelligent home detection data are usually home environment data and device status data collected by various sensors. The input data of prediction module can be obtained by combining the environmental data at the same time with the device status data. In this experiment, environmental data and electrical state data at the same time point are combined as one input data. The environmental data set is collected every 300 seconds during the day, and the collection time point of the equipment state data set is relatively random. Therefore, when sorting the data, it is necessary to find the equipment state that is relatively close to the environmental data collection time point, so as to obtain the training sample set. The prediction results of sample data are shown in Figure4.Figure 4
Sample data prediction results.As can be seen from Figure4, 0 and 1, respectively, represent the state of the device switch. When the time period is from 0 to 10, from 12 to 20, and from 22 to 24, the predicted result is consistent with the actual state of the switch. The switching state prediction results of the prediction model proposed in this paper have a high coincidence rate with the original data curves.


## 3.4.1. Main Control Module of the System

In the system designed in this paper, the most core function is the control and monitoring of household electrical equipment. When we click the interface icon to update, the Android client will send this action to the main controller, which will return the acquired data to the Android client after obtaining the real-time on-off status of the household device connected with the main device. The design uses lighting control and fan control instead of other household devices. The main control module of the smart home system is shown in Figure3.Figure 3
Main control module of the system.As we can see from Figure3, the functions of the main module are implemented by the home information or device management module. This module integrates the electrical control in the home, including the electric control of the light, the master switch of the power supply, the air purifier, the ventilator fan, and so on. It also includes the monitoring of the home environment information data, which shows that the user of the smart home system can control the corresponding electrical equipment switch simply by clicking the button of the electrical equipment switch. The home device status is displayed in the home information and device management interface, and the user can know the device status at any time, making it easier for the user to conduct relevant operations.


## 3.4.2. System Data Prediction Module

Intelligent home detection data are usually home environment data and device status data collected by various sensors. The input data of prediction module can be obtained by combining the environmental data at the same time with the device status data. In this experiment, environmental data and electrical state data at the same time point are combined as one input data. The environmental data set is collected every 300 seconds during the day, and the collection time point of the equipment state data set is relatively random. Therefore, when sorting the data, it is necessary to find the equipment state that is relatively close to the environmental data collection time point, so as to obtain the training sample set. The prediction results of sample data are shown in Figure4.Figure 4
Sample data prediction results.As can be seen from Figure4, 0 and 1, respectively, represent the state of the device switch. When the time period is from 0 to 10, from 12 to 20, and from 22 to 24, the predicted result is consistent with the actual state of the switch. The switching state prediction results of the prediction model proposed in this paper have a high coincidence rate with the original data curves.


## 3.5. System Performance Test

### 3.5.1. Communication Effect Test of the Smart Home System

The communication effects of the smart home system affect whether the user’s commands are correctly sent to the home gateway. In the communication test of intelligent home system in this paper, the home gateway and five intelligent home controller nodes are arranged in the indoor environment with many obstacles. The network is connected to the home gateway, and the intelligent home controller node and the home gateway form a star network. Make a test program to send control commands and record the status of the node of the home appliance controller. Each node sends control commands 200 times repeatedly, recording the packet loss rate of test cases. The test results of communication effect are shown in Table1 and Figure 5.Table 1
Communication effect test results.
Control node numberNode status update timesSuccess rate (%)119496219898319797.8419898.2519998.7Figure 5
Communication effect test results.As can be seen from Table1 and Figure 5, the test results show that when the number of instructions is 200, the system communication success rate of the five smart home appliance controller nodes is above 96%. At the same time, when the node status updates more times, the communication success rate is higher. Therefore, we can see that the intelligent home system designed in this paper has a good communication effect and can meet the needs of users.


### 3.5.2. Smart Home System Response Time Test

In the response time test of the smart home system, a test software was created to simulate the performance of the smart home system by continuously sending different request information and recording the response time of the system. The test commands have order commands and control commands. Set 100 test commands to be sent per test cycle, and calculate the response time of the system communication by recording the time of sending the command and the response time of the command. The authentication command means that the user terminal sends a login request to the intelligent home management system that only contains the communication between the user terminal and the management system. The test software simulates the sending gateway name, user name, and user password of the user terminal. Only when the intelligent home management system verifies the information successfully can the login operation be completed. The test results for command response times are shown in Table2 and Figure 6.Table 2
Test results for command response time.
Minimum delayMaximum delayAverage delayFirst testSecond testFirst testSecond testFirst testSecond testAuthentication command110130300320190200Control command200230600580270280Figure 6
Test results of command response time.As can be seen from Table2 and Figure 6, the test results record the maximum wait time, minimum time delay, and average wait time for the response time of each test, respectively. As can be seen from the test results, the authentication command response time is about 195 ms, and the control command response time is about 275 ms. It can be seen from the performance test results of the smart home system that the system designed in this paper responds quickly and the user experience is good.


## 3.5.1. Communication Effect Test of the Smart Home System

The communication effects of the smart home system affect whether the user’s commands are correctly sent to the home gateway. In the communication test of intelligent home system in this paper, the home gateway and five intelligent home controller nodes are arranged in the indoor environment with many obstacles. The network is connected to the home gateway, and the intelligent home controller node and the home gateway form a star network. Make a test program to send control commands and record the status of the node of the home appliance controller. Each node sends control commands 200 times repeatedly, recording the packet loss rate of test cases. The test results of communication effect are shown in Table1 and Figure 5.Table 1
Communication effect test results.
Control node numberNode status update timesSuccess rate (%)119496219898319797.8419898.2519998.7Figure 5
Communication effect test results.As can be seen from Table1 and Figure 5, the test results show that when the number of instructions is 200, the system communication success rate of the five smart home appliance controller nodes is above 96%. At the same time, when the node status updates more times, the communication success rate is higher. Therefore, we can see that the intelligent home system designed in this paper has a good communication effect and can meet the needs of users.


## 3.5.2. Smart Home System Response Time Test

In the response time test of the smart home system, a test software was created to simulate the performance of the smart home system by continuously sending different request information and recording the response time of the system. The test commands have order commands and control commands. Set 100 test commands to be sent per test cycle, and calculate the response time of the system communication by recording the time of sending the command and the response time of the command. The authentication command means that the user terminal sends a login request to the intelligent home management system that only contains the communication between the user terminal and the management system. The test software simulates the sending gateway name, user name, and user password of the user terminal. Only when the intelligent home management system verifies the information successfully can the login operation be completed. The test results for command response times are shown in Table2 and Figure 6.Table 2
Test results for command response time.
Minimum delayMaximum delayAverage delayFirst testSecond testFirst testSecond testFirst testSecond testAuthentication command110130300320190200Control command200230600580270280Figure 6
Test results of command response time.As can be seen from Table2 and Figure 6, the test results record the maximum wait time, minimum time delay, and average wait time for the response time of each test, respectively. As can be seen from the test results, the authentication command response time is about 195 ms, and the control command response time is about 275 ms. It can be seen from the performance test results of the smart home system that the system designed in this paper responds quickly and the user experience is good.


## 4. Conclusions

(1)
In the design of mobile phone client in this paper, basic functions required by the home are designed by combining the actual situation of the family, including the management of family equipment and management of environmental information, one-button alarm, and some modules of family security monitoring. Close to people’s daily life, practical high. Through the combination of the mobile phone client and the family control center, the task of remote family management is completed, and the privacy and security of the family are protected in the monitoring design, which is closer to the needs of personal family life.(2)
This paper completed the test of the Internet-based smart home management system. By setting up a test environment, this paper completes the performance test of the system on the basis of the test platform, including the system communication effect and command response time. The test results show that the intelligent home system designed in this paper has good performance and can meet the user’s needs. This also proves that the Internet-based smart home system is feasible.(3)
At present, the Internet-based intelligent home system designed in this paper only provides users with basic functions such as user information management, video monitoring, furniture electrical management, and equipment control on the mobile phone client. With the popularity and development of smart home, users can have video calls, community forums, transactions, and other functions. In addition, when the smart home system is applied in a wider range, we should provide terminal services for the staff of community management, so as to facilitate the staff to manage the environment and security of the community. Therefore, this paper needs to further expand and improve the function of the system.Network remote control requires a specific IP address. Due to time and cost issues, only a design plan is proposed for this part, and the actual control is not completed.



---

*Source: 1031682-2022-06-13.xml*