CN103731510B - Data interaction method for application layer of wireless sensor network based on IPv6 (internal protocol version 6) - Google Patents

Data interaction method for application layer of wireless sensor network based on IPv6 (internal protocol version 6) Download PDF

Info

Publication number
CN103731510B
CN103731510B CN201410036153.1A CN201410036153A CN103731510B CN 103731510 B CN103731510 B CN 103731510B CN 201410036153 A CN201410036153 A CN 201410036153A CN 103731510 B CN103731510 B CN 103731510B
Authority
CN
China
Prior art keywords
byte
equipment
application
shortcut
frame
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201410036153.1A
Other languages
Chinese (zh)
Other versions
CN103731510A (en
Inventor
王恒
王平
王娜
邹继
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Chongqing University of Post and Telecommunications
Original Assignee
Chongqing University of Post and Telecommunications
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Chongqing University of Post and Telecommunications filed Critical Chongqing University of Post and Telecommunications
Priority to CN201410036153.1A priority Critical patent/CN103731510B/en
Publication of CN103731510A publication Critical patent/CN103731510A/en
Application granted granted Critical
Publication of CN103731510B publication Critical patent/CN103731510B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Communication Control (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention discloses a data interaction method for an application layer of a wireless sensor network based on IPv6 (internal protocol version 6), which belongs to the technical field of industrial wireless sensor networks. The method comprises the following steps: according to the design of a 6LoWPAN protocol stack and the application needs of a wireless sensor network, designing a whole framework of an application layer, introducing an application layer technique and an object concept to the protocol stack, designing an application layer frame header meeting the requirements of the protocol stack, selecting and realizing a particular inter-node communication mode for the data transmission and interaction of the application layer, and designing a frame format in a corresponding communication mode; designing a data interaction frame format of the application layer; and designing a shortcut mechanism of the application layer, an object relationship establishment function and a corresponding command frame format, and implementing in a mechanism of a protocol stack state machine. According to the invention, a user application object is defined so as to perform data interaction with industrial process data; and an application layer communication service is defined so as to support the communication among multiple objects of distributed applications in an industrial environment.

Description

A kind of application of higher wireless sensor network layer data exchange method based on IPv6
Technical field
The invention belongs to industrial wireless sensor network technical field, and in particular to a kind of wireless senser based on IPv6 Network application layer data interactive method.
Background technology
6LoWPAN protocol stacks have multiple structure, and each layer all provides specific service for its levels:Data entity is carried For data, services, management entity provides management service.Per layer of definition and design for having related protocol in 6LoWPAN protocol stacks. Wherein, PHY layer and MAC layer adopt IEEE802.15.4 agreements, and Internet adopts IPv6 agreements, also, in order to realize MAC layer with The seamless connection of Internet, 6LoWPAN protocol stacks define adaptation layer between Internet and MAC layer, and for application layer, 6LoWPAN protocol stacks do not explicitly define its correlation function and communication pattern.Therefore, it is within the contemplation of the invention that design one kind is based on The application of higher wireless sensor network layer data exchange method of IPv6, enable data in 6LoWPAN protocol stack application layers accurately, Faster, preferably transmit and interact.
As the application layer of 6LoWPAN protocol stack important component parts, which employs Objects Mechanism, by each object and Service can fully meet the demand of user and industry spot.The application layer framework of 6LoWPAN protocol stacks is divided into UPL layers and APS Layer two-layer.UPL includes some user's application process (UAP), and each UAP includes some objects, and which utilizes the service that APS layers are provided The communication between node device is completed, UAP management functions are particularly important in industry wireless network, and which causes processing tube in a device Reason application process is more convenient;APS layers, as the interface between Internet and application layer, are that UPL layers and Internet provide phase Close service.
The content of the invention
It is an object of the invention to according to the design of existing 6LoWPAN protocol stacks, and industrial wireless sensor network Feature, proposes a kind of wireless sensor network based on IPv6 that can be ensured normal data transfer in industrial environment and interact Application layer data exchange method, with reference to the application demand of industrial wireless sensor network, application layer data form reasonable in design, Proper communication between commercial Application object is realized with this, improve data transfer and the reliability for interacting in industry wireless network, Ensure the quality of communication service in management user's application process and network.
For reaching above-mentioned purpose, it is as follows that the present invention provides technical scheme:
A kind of application of higher wireless sensor network layer data exchange method based on IPv6, for the data transfer of industrial process With interact and industrial environment in Distributed Application multiple objects between communication.
In the wireless sensor network, the realization of data interaction is carried out by object approach, and the data wherein transmitted have Unified data frame format.
According to design and the application demand of wireless sensor network of 6LoWPAN protocol stacks, whole application layer framework is designed, Application layer framework is divided into UPL layers and APS layer two-layers by methods described, and wherein APS layers are used as connecing between Internet and application layer Mouthful, be that UPL layers and Internet provide service, there is provided service include data, services, management service and to management object properties Operation.Two entities of APSDE and APSME are included in APS layers, provide clothes by the two entities to application and lower floor Business, APSDE provide data, services to Internet and application end so that can be in two or more equipment rooms between application program Transmission;APSME provides management service, it is allowed to which application program is interacted with protocol stack.
Specifically, application sublayer APS provides six kinds of services, is respectively:Application layer equipment is in client/server (Client/Server) confirmation operation is read and write, performs and is reported under communication pattern;In publish/subscribe (Publisher/ Subscriber) issue operation is carried out under communication pattern;Reporting operations are carried out under report (Report/Sink) communication pattern.
User's application process and device management application process carry out object all based on the service provided using sublayer Between communication.
Further, the model according to application layer at the middle and upper levels with sublayer, introduces application layer technology and right in wireless senser As concept, the Classification Management to service provided is realized.
Further, design meets the application data frame head form of protocol stack requirement, selects suitably to be used for application layer data Specific communication pattern between the node of transmission and interaction, including passive client/server (Client/Server) communication pattern, Proactive dissemination/subscription (Publisher/Subscriber) communication pattern and Active report (Report/Sink) communication pattern, and Command frame format under three kinds of communication patterns of design.
Further, application layer data interaction frame format is designed, including reading and writing, execution, report, report confirmation and release work( The application layer data interaction frame format of energy and its corresponding load format.
Further, application layer shortcut mechanism and the command frame format based on shortcut mechanism are designed.Realize industry The data communication of wireless sensor network low energy consumption.Service is read and write in the multiple parameters to same wireless sensor node Shi Caiyong this mechanism, can more preferably, more easily realize data communication.
Further, design object relation sets up the command frame format that function and object relation are set up under function, real in network Showed set up relationship object directly can be communicated without other equipment aid in, to save energy consumption, in making network Distinct device carries out object relation foundation, realizes the complementary logic connection of function of application between distinct device.
The beneficial effects of the present invention is, relative to existing application of higher wireless sensor network layer data interaction technique side Wireless sensor network, IPv6 technologies, application layer data interaction technique are combined by method, the present invention, are devised one kind and are based on The application of higher wireless sensor network layer data exchange method of IPv6.The method meets IPv6 Protocol of Wireless Snesor Network Demand, can be very good to operate on IPv6 Protocol of Wireless Snesor Network, carries out between equipment the transmission of data and interacts. Meanwhile, the method increase the reliability of data transfer in industry wireless network, it is ensured that the management of user's application process and The quality of communication service in network.
Description of the drawings
Fig. 1 IPv6 Protocol of Wireless Snesor Network system figures
Fig. 2 IPv6 application of higher wireless sensor network Rotating fields figures
Fig. 3 Client/Server communication pattern data interaction figures
Fig. 4 Publisher/Subscriber communication pattern data interaction figures
Fig. 5 Report/Sink communication pattern data interaction figures
Fig. 6 shortcut mechanism communication data interaction figures
Fig. 7 object relations set up Configuration Online mode data interaction figure
Fig. 8 object relations set up the centralized inquiry data interaction figure of pre-configured mode
Fig. 9 object relations set up pre-configured mode distributed query data interaction figure.
Specific embodiment
In order that the object, technical solutions and advantages of the present invention are clearer, below in conjunction with accompanying drawing the present invention is made into The detailed description of one step:
IPv6 Protocol of Wireless Snesor Network system is as shown in figure 1, application layer is located at the protocol stack the superiors.The present invention sets Whole application layer framework is counted, application layer framework design has been divided into into UPL and APS two-layers.
IPv6 application of higher wireless sensor network Rotating fields are as shown in Figure 2.Wherein, APS layers contain IPv6 device objects, set Standby discovery feature and service discovery function.Wherein IPv6 device objects provide initialization application support sublayer, Internet, safety clothes Business specification;APS layers are that Internet and application layer provide interface, include two entities of APSDE and APSME in APS layers.APSDE Data, services are provided to Internet and application end so that can transmit in two or more equipment rooms between application program; APSME provides management service, it is allowed to which application program is interacted with protocol stack.By the two entities to application and lower floor Service is provided.
Application layer management information object properties attribute necessary to the application layer-management of equipment is constituted.Table 1 is described in detail The attribute included by application layer management information object.
Table 1:Application layer management information object properties
Secondly, the frame format of APS layers is devised, APS layer frames are divided into frame head and load two parts.APS layer Generic Frame Formats As shown in table 2.
Table 2:APS layer Generic Frame Formats
Below the design to 2 each field of table is described in detail:
(1) frame control field, length are 8.COS, acknowledgement frame and security mechanism equipotential is there is defined, will be It is discussed in detail in table 5.
(2) number of frames field, length are 8.Represent the sequence number of currently transmitted frame.
(3) Service ID field, length are 8.When client sends request message, this position is set to 0; When server sends response message to client, this position is set to 1.Service ID is 0 in program initialization, often performs clothes Business, service ID add 1, and consistent with service ID in response in the request of same service.
(4) address field/shortcut domain field, length are 16.During for address field, the field format is as shown in table 3, Wherein source object id field length is 8, represents the attribute of node oneself, and the load of corresponding frame carries the further category of node Property;Destination object ID represents the attribute of target device, and its value to must not exceed 223, i.e. front three can not be 111.For quick During mode domain, as shown in table 4, the front three of wherein shortcut control field is fixed as 111 to the field format.
Table 3:Address field/shortcut domain field is used for address field form
1 byte 1 byte
Source object ID Destination object ID
Table 4:Address field/shortcut domain field is used for shortcut domain form
1 byte 1 byte
Shortcut is controlled Shortcut ID
(5) module provided by security service described later by security domain field is managing.
Wherein frame control field everybody be specifically defined as shown in table 5:
Table 5:Frame control field form
3 1 1 3
COS Whether acknowledgement frame is needed Security mechanism It is reserved
Below the design to 5 each field of table is described in detail:
(1) COS son field, length are 3.000 represents Client/Server communication patterns, and 001 represents Publish/Subscribe communication patterns, 010 represents Report/Sink communication patterns, and 011 represents that present frame is acknowledgement frame, 100 expression present frames set up function frame for object relation.
(2) acknowledgement frame son field whether is needed, length is 1.0 expression is not needed, and 1 represents needs.When needing acknowledgement frame, Its frame format is as shown in table 6.
(3) security mechanism son field, length are 1.0 expression is not enabled, and 1 expression is enabled.
(4) son field is reserved, length is 3.According to the different and different of COS, when COS is in Client/ When under Server communication patterns, the 1st expression direction of action, 0 represents request, and 1 represents response;2 expressions type of action next, 00 temporarily reservation, 01 represents reading service, and 10 represent service of writing, and 11 expressions perform service.When COS is under response modes, move Make type to be consistent with corresponding claim frame type of action.When COS is other types, this 3 reservations.
The present invention devises six kinds of main communication services in APS layers, mainly including reading and writing, execution, report, report Confirm, issue six kinds of services, as shown in table 7.When a device node is wanted to perform another device node corresponding operation When, you can the mode operated to data object by using the data, services provided by data object is realizing.
Table 7:The six kinds of communication service of APS layers
As described in Table 7, the data object in device node provides reading and writing, execution, issues and report services, below will be right This several data, services describes in detail:
(1) read service
It is the service provided by data object in equipment to read service, represents that an equipment can pass through " reading " this service To obtain the property value in data object.Reading service includes read request and reads response, its identifier be request respectively with response。
request:For read request identifier, expression equipment need to obtain the property value of data object in another equipment and The request for sending.
response:For reading response identifier, expression equipment successfully read data object in another equipment Property value.
(2) write service
The service of writing is the service provided by data object in equipment, represents that equipment can be write by " writing " this service Enter corresponding value in data object attribute, using as its property value.The service write includes write request and write response, its identifier point It is not request and response.
request:For write request identifier, represent that equipment needs write is worth in the attribute of data object accordingly.
response:For write response identifier, expression equipment is successfully written corresponding value in the attribute of data object.
(3) perform service
The service of execution represents that coordinator can perform certain operation to the equipment in network, for example, make equipment perform dormancy etc. Operation.
(4) report services
Report services are the services provided by data object in equipment, represent equipment emergency case, unusual condition or During other situations, the method used by the acyclic information transmission actively initiated to the opposing party of communication.This service master It is used for the occasions such as acyclic data renewal.
(5) report confirmed service
Report confirmed service is when equipment occurs emergency case, unusual condition or active is initiated to a side in the case of other After information transmission, other side receives the service for returning confirmation after reporting to the police.
(6) issuing service
Issuing service is the service provided by data object in equipment, represents what the side in communicating can be received according to which From the information ordered by miscellaneous equipment, the method used by relevant information is issued.This service is mainly used in periodic number According to occasions such as renewals.
The present invention mainly supports following three kinds of communication patterns in the data communication services provided using sublayer, i.e., Client/SerVer communication patterns, Publisher/Subscriber communication patterns and Report/Sink communication patterns, below Described in detail respectively.
(1) client/server communication pattern (Client/SerVer)
Client/SerVer communication patterns are used for One-to-one communication.The communication used in the two-way communication of the sequence of operation Model.For certain parameter in object read and write or certain functional module in service execution operation be required for by APS The Client/SerVer communication patterns provided by layer are realized.The communication process of Client/SerVer communication patterns is as shown in Figure 3.
Based on the three kinds of services that have of Client/SerVer communication patterns, respectively reading and writing and service is performed.
1) Client/SerVer, under read request pattern, load format is as shown in Table 9:
Table 8:Client/SerVer communication pattern read request service load frame formats
1 byte 1 byte 1 byte
Attribute number Property ID Secondary attributes ID
(a) attribute digital section, 1 byte (maximum is 128, and highest order is invalid).
(b) attribute ID field, 1 byte.
(c) secondary attributes id field, 1 byte.
Secondary attributes ID are not typically used.Low 7 expression is taken in Property ID only, highest order is indicating bit.When highest order is 0 When, there are no secondary attributes in expression;When highest order is 1, represent that next byte is secondary attributes.(object is up to 128 attributes.If Property ID highest order is not 1 and the attribute has secondary attributes, all second-order is read in order directly Property value).
2) Client/SerVer, under write request pattern, load format is as shown in table 9:
Table 9:Client/SerVer communication pattern write request service load frame formats
1 byte 1 byte 1 byte 1 byte 1 byte
Attribute number Property ID Secondary attributes ID Property value length Property value
(a) attribute digital section, 1 byte (maximum is 128, and highest order is invalid).
(b) attribute ID field, 1 byte.
(c) secondary attributes id field, 1 byte.
(d) property value length field, 1 byte.
(e) attribute value field, the N number of byte determined by property value length.
3) Client/SerVer, performs under request mode, and load format is as shown in table 10:
Table 10:Client/SerVer communication patterns perform request service load frame format
1 byte 1 byte 1 byte 1 byte 1 byte
Method number Method ID Two stage approach ID Method length Method value
(a) method digital section, 1 byte (maximum is 128, and highest order is invalid).
(b) method id field, 1 byte.
(c) two stage approach id field, 1 byte.
The length field of (d) method |input paramete, 1 byte.
(e) parameter value field, the N number of byte determined by the length of parameter.
4) Client/SerVer, under response modes, load format is as shown in table 11:
Table 11:Client/SerVer communication pattern responsive load frame formats
1 byte 1 byte 1 byte 1 byte
Implementing result number Implementing result Perform output information length Perform output
(a) implementing result digital section, 1 byte.
(b) implementing result field, and 1 byte of each implementing result (low 7 expressions end value, when highest order is 1, table It is bright to have the concrete length field and codomain for performing output information below.
C () performs output information length field, 1 byte.
D () performs output specifying information field, with string representation.
(2) publish/subscribe communication pattern (Publish/Subscribe)
Issue in Publish/Subscribe communication patterns is a communication process, by the APS layers issued Object initialization, and received by the object subscribed in APS layers.Give out information the issuing service provided using APS layers.Issue communication Process is from publisher's object to subscription object.Any one object all can be used as publisher or subscriber.Pin Issue operation to object is required for the Publisher/Subscriber communication patterns provided by APS layers to realize. Publisher/Subscriber communication patterns are as shown in Figure 4.
Publish/Subscribe issuing service load formats are as shown in table 12.
Table 12:The issuing service of Publish/Subscribe communication patterns loads frame format
1 byte 1 byte 1 byte 1 byte 1 byte
Attribute number Property ID Secondary attributes ID Property value length Property value
(a) attribute digital section, 1 byte (maximum is 128, and highest order is invalid).
(b) attribute ID field, 1 byte.
(c) secondary attributes id field, 1 byte.
(d) property value length field, 1 byte.
(e) attribute value field, the N number of byte determined by property value length.
(3) report communication pattern (Report/Sink)
The characteristics of Report/Sink communication patterns are mainly used in the report services of equipment, this pattern be:Bottom is to sending Message queueing, is transmitted according to the size of priority, it is not necessary to message authentication, without stream or rate controlled or loss message inspection Survey.Report/Sink communication patterns are as shown in Figure 5.
Report/Sink reporting service load forms are as shown in table 13.
Table 13:Report/Sink communication pattern reporting service load frame formats
1 byte 1 byte 1 byte 1 byte 1 byte
Attribute number Property ID Secondary attributes ID Property value length Property value
(a) attribute digital section, 1 byte (maximum is 128, and highest order is invalid).
(b) attribute ID field, 1 byte.
(c) secondary attributes id field, 1 byte.
(d) property value length field, 1 byte.
(e) attribute value field, the N number of byte determined by property value length.
The present invention introduces shortcut mechanism in application layer, and realizes this mechanism under protocol stack state machine, below Design to this mechanism is described in detail.
During data transfer, the Frame for sending every time and returning all will carry whole information, in multi information In the case of transmission, this will cause the very big wasting of resources and temporal congestion.Therefore.The present invention devises a kind of quick Mode, more preferably, more easily to carry out the transmission of data and interact, carrys out energy efficient with this.In systems each is marked Quasi- object is required for defining standard attribute, a characteristic of an attribute characterization object.Each attribute has a corresponding attribute Identifier, to illustrate the attribute.
These attributes are provided simultaneously with determinant attribute and name attribute, and determinant attribute represents a unique object, and one Object often has many name attributes.The data type of attribute has:Constant, static state, dynamic and can not cache.Constant attributes are for being Attribute constant always in system operating process, such as device number, after device looses power is restarted, constant attributes keep constant;Static category Property be the attribute that will not change automatically, only system be subject to ectocine when, can just change, such as one warning generation; Dynamic attribute is the attribute of regular change, such as the process variable in industrial control process;Can not cache attribute for always The attribute of buffer area is not put into, to be addressed to this attribute, can only be obtained from the equipment for finally obtaining this object properties.Category The access type of property have it is read-only, only write or read and write.The attribute of each object is assigned to ground by specifying herein below Location:
(1) physical address of node;
(2) TLDE-SAP for communicating with the unique UPL layer processes comprising the object;
(3) unique object identifier in UPL layer processes;
(4) unique attribute-identifier.
The addressing of attribute is the type definition based on attribute.Attribute type includes:
(1) scalar;
(2) standard data structure;
(3) one-dimension array;
(4) two-dimensional array.
In the occasion for needing to transmit multiple attributes, if Frame uses Property ID, property variable type, attribute to become every time Amount length, the mode of property value have both wasted resource and have also increased transmission burden representing.Therefore, the present invention is in response frame Property ID, property variable type and property variable length is omitted, data are directly arranged.For example, read service frame need to only carry fast Mode ID, without carrying other any attribute informations.Increase a field domain in frame head portion, be named as " shortcut ID ", come Represent order ID.This method exchanges data packet number for memory space, when service command frequently or is periodically used, the life The complete content of order request can be omitted, it is only necessary to carry an order ID, and recipient stores the content representated by order ID, The result read service or perform service can directly be returned.
When shortcut pattern starts, before node obtains mutual information, side's node is firstly the need of one Shen of transmission Please shortcut ID frame to Correspondent Node, application shortcut ID frame format is as shown in table 14.
Table 14:Application shortcut ID frame format
1 byte 1 byte 1 byte 1 byte 1 byte
Frame is controlled Number of frames Service ID Source object ID Shortcut asks ID
When Correspondent Node receives application shortcut ID frame, one can be generated according to the corresponding object properties of node Shortcut ID, and requesting party is returned to, response frame form is as shown in Table 15.
Table 15:Response application shortcut ID frame format
When next opposite into the object properties of shortcut ID carry out read/write and service when, you can directly by accessing soon Prompt mode ID is realizing the access of data, not only time-consuming but also can improve transmitting efficiency well.
Between application shortcut ID and generation shortcut posterior nodal point, data interaction is as shown in Figure 6.When multiple nodes After attribute is numbered, when needing to read multiple property values, you can communicated using shortcut.Shortcut read request form is such as Shown in table 16.
Table 16:Shortcut read request frame format
1 byte 1 byte 1 byte 1 byte 1 byte
Frame is controlled Number of frames Service ID Source object ID Shortcut ID
It is as shown in table 17 that shortcut reads response format.
Table 17:Shortcut reads response frame form
1 byte 1 byte 1 byte 1 byte 1 byte N byte
Frame is controlled Number of frames Service ID Shortcut ID Destination object ID Property value
When needing to be read out access to multiple attributes, by sending shortcut request to the purpose pair for needing access As, you can realize the reading to multiple object respective attributes.Then only quick side need to be carried in frame head portion during response read request command Formulas I D, loads attribute data of the domain directly required for arrangement and returns to source object.
Shortcut write request form is as shown in table 18.
Table 18:Shortcut write request frame format
1 byte 1 byte 1 byte 1 byte 1 byte N byte
Frame is controlled Number of frames Service ID Source object ID Shortcut ID Property value
Shortcut write response form is as shown in table 19.
Table 19:Shortcut write response frame format
1 byte 1 byte 1 byte 1 byte 1 byte
Frame is controlled Number of frames Service ID Shortcut ID Source object ID
When multiple write request Frames are sent to purpose object, it would be desirable to which the Service Properties of writing of transmission are arranged in order.When Node receive with shortcut ID when writing service request, according to corresponding property value perform write service.Complete to write clothes After business, node is returned and responds to source object.
When certain order is performed a plurality of times, a table can be set up in node, record uses (reading and writing with perform service) Frequency, when certain order usage frequency is higher, you can directly using corresponding shortcut ID perform it is corresponding order behaviour Make.
The present invention increases object relation in application layer and sets up function, and can realize under protocol stack state machine mechanism this Relation sets up function, is described in detail the design to this mechanism below.
According to the opportunity for adding network, the foundation between equipment using relation is divided into two ways:
(1) Configuration Online mode:Configuration Online mode as shown in Figure 7, comprises the following steps that:
A) equipment constructs corresponding Frame after networking success, and actively sends out equipment of itself information (such as serial number) Give coordinator;
B) coordinator is saved it in coordinator after the facility information that the equipment of receiving sends, in all of section After point networks, coordinator starts to set the application relation between each equipment;
C) the application relation for setting is sent to associated equipment by coordinator, is received coordinator in equipment and is sent out The object relation sent just can be communicated with the equipment of opening relationships after setting up structure.
Wherein, equipment sends information to the command frame and coordinator of coordinator and is handed down to the command frame format of each equipment Respectively as shown in table 20, table 21.
Table 20:Configuration Online mode equipment sends facility information command frame format to coordinator
Table 21:Configuration Online mode coordinator sets up result command frame format to equipment sending object relation
(2) pre-configured mode:Mainly before the equipment for initiating communication networks, the parameter of target device is configured, i.e., in advance Application communication relation between set device.The labelling of equipment in network mainly by the way of equipment Serial Number, each equipment The fixed serial number of correspondence, and for the labelling of the application on equipment mainly adopts object ID mode.Using pre-configured side By following three kinds of modes, the equipment of formula, realizes that object relation is set up after networking success:
1) centralized inquiry mode, as shown in Figure 8:Centralized inquiry mode mainly make network in each equipment network Backward coordinator reports the facility information of oneself, and at this moment coordinator can be stored in the facility information for receiving in corresponding table, Then the equipment for initiating communication can inquire about the information of target device to coordinator,
A) equipment in a network before networking is pre-configured with the parameter of target device in source device;
B) facility information of itself is reported after the equipment networking success in network to coordinator, and constructs corresponding number According to frame, Frame is sent to into coordinator, in the table that the facility information for receiving is stored in by coordinator;
C) after all of equipment has all sent facility information, source device sends inquiry target device to coordinator Claim frame, the frame include pre-configured target device parameter, inquire about target device mainly by pre-configured serial number The information such as IP address.
Wherein, equipment sends facility information command frame format as shown in table 22 to coordinator, and equipment sends to coordinator and looks into Ask command frame format as shown in table 23.
Table 22:Equipment sends facility information command frame format to coordinator
Table 23:Equipment sends querying command frame format to coordinator
D) coordinator is after the querying command frame of the equipment that receives, according to the serial number carried in command frame, corresponding Whether have the target device of matching, finally, by the information of the target device of matching with the lattice of command frame if inquiring about in facility information table Formula is sent to the equipment for sending inquiry request.
E) source device just can carry out data interaction with which after the destination device address for receiving coordinator transmission.
The information frame format that coordinator is sent to target device is as shown in table 24.
Table 24:Coordinator sends target device information frame format to inquiry request equipment is sent
2) distributed query mode, as shown in Figure 9:
A) equipment in network before networking is pre-configured with the parameter of target device in source device;
B), after the equipment networking success in network, source device starts tectonic relationship and finds frame, and to other in network Equipment sends relation and finds frame, finds frame format as shown in Table 25, includes pre-configured target device parameter in the frame;
C), after the other equipment in network receives relation discovery frame, by checking target device parameter query oneself it is It is no to find serial number entrained in frame to search corresponding target device according to the relation for sending for target device, if Target device parameter is consistent with inherent parameters, then the equipment is target device.After target device is inquired, meet bar The target device of part will send response frame to source device, and wherein response command frame format is as shown in table 26.
D) source device just can carry out data interaction with which after receiving the response frame of target device.
Table 25:Initiate communication equipment frame format is found to the relation that surrounding devices send
Table 26:Target device is to the response frame form for initiating communication equipment transmission
3) fixed ip address mode:Equipment mainly directly to initiating communication carry out it is pre-configured, by by target device Serial number and IP address be preconfigured into the equipment for initiating communication, so as to realize the equipment for initiating communication directly and target device Communicated, and set up corresponding application layer object relation.
There are a kind of special circumstances in pre-configured mode, if pre-configured equipment Serial Number is 0, then it represents that target sets Standby is coordinator, and now, and node is without performing, and object relation foundation operation can directly to coordinator, (coordinator IP address be solid It is fixed) send application data.

Claims (9)

1. a kind of application of higher wireless sensor network layer data exchange method based on IPv6, it is characterised in that the wireless sensing In device network, the realization of data interaction is carried out by object approach, and the data wherein transmitted have unified data frame format;
Application layer framework is divided into UPL layers and APS layer two-layers by methods described, and UPL includes some user's application processes UAP, its profit The service provided with APS layers completes the communication between node device, and APS layers, as the interface between Internet and application layer, are UPL Layer and Internet provide service, include two entities of APSDE and APSME in APS layers, by the two entities to application and Lower floor provide service, APSDE provide data, services to Internet and application end so that between application program can at two or Transmit between multiple equipment;APSME provides management service, it is allowed to which application program is interacted with protocol stack;
The service that application sublayer APS is provided is respectively:Application layer equipment carries out reading under client/server communication pattern, Write, perform and report confirmation operation;Issue operation is carried out under publish/subscribe communication pattern;Carry out under report communication pattern Reporting operations;
User's application process and device management application process are carried out between object all based on the service provided using sublayer Communication;
Function ORE is set up in application layer design object relation, is realized by Configuration Online mode or pre-configured mode, wherein Pre-configured mode is divided into centralized inquiry mode, distributed query mode and fixed ip address mode again.
2. a kind of application of higher wireless sensor network layer data exchange method based on IPv6 according to claim 1, which is special Levy and be, the application layer equipment reads and writes operating process under client/server communication pattern can be using following quick side Formula mechanism, step are as follows:
A) source device is when needing frequently to read and write operation to the object properties of target device, execution step b);
B) source device applies for shortcut id command frame accordingly according to shortcut command frame format construction, and loads corresponding Shortcut is asked;
C) source device sends the application shortcut id command frame for having constructed to target device, and waits the sound of target device Should;
D) target device is judged when receiving from the application shortcut id command frame of source device, and is constructed corresponding Response command frame, loading relevant information, to respond the request of source device;
E) source device is when shortcut ID of target device return is received, subsequently with the data interaction of the equipment i.e. to the equipment Reading and writing operation can directly be completed by shortcut ID.
3. the application of higher wireless sensor network layer data exchange method based on IPv6 according to claim 1, its feature exist In, realized by Configuration Online mode object relation set up function key step it is as follows:
A) equipment constructs corresponding Frame after networking success, and equipment of itself information is sent to coordinator actively;
B) coordinator is saved it in coordinator after the facility information that the equipment of receiving sends, and is entered in all of node After net, coordinator starts to set the application relation between each equipment;
C) the application relation for setting is sent to corresponding equipment by coordinator, receives the right of coordinator transmission in equipment Set up as relation and just can be communicated with the equipment of opening relationships after result.
4. the application of higher wireless sensor network layer data exchange method based on IPv6 according to claim 1, its feature exist In, realized by pre-configured centralized inquiry mode object relation set up function key step it is as follows:
A) equipment in a network before networking is pre-configured with the parameter of target device in source device;
B) facility information of itself is reported to coordinator after the equipment networking success in network, and construct corresponding data Frame is sent to coordinator, in the table that the facility information for receiving is stored in by coordinator by frame;
C) after all of equipment has all sent facility information, source device sends inquiry target device request to coordinator Frame, the target device claim frame include pre-configured target device parameter;
D) the target device claim frame that coordinator is sent according to source device inquires about corresponding information table, and by the result of inquiry and Qualified destination device address is sent to source device with the form of response frame;
E) source device just can carry out data interaction with which after the destination device address for receiving coordinator transmission.
5. the application of higher wireless sensor network layer data exchange method based on IPv6 according to claim 1, its feature exist In, realized by pre-configured distributed query mode object relation set up function key step it is as follows:
A) equipment in network before networking is pre-configured with the parameter of target device in source device;
B), after the equipment networking success in network, source device starts tectonic relationship and finds frame, and to the other equipment in network Transmission relation finds frame, and the relation includes pre-configured target device parameter in finding frame;
Whether c) other equipment in network is received after relation finds frame, by checking target device parameter query oneself be Target device, if target device parameter is consistent with inherent parameters, then the equipment is target device, at this moment qualified Target device will send response frame to source device;
D) source device just can carry out data interaction with which after receiving the response frame of target device.
6. the application of higher wireless sensor network layer data exchange method based on IPv6 according to one of claim 1-5, its It is characterised by, the command frame format under three kinds of communication patterns is respectively:
A) command frame format under client/server communication pattern is as follows:
1 byte 1 byte 1 byte 1 byte 1 byte N byte Frame is controlled Number of frames Service ID Source object ID Purpose object ID Load
E) command frame format under publish/subscribe communication pattern is as follows:
1 byte 1 byte 1 byte 1 byte 1 byte N byte Frame is controlled Number of frames Service ID Source object ID Purpose object ID Load
F) report that the command frame format under communication pattern is as follows:
7. the application of higher wireless sensor network layer data exchange method based on IPv6 according to one of claim 1-5, its It is characterised by, the reading and writing, execution, report, the application layer data interaction frame load format difference of report confirmation and release operation It is:
A) the read request load frame format under client/server communication pattern is as follows:
1 byte 1 byte 1 byte Attribute number Property ID Secondary attributes ID
B) the write request load frame format under client/server communication pattern is as follows:
1 byte 1 byte 1 byte 1 byte 1 byte Attribute number Property ID Secondary attributes ID Property value length Property value
C) the execution request load frame format under client/server communication pattern is as follows:
1 byte 1 byte 1 byte 1 byte 1 byte Method number Method ID Two stage approach ID Method length Method value
D) the response command frame format under client/server communication pattern is as follows:
1 byte 1 byte 1 byte 1 byte Implementing result number Implementing result Perform output information length Perform output
E) the load frame format under publish/subscribe communication pattern is as follows:
1 byte 1 byte 1 byte 1 byte 1 byte Attribute number Property ID Secondary attributes ID Property value length Property value
F) report that the load frame format under communication pattern is as follows:
8. the arbitrary described application of higher wireless sensor network layer data exchange method based on IPv6 according to claim 2-5, Characterized in that, the command frame format of the application layer shortcut mechanism is:
A) application layer shortcut mechanism is as follows with regard to applying for shortcut id command frame format:
1 byte 1 byte 1 byte 1 byte 1 byte Frame is controlled Number of frames Service ID Source object ID Shortcut asks ID
B) application layer shortcut mechanism is as follows with regard to response application shortcut id command frame format:
C) application layer shortcut mechanism is as follows with regard to shortcut read request command frame format:
1 byte 1 byte 1 byte 1 byte 1 byte Frame is controlled Number of frames Service ID Source object ID Shortcut ID
D) application layer shortcut mechanism is as follows with regard to shortcut reading response command frame format:
1 byte 1 byte 1 byte 1 byte 1 byte N byte Frame is controlled Number of frames Service ID Shortcut ID Destination object ID Property value
E) application layer shortcut mechanism is as follows with regard to shortcut write request command frame format:
1 byte 1 byte 1 byte 1 byte 1 byte N byte Frame is controlled Number of frames Service ID Source object ID Shortcut ID Property value
F) application layer shortcut mechanism is as follows with regard to shortcut write response command frame format:
9. the arbitrary described application of higher wireless sensor network layer data exchange method based on IPv6 according to claim 1-5, Characterized in that, the command frame format that the object relation sets up function is:
A) object opening relationships function is as follows to coordinator transmission facility information command frame format with regard to Configuration Online mode equipment:
B) object opening relationships function sets up result command frame with regard to Configuration Online mode coordinator to equipment sending object relation Form is as follows:
C) object opening relationships function sends facility information command frame with regard to pre-configured centralized inquiry mode equipment to coordinator Form is as follows:
D) object opening relationships function sends querying command frame format with regard to pre-configured centralized inquiry mode equipment to coordinator It is as follows:
E) object opening relationships function sends mesh with regard to pre-configured centralized inquiry mode coordinator to inquiry request equipment is sent Marking device information frame format is as follows:
F) object opening relationships function initiates the pass that communication equipment is sent to surrounding devices with regard to pre-configured distributed query mode System finds that frame format is as follows:
G) sound that object opening relationships function is sent to initiation communication equipment with regard to pre-configured distributed query mode target device Answer frame format as follows:
CN201410036153.1A 2014-01-24 2014-01-24 Data interaction method for application layer of wireless sensor network based on IPv6 (internal protocol version 6) Active CN103731510B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410036153.1A CN103731510B (en) 2014-01-24 2014-01-24 Data interaction method for application layer of wireless sensor network based on IPv6 (internal protocol version 6)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410036153.1A CN103731510B (en) 2014-01-24 2014-01-24 Data interaction method for application layer of wireless sensor network based on IPv6 (internal protocol version 6)

Publications (2)

Publication Number Publication Date
CN103731510A CN103731510A (en) 2014-04-16
CN103731510B true CN103731510B (en) 2017-03-22

Family

ID=50455432

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410036153.1A Active CN103731510B (en) 2014-01-24 2014-01-24 Data interaction method for application layer of wireless sensor network based on IPv6 (internal protocol version 6)

Country Status (1)

Country Link
CN (1) CN103731510B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105916184B (en) * 2016-06-06 2019-05-31 西安航天自动化股份有限公司 A kind of industrial wireless sensing network termination implementation method meeting ISA100.11a standard
CN108183967B (en) * 2018-01-16 2020-08-04 重庆邮电大学 OPC UA (optical proximity correction) publishing/subscribing method suitable for IPv6 wireless sensor network
CN110737483B (en) * 2019-10-12 2023-02-24 重庆邮电大学 Signaling and data transmission method based on Windows USB MassStorage class

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2267978A1 (en) * 2009-01-13 2010-12-29 Metrologic Instruments, Inc. Wireless communication and sensor networks employing electronic-ink based display devices
CN102548030A (en) * 2010-12-08 2012-07-04 中国电信股份有限公司 Communication system, gateway and mobile terminal of ZigBee internet of things

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7852842B2 (en) * 2004-03-31 2010-12-14 Lg Electronics Inc. Data processing method for network layer

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2267978A1 (en) * 2009-01-13 2010-12-29 Metrologic Instruments, Inc. Wireless communication and sensor networks employing electronic-ink based display devices
CN102548030A (en) * 2010-12-08 2012-07-04 中国电信股份有限公司 Communication system, gateway and mobile terminal of ZigBee internet of things

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
ISA100.11a协议栈设计及数据链路层关键技术的研究与实现;王平;《中国优秀硕士学位论文全文数据库信息科技辑》;20111215;正文第10、14、21、23页 *

Also Published As

Publication number Publication date
CN103731510A (en) 2014-04-16

Similar Documents

Publication Publication Date Title
Colistra et al. The problem of task allocation in the Internet of Things and the consensus-based approach
KR101571376B1 (en) Method, group server, and member device for accessing member resources
EP1542409A1 (en) Protocol for multi-hop ad-hoc networks
Esposito et al. Event-based sensor data exchange and fusion in the Internet of Things environments
US20180063879A1 (en) Apparatus and method for interoperation between internet-of-things devices
EP3175602A2 (en) Server for device location registration in an internet of things (iot)
Kim et al. An MQTT-based context-aware autonomous system in oneM2M architecture
CN101459526B (en) Projector sharing conference system based on service discovery
KR100747551B1 (en) Sensor network topology management method using topology information table
JP4954328B2 (en) Method and system for data management in a communication network
CN103731510B (en) Data interaction method for application layer of wireless sensor network based on IPv6 (internal protocol version 6)
CN101330529B (en) Method for distributing address of self-pruning type tree-shaped structure network
CN103841183A (en) SMI-S Provider registration request method oriented to data center
KR102285352B1 (en) PROXY, METHOD FOR INTERWORKING BETWEEN HETEROGENEOUS IoT DEVICE AND IoT FLATFORM AND SYSTEM THE PROXY
Nguyen et al. Multiple peer chord rings approach for device discovery in IoT environment
Hayashi et al. Updated data dissemination methods for updating old replicas in ad hoc networks
US20230045914A1 (en) Method and apparatus for controlling device in internet of things, and gateway device and storage medium
US20090157878A1 (en) Method and system for connecting lower nodes to one another to increase scalability in zigbee network
Bhuvaneswari et al. Semantic web service discovery for mobile web services
CN111315037B (en) Communication link establishing method and device, computer equipment and storage medium
KR101673755B1 (en) System for interoperation network of IoT and network of Zigbee based DDS and Method thereof
Benchi et al. A P2P tuple space implementation for disconnected MANETs
JP3826735B2 (en) Service providing method by distributed system and equipment constituting distributed system
WO2020143013A1 (en) Method and apparatus for processing query request, computer device and storage medium
JP2006171917A (en) Protocol for radio multi-hop ad hoc network

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant