Design and Implementation of the Application Layer Communication Protocol Based on Wireless Sensor Network

Similar documents
Study of Smart Home System based on Zigbee Wireless Sensor System. Jie Huang 1

A Design of Remote Monitoring System based on 3G and Internet Technology

Serial Communication Based on LabVIEW for the Development of an ECG Monitor

Communication Stability Experiment of IOT Car Based on WIFI and Bluetooth

Design of Smart home System Based on Basic Radio Frequency Wireless Sensor Network

A Multipath AODV Reliable Data Transmission Routing Algorithm Based on LQI

Research and Implementation of the Key Technology of UAV Aerial Image. Transmission

The Research of Internet of Things in Operation and Maintenance for Distribution Grid

Agriculture Wireless Temperature and Humidity Sensor Network Based on ZigBee Technology

Research into a Wireless Smart Parking System

Key Technology of Monitoring and Control for Coal Shearer Supporting Network Convergence

On the Expansion of Access Bandwidth of Manufacturing Cloud Core Network

AN WIRELESS COLLECTION AND MONITORING SYSTEM DESIGN BASED ON ARDUINO. Lu Shaokun 1,e*

Geospatial Information Service Based on Ad Hoc Network

The Design of Supermarket Electronic Shopping Guide System Based on ZigBee Communication

Wireless Smart Home Security System Based on Android

Embedded Smart Home System Based on ZigBee Song Chi

Design of Greenhouse Temperature and Humidity Monitoring System Based on ZIGBEE Technique Ming Xin 1,a, Wei Zhongshan 1,b,*

Research on Two - Way Interactive Communication and Information System Design Analysis Dong Xu1, a

Remote Monitoring System of Ship Running State under Wireless Network

The Application of Wireless Sensor in Aquaculture Water Quality Monitoring

A Network Disk Device Based on Web Accessing

A Field Monitor System of Rodpumped Wells Based on GPRS

Fingerprint Verification Terminal of Examination Information Based on Qt Mengtao Huang 1, Mengyao Han 2

The Design of Wireless Data Acquisition and Remote Transmission Interface in Micro-seismic Signals

2017 International Conference on Economics, Management Engineering and Marketing (EMEM 2017) ISBN:

Intelligent Mobile Monitoring and Control Network of Oil Pipeline Based on Internet of Things

Test Analysis of Serial Communication Extension in Mobile Nodes of Participatory Sensing System Xinqiang Tang 1, Huichun Peng 2

Design of Coal Mine Power Supply Monitoring System

A Novel Intrusion Detection Method for WSN Sijia Wang a, Qi Li and Yanhui Guo

Design and Implementation of Agricultural Intelligent Monitoring System. based on the Android Platform. Liang Haili 1, a

The Research and Design of the Android-Based Facilities Environment Multifunction Remote Monitoring System*

A Data Collecting and Caching Mechanism for Gateway Middleware in the Web of Things

THE DESIGN OF GREENHOUSE ENVIRONMENT MONITORING SYSTEM BASED ON ZIGBEE

Exploration of Fault Diagnosis Technology for Air Compressor Based on Internet of Things

Mitigating Hot Spot Problems in Wireless Sensor Networks Using Tier-Based Quantification Algorithm

Battery Energy Storage System Information Modeling Based on IEC 61850

Design of Desert Plant Monitoring System Based on SI446X Wireless Radio Frequency Communication

The Application Analysis and Network Design of wireless VPN for power grid. Wang Yirong,Tong Dali,Deng Wei

An Energy Efficiency Routing Algorithm of Wireless Sensor Network Based on Round Model. Zhang Ying-Hui

Nodes Energy Conserving Algorithms to prevent Partitioning in Wireless Sensor Networks

Agricultural Collection System Based on Zigbee

Jacquard Control System of Warp Knitting Machine Based on Embedded System

Relaxation Control of Packet Arrival Rate in the Neighborhood of the Destination in Concentric Sensor Networks

A High-Speed Wireless Transmission Scheme for Wireless Sensor Network

Design of Wireless Sensing Virtual Cloud Desktop System Based on ARM-Linux

Information Acquisition System Based on ZigBee and ARM

Performance Evaluation of CoAP and UDP using NS-2 for Fire Alarm System

Research on Transmission Based on Collaboration Coding in WSNs

Model the P2P Attack in Computer Networks

The Design of Electronic Color Screen Based on Proteus Visual Designer Ting-Yu HOU 1,a, Hao LIU 2,b,*

Network protocol for Internet of Things based on 6LoWPAN

Open Access Universal Real-time Monitoring System Based on Ethernet in Test and Measurement Domain

The Analysis and Research of IPTV Set-top Box System. Fangyan Bai 1, Qi Sun 2

The Design and Development of the Precision Planter Sowing Depth Control System

World Journal of Engineering Research and Technology WJERT

The Design of the Embedded WEB Server Based on ENC28J60

A Design of Greenhouse Remote Monitoring System Based on WSN and WEB

Design of Smart Home System Based on ZigBee Technology and R&D for Application

International Conference on Information Sciences, Machinery, Materials and Energy (ICISMME 2015)

An Solution of Network Service Oriented Operator Network Intrusion Prevention

CLUSTER BASED ROUTING PROTOCOL FOR WIRELESS SENSOR NETWORKS

Research on Approach of Equipment Status and Operation Information Acquisition Based on Equipment Control Bus

A Multi-channel Smart Strain Sensor with IEEE 1451 Protocol

Energy Conservation through Sleep Scheduling in Wireless Sensor Network 1. Sneha M. Patil, Archana B. Kanwade 2

A Method of Identifying the P2P File Sharing

Analysis and Performance evaluation of Traditional and Hierarchal Sensor Network

A New Approach to Sensor Energy Saving Algorithm

Design and Application of Electrical Equipment Overheating Monitoring Based on Wireless Sensor

Design and Implementation of Somatosensory Teaching Pendant System Based on Android Platform

Research on Multi-service Unified Bearing Electric Power Communication Access Network Bao Feng1,a, Yang Li1, Yang Hu1, Yan Long2, Yongzhong Xie3

Journal of Chemical and Pharmaceutical Research, 2014, 6(6): Research Article

Cemetery Navigation and Information Query System Based on Android and Java Web

The Design of Wireless Communication System Based on STC12+CC1101 Zhijian Yin 1, a, Kun Xiang 2,b,Wang Fan 3,c

An intelligent LED landscape lighting system

Analysis and Implementation Wireless Sensor Network of Information Technology Systems

An Improved Gateway Based Multi Hop Routing Protocol for Wireless Sensor Network

The design and implementation of UML-based students information management system

Hardware design of a submerged buoy system based on electromagnetic inductive coupling

Mobile Agent Driven Time Synchronized Energy Efficient WSN

Transmitter Station Remote Monitor System Based on Browser/Server Structure

Design of Coal Mine Comprehensive Parameters Monitoring System Based on DSP

Wireless Sensor Environment Monitoring System for Chemical Industrial Areas Based on Path Selection Routing Algorithm

The framework of next generation automatic weather station in China

The Monitoring System of Water Environment Based on Overlay Network Technology 1

101seminartopics.com. Bluetooth Based Smart Sensor Networks

Design of Temperature and Humidity Data Acquisition System. Based on ARM

Research of tooling test signal collection and analysis Guozhuang Liang 1, a, Xuan Chen 1,b,Yufeng Yao 2,c

International Journal of Advance Engineering and Research Development

Open Access Design and Implementation of the Infant Incubator Intelligent Control System Based on Internet of Things. Tianshun Huang * and Leiming Sun

Collaborative Image Compression Algorithm In Wireless Multimedia Sensor Networks

Study on monitor system of pollution discharge in chemical enterprise based on internet of things

A Novel Data Mining Platform Design with Dynamic Algorithm Base

Research on Heterogeneous Communication Network for Power Distribution Automation

Research on IOT Intelligent Gateway Service Mechanism and System Implementation

Comprehensive analysis and evaluation of big data for main transformer equipment based on PCA and Apriority

WSN WIRELESS WSN WSN WSN. Application agriculture SENSOR. Application geophysical. Application agriculture NETWORK: 11/30/2016

International Conference on Advances in Mechanical Engineering and Industrial Informatics (AMEII 2015)

Research Article. ISSN (Print) *Corresponding author Chen Hao

An Automatic Control Method of Foam Spraying Glue Machine based on DMC Yu-An HEa,*, Tian CHENb

Transcription:

TELKOMNIKA, Vol. 11, No. 8, August 2013, pp. 4788~4793 e-issn: 2087-278X 4788 Design and Implementation of the Application Layer Communication Protocol Based on Wireless Sensor Network Changshun Chen College of Information Engineering,Yangzhou Polytechnic College Wenchang west road 458, Yangzhou, Jiangsu, China, telp/fax:0514-87697092 e-mail: 1025469638@qq.com Abstract The user-defined communication protocol is the key step to develop application system based on Wireless Sensor Network. Through the analysis on the application of the wireless sensor network architecture and communication needs, a kind of simple and practical application layer communication protocol with detailed design of protocol data structure is proposed in this paper. Based on that, a communication protocol programming prototype is written in C# language. Through the test of wireless sensor network intelligent community monitoring system, it proves that the system data transmission based on this proposal is reliable and programming is simple and convenient. Keywords: wireless sensor network, communication protocol, data structure, program prototype Copyright 2013 Universitas Ahmad Dahlan. All rights reserved. 1. Introduction Wireless Sensor Networks(WSN) is a distributed network using wireless communication technology to realize information collection, transmission and processing [1-2]. In the study of Wireless Sensor Networks, data transmission method or protocol is always a research hotspot in this field, and communication protocol with simple and effective and easy programming is mostly hopeful to quickly build application system. In this paper, a simple communication model is established through analysis on the application of the wireless sensor network architecture and communication needs, and a programming prototype which can rapidly achieve application system is also designed. 2. Basic Framework of Application System The typical application system of wireless sensor network is composed of a host machine, convergence gateway and control unit. The basic architecture can be seen in Figure 1. Figure 1. The Basic Architecture of Wireless Sensor Network According to the demand of application, the control unit node is reasonably distributed in the control region. Control unit comprises two modules of the sensing and control, which can Received January 15, 2013; Revised May 25, 2013; Accepted June 3, 2013

TELKOMNIKA e-issn: 2087-278X 4789 be selected by software. Nodes automatically form a network through the network adaptive function and communicate with the convergence gateway through the route hop or jump. Convergence gateway is the distributing centre of measuring and controlling node data transmission. It on one hand transmits the control command from host machine to the control nodes and on the other hand, receives sensor data of each control node. Convergence gateway can be connected with the host computer through the RS-232 serial mode, GPRS, 3G, WiFi and broadband networks. The host computer receives the upload perception data of convergence gateway, and stores them into the database after analysis. These stored data can be presented to the managers in ordinary form or web mode for query, statistics and history tracking, and also can send control demand to realize the closed loop control of the specified object by gathering gateway starting control unit according to the management command [3-4]. 3. Communication Protocol Architecture Wireless sensor network is data-centric task network, the nodes of which using the identification number, commands and data transmission among nodes, convergence gateway and host machine are all dependent on the network communication protocol which includes the physical layer, data link layer, network layer, transport layer and application layer. The system structure is shown in Figure 2 [5-7]. Figure 2. Wireless Sensor Network Communication Protocol Architecture The application layer is closely related to the specific application and environment and design of which depends on the specific application demand. The main task of application layer is the acquisition of data and a preliminary treatment. The characteristics of basing on the data center and facing to the specific application require the WSN to quickly and effectively organize the information of each node and fusion to extract useful information directly to the users, instead of the traditional network addressing process. Meanwhile, in order to adapt to different network requirements, the function of clock synchronization, positioning technology and so on should also be considered [8-10]. 4. Design of Application Layer Communication Protocol Based on the above analysis, the main problems to solve for the application layer communicationprotocol in wireless sensor networks include two aspects, i.e., how to send collection and control command from host computer to nodes and how to return sensor data from nodes to host machine. 4.1. Downlink Design When the host computer sends command to coordinate gateway and then gateway sends it to controlnode, there are four factors should be considered. First is the difference of sensor data acquisition and actuator control, the second is the command execution node pointing and selection, the third is the physical differences between different actuator, and the Design and Implementation of the Application Layer Communication (Changshun Chen)

4790 e-issn: 2087-278X last one is programming and analysis convenience of command data package. Based on this, the downlink command data pachage structure is designed as shown in Table.1. Table 1. WSN Downlink Packet Structure name head type address parameter tail 1 3 3 2 6 1 R/T + XX R:collect Null value repalced # WSN 0x---- * T:control by N head: the beginning of identify command, fixed as ANSI symbol #. type: named as ANSI symbol WSN for wireless sensor network. name: command detail content, for example: the noise sensor data acquisition, starting stepper motor etc. address: the network node command directed to. parameter: identification command used for command expansion. tail: the end of identification command, fixed as ANSI symbol *. According to the above protocol format, the downlink command for noise data acquisition, DC motor control, and RFID card control is shown in Table 2. Table 2. WSN Downlink command value Noise acquisition #WSNRZS+node network address(2)+nnnnnn * DC motor control #WSNTZL+node network address(2)+turn(1)+speed(1)+nnnn* RFID card control #WSNTRF+node network address(2)+open or close RFIDreader control code(1)+nnnnn* 4.2. Design of Upstream Return Data Package After the host machine sends collection and control command to WSN, nodes receive the command, analysis and execute it and return the results to the host computer. Two aspects information should be included in the return data package: one is whether the execution is successful; the other is, if successful, returning the collected sensor data in a specific format. The return data package design can be seen in Table 3. Table 3. WSN Return Data Package Structure head type name status address return data tail 1 3 3 1 2 21 1 # WSN R/T + XX S:success Null value R:collect 0x---- E:failure replaed by N T:control * Definition and command of return data package are similar. According to the above protocol rule,the result data return package from noise and RFID control node is listed in Table 4. Table 4. WSN Return Data Package command return data package Noise acquisition #WSNRZS+node network address(2)+nnnnnn * RFIDcard control #WSNRZS+command status(1)+node network address(2)+ noise data(1)+ NNNNNNNNNNNNNNNNNNNN* RFID card control #WSNTRF+command status(1)+node network address(2)+rfid card number data(16)+ NNNNN* TELKOMNIKA Vol. 11, No. 8, August 2013: 4788 4793

TELKOMNIKA e-issn: 2087-278X 4791 5. Application of the Application Layer Communication Protocol in the Monitoring and Management System of Intelligent Community Based on the above communication protocol, a monitoring and management system of Intelligent Community with PC as host machine, CC2530 as the core to form the intelligent measurement and control node, ARM6410 as the core of setting up the coordination gateway, is developed. Host computer runs the monitoring and management program, convergence gateway is in charge of the establishment and management of WSN network, and the control nodes are responsible for the implementation of the sensing data colletion and control command. Whether in PC or nodes, the method for programming the application layer protocol is similar, that is, firstly converting the user demand into the command of byte protocol specification, and then sending it from host PC to the convergence gateway, which analyze the command and start the acquisition or actuator of corresponding nodes control. After finishing the task, the collection result or the state of execution will be organized according to the protocol specification into data package and returned to the host machine. Finally, the host computer analizes the acquired data package, separats the relevant information to display and store, compares the return results with the present value and determines the next command need to issue [8]. Limiting to the length of paper, only the core C# program in host computer relevant with applicationlayer protocol is presented as flows, the programs in convergence gateway and control nodes are similar. namespace WinFormMonitor public partial class Form_Monitor : Form // Initialization, definition of process variables List<byte> datalist = new List<byte>(); StringBuilder strbud = new StringBuilder(); StringBuilder strbud1 = new StringBuilder(); //form loading, serial port setting up and opening private void Form_Monitor_Load(object sender, EventArgs e) s_port.portname = comports.text; s_port.baudrate = int.parse(comrate.text); s_port.open(); //the host computer send downlink command to WSN through the serial prot. private void SendNetCmd(string s) //transfer the command to the corresponding byte code List<byte> buf = new List<byte>(); buf.add(convert.tobyte('#')); buf.add(convert.tobyte('r')); buf.add(convert.tobyte('z')); buf.add(convert.tobyte('s')); buf.add(convert.tobyte(0x01)); buf.add(convert.tobyte(0x00)); buf.add(convert.tobyte('n')); buf.add(convert.tobyte('*')); //write the byte code command to the serial buffer s_port.write(buf.toarray(), 0, buf.count); timermain.enabled = true; // when the serial port receives the return data from sensor node private void s_port_datareceived(object sender, SerialDataReceivedEventArgs e) int n = s_port.bytestoread; byte[] buf = new byte[n]; s_port.read(buf, 0, n); Design and Implementation of the Application Layer Communication (Changshun Chen)

4792 e-issn: 2087-278X this.invoke((eventhandler) foreach (byte b in buf) datalist.add(b); // Regular inspection, analysis of serial port received postback data and corresponding treatment private void timermain_tick(object sender, EventArgs e) for (int i = 0; i <= record.count - 1; i++) // Check the command type for (int j = 5; j <= 7; j++) strbud1.clear(); strbud1.append(record [i][j].tostring()); ComType += strbud1.tostring; // Check the command execution status for (int j = 8; j <= 8; j++) strbud1.clear(); strbud1.append(record [i][j].tostring()); ComState += strbud1.tostring(); // The corresponding treatment according to the results of analysis if (DatType == "5A5353") //noise for (int j = 10; j <= 10; j++) strbud1.clear(); strbud1.append(record [i][j].tostring()); zsdata += strbud1; zs = (Convert.ToDecimal(zsData)).ToString(); listview1.items.add(new ListViewItem(new string[] netadr, zs )); 6. Conclusion System structure of communication protocol for Wireless Sensor Networks is studied in the view of developing wireless sensor network application system in this paper. A application layer communication protocol based on architecture model of host machine, coordinate gateway, and control node is designed and the detailed programming scheme and prototype is also given. Through the practical application of wireless sensor network in intelligent community monitoring system, it is confirmed that this scheme is convenient in programming, reliable in communication and stable in system. The application layer protocol for wireless sensor network designed in this paper has good portability and scalability. On the basis of maintaining the overall scheme of the protocol,with slight adjustment and expansion on the reservation, it can be applied in a variety of application fields and then the intelligent application system based on wireless sensor network can be quickly developed. TELKOMNIKA Vol. 11, No. 8, August 2013: 4788 4793

TELKOMNIKA e-issn: 2087-278X 4793 References [1] Atzori L, Ieraand A, Morabito G. The Internet of things: A survey. Computer Network. 2010; 54(15): 2787-2805. [2] Ruiling Liu, Xianglin Li. Summary of wireless sensor network research and Application. Computer application technology. 2010; 6(12): 3093-3094. [3] Changlin Shu et al. Method for wireless sensor network component development. Micro computer information. 2010; 26(3-2): 30-32. [4] Endong Tong et al. Service construction and concurrency control of sensor network. Journal of electronic science and technology university. 2011; 40(3): 322-332. [5] Xiang Chen. Research on security strategy based on Wireless Sensor Network. Digital technology and application. 2010; 5. [6] GUO L W, LIU D H, ZHANG X L, et al. Design of intelligent detecting system based on wireless transmission. Journal of Hejiang University (SCIENCE A). 2007; 8(3): 490-494. [7] Li Baozhu, Wang Hui.A low complexity localization algorithm in wireless sensor network. Innovative Computing & Communication. 2010: 1260-1264. [8] WON-SUK J, WILLIAM M, MIROSLAW J. Wireless sensor networks as part of a web-based building environmental monitoring system. Automation in Construction. 2008; 17(3): 29-736. [9] Babak Namazi. EnergyEfficient MultiSPEED Routing Protocol for Wireless Sensor Networks. International Journal of Electrical and Computer Engineering (IJECE). 2013; 3(2). [10] Chin-Yuan Hsieh. Prediction of Forest Temperature Microchange by Wireless Sensor Network Technology. International Journal of Electrical and Computer Engineering (IJECE). 2012; 2(5): 632-638. Design and Implementation of the Application Layer Communication (Changshun Chen)