WO2012126208A1 - Method and system for wireless sensor network connecting to telecommunication network - Google Patents

Method and system for wireless sensor network connecting to telecommunication network Download PDF

Info

Publication number
WO2012126208A1
WO2012126208A1 PCT/CN2011/075974 CN2011075974W WO2012126208A1 WO 2012126208 A1 WO2012126208 A1 WO 2012126208A1 CN 2011075974 W CN2011075974 W CN 2011075974W WO 2012126208 A1 WO2012126208 A1 WO 2012126208A1
Authority
WO
WIPO (PCT)
Prior art keywords
gateway
wsn
primary
information
slave
Prior art date
Application number
PCT/CN2011/075974
Other languages
French (fr)
Chinese (zh)
Inventor
马景旺
Original Assignee
中兴通讯股份有限公司
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
Priority claimed from CN201110066941.1A external-priority patent/CN102685787B/en
Application filed by 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2012126208A1 publication Critical patent/WO2012126208A1/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W88/00Devices specially adapted for wireless communication networks, e.g. terminals, base stations or access point devices
    • H04W88/16Gateway arrangements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W84/00Network topologies
    • H04W84/18Self-organising networks, e.g. ad-hoc networks or sensor networks

Definitions

  • the present invention relates to an access technology in a combined network, and more particularly to a method and system for a wireless sensor network to access a telecommunications network. Background technique
  • wireless sensor networks are a new information acquisition and processing technology. Due to recent improvements in microfabrication technology, communication technology, and battery technology, tiny sensor terminals have the ability to sense, wirelessly communicate and process information. Such sensor terminals can not only sense and detect the target of the environment and its changes, but also process the collected data and send the processed data to the data collection center by wireless transmission.
  • These sensor terminals typically consist of a power supply, sensing components, an embedded processor, memory, communication components, and execution software. Among them, the power supply provides the sensor node with the energy necessary for normal operation.
  • the sensing component is used to sense, acquire, and convert external information into digital signals.
  • the embedded processor is responsible for coordinating the work of various parts of the node, such as performing necessary processing, saving, and controlling the operating mode of the sensing component and the power supply.
  • the communication component is responsible for communicating with other sensors or observers.
  • Execution software provides the necessary software support for sensor terminals, such as embedded operating systems, embedded database systems, and more. Detecting thermal, infrared, sonar, radar and seismic signals in the surrounding environment of the sensor terminal by means of a variety of sensing components built into the sensor terminal, thereby detecting temperature, humidity, noise, light intensity, pressure, soil composition , a lot of information such as the size, speed and direction of moving objects. Sensor terminals typically form a network in a self-organizing or pre-configured manner.
  • wireless sensor networks In terms of communication methods, although wired, wireless, infrared, and optical formats can be used, it is generally considered that short-range wireless low-power communication technology is most suitable for the use of sensor networks, generally called wireless sensor networks. ( WSN, Wireless Sensor Network )
  • WSN Wireless Sensor Network
  • the current widely used wireless low-power communication technologies include: IEEE, Institute of Electrical and Electronics Engineers 802.15.4 and Zigbee technology.
  • IEEE 802.15.4 is a low-speed wireless personal area network (WPAN) standard developed by IEEE. IEEE 802.15.4 specifies the physical layer and medium access control layer (MAC, Media Access Control) standards. The IEEE 802.15.4 compliant communication module features low cost, low power consumption, and small size.
  • WPAN wireless personal area network
  • IEEE 802.15.4 specifies the physical layer and medium access control layer (MAC, Media Access Control) standards.
  • MAC medium access control layer
  • the IEEE 802.15.4 compliant communication module features low cost, low power consumption, and small size.
  • the Zigbee Alliance is an organization dedicated to developing reliable, low-cost, low-power, wireless network connectivity monitoring and control products based on open global standards.
  • the Zigbee standard physical layer and MAC layer use IEEE 802.15.4 technology, and the network layer, security management, application layer specifications, and interoperability are developed by the Zigbee Alliance.
  • the Zigbee smart energy public applications profile and the Zigbee home automation public applications profile in the Zigbee standard are for business environment applications and home applications.
  • the WSN terminal's micro-processing capabilities and wireless communication capabilities make wireless sensor networks a promising application for military applications, biological and environmental monitoring, health applications, home applications, industrial control and monitoring.
  • wireless sensor networks and telecommunication networks such as second generation (2G, 2nd Generation) mobile communication, third generation (3G, 3rd Generation) mobile communication, xDSL (x Digital Subscriber Line), FTTx (Fiber To The x, x is Home, building, node, premises), wireless access, satellite/microwave, etc.
  • second generation (2G, 2nd Generation) mobile communication 3G, 3rd Generation mobile communication
  • xDSL x Digital Subscriber Line
  • FTTx Wireless To The x, x is Home, building, node, premises
  • wireless access satellite/microwave, etc.
  • wireless sensor networks can effectively transmit the data perceived by the wireless sensor network to the data center. By sorting and analyzing the data, the way of acquiring data of the natural world can be greatly changed.
  • Wireless sensor network The centralized management of the network solves the problem that the wireless sensor networks that are currently scattered everywhere are difficult to manage.
  • the combination of a wireless sensor network and a telecommunication network refers to connecting a wireless sensor network with a telecommunication network, and utilizing the telecommunication network to monitor, manage, and complete the service carrying and cooperation of the wireless sensor network and the services provided by the telecommunication network, and expand the telecom network.
  • the services provided by wireless sensor networks is generally a wireless sensor network connected to a telecommunications network platform through a gateway device.
  • the WSN terminal is a sensor node constituting the WSN and is connected to the gateway by one or more hops.
  • the WSN terminal is responsible for collecting and uploading data, as well as receiving and executing commands.
  • the WSN terminals that make up the WSN are as few as a few hundreds, and WSN terminals can be networked in a star, tree or mesh manner, some of which have strong groups. Network and data forwarding capabilities.
  • the gateway is responsible for transmitting the data reported by the WSN terminal to the relevant network unit in the telecommunication network, and the relevant network unit in the telecommunication network sends the relevant command to the WSN terminal through the gateway.
  • the gateway is generally responsible for creating the WSN, which is responsible for the management of the WSN terminal when joining and leaving the sensor network, and the configuration information of the WSN terminal and the sensor network are stored in the gateway. Important data such as business configuration information.
  • the data reported by the WSN terminal needs to be sent to the relevant network unit in the telecommunication network through the gateway, and the existing WSN usually only configures one gateway for forwarding the data reported by the WSN terminal to the relevant network unit in the telecommunication network, so that
  • the gateway load in the WSN is so large that the data of the WSN terminal cannot be sent in time and the communication between the WSN terminal and the gateway is congested. This will seriously affect the normal operation of the WSN.
  • the network unit on the telecommunication network side when the network unit on the telecommunication network side performs management of the WSN terminal in the wireless sensor network, it is required to establish communication with the WSN terminal through the gateway of the wireless sensor network; if the gateway unit on the telecommunication network side only passes through one gateway and the wireless sensor network The WSN terminal in the establishment of communication will also cause a relatively large load on the gateway. The force causes the gateway unit on the telecommunication network side to fail to establish communication with the WSN terminal in the wireless sensor network in time, which affects the normal operation of related services. Therefore, it is necessary to consider how the relevant network element on the telecommunication network side performs more smooth communication with the WSN terminal in the wireless sensor network through the WSN gateway. For this problem, a feasible solution is to configure multiple gateways in the wireless sensor network.
  • the WSN terminals in the wireless sensors communicate with the WSN terminals through the gateways and the network elements on the telecommunication network side through these gateways.
  • the multiple gateways configured in the wireless sensor network can use the master-slave gateway working mode, with one gateway as the primary gateway and the remaining gateways as the slave gateways; the primary gateway is responsible for creating the creation and management of the wireless sensor network, and the primary gateway is assigned to the WSN terminal.
  • the allocated gateway may be the primary gateway, or may be one of the secondary gateways, and the WSN terminal accesses the telecommunication network through the allocated gateway, and the secondary gateway is the WSN terminal according to the scheduling of the primary gateway.
  • the primary gateway plays an important role in the normal operation of the wireless sensor network. If the primary gateway is in a faulty situation and causes it to malfunction, the wireless sensor network and related services will not operate normally. A corresponding solution is needed. When the primary gateway fails, the relevant methods are used to make the wireless sensor network and its Related business can work normally. There is currently no corresponding solution to this problem. Summary of the invention
  • the main object of the present invention is to provide a method and system for a wireless sensor network to access a telecommunications network, which can timely confirm a new primary gateway when the primary gateway fails without affecting communication between the WSN and the telecommunications network.
  • a method for a wireless sensor network to access a telecommunication network wherein the WSN is provided with a WSN terminal and two or more WSN gateways, and the two or more WSN gateways are provided with a main gateway; the telecommunication network is provided with management Platform; the method further includes:
  • one of the WSNs is used as a primary network from the gateway. Off, instead of working with the original primary gateway.
  • the one of the WSNs is used as a primary gateway instead of the original primary gateway, and is:
  • the slave gateway replacing the original primary gateway is designated by the management platform, and the slave gateway works in place of the original master gateway.
  • the management platform specifies a slave gateway that replaces the original primary gateway, and is:
  • the slave gateway of the replacement primary gateway in the WSN is further determined, and the determined secondary gateway is notified as the primary gateway to work instead of the original primary gateway.
  • the one of the WSNs is used as a primary gateway instead of the original primary gateway, and is:
  • the slave gateway in the WSN negotiates to determine a new master gateway to work in place of the original master gateway.
  • the one of the WSNs is used as a primary gateway instead of the original primary gateway, and is:
  • the gateway or the management platform notifies the failure gateway of the primary gateway to the backup gateway with the highest priority of the backup gateway, and the backup gateway with the highest priority replaces the original primary gateway.
  • the method further includes:
  • the management platform stores backup information of the primary gateway
  • the management platform sends the stored backup information of the master gateway to the slave gateway replacing the original master gateway, and the slave gateway replacing the original master gateway uses the backup information of the original master gateway to work in the WSN.
  • the method further includes: After the gateway replaces the original primary gateway, a broadcast message is sent in the WSN, and the information of the new primary gateway is notified to the WSN terminal and the remaining slave gateways of the WSN.
  • the management platform stores backup information of the primary gateway and the secondary gateway;
  • the backup information of the primary gateway includes configuration information of the WSN, correspondence information between the WSN terminal and the gateway allocated for the WSN terminal;
  • the configuration information of the WSN includes the identifier of the WSN, the network topology information, the slave gateway information, the information of the WSN terminal, and the network security setting information.
  • the backup information of the slave gateway includes the gateway information, and the WSN of the telecommunication network accessed through the slave gateway.
  • the method further includes:
  • the new primary gateway determines, according to the correspondence information between the obtained WSN terminal and the gateway allocated for the WSN terminal, that the WSN terminal accessing the telecommunication network through the original primary gateway exists for the WSN terminal accessing the telecommunication network through the original primary gateway. Assign a gateway to the telecommunications network.
  • a system for accessing a telecommunication network by a wireless sensor network wherein the WSN is provided with a WSN terminal and two or more WSN gateways, and the two or more WSN gateways are provided with a main gateway; the telecommunication network is provided with management a platform; the system includes a determining unit and a replacing unit, wherein
  • a determining unit configured to: when the primary gateway is not working properly, trigger a replacement unit; and the replacing unit is configured to use one of the WSNs as a primary gateway instead of the original primary gateway to work.
  • the determining unit is disposed in the management platform, after determining that the primary gateway in the WSN is not working normally, further determining a secondary gateway of the replacement primary gateway in the WSN, and notifying by the proxy unit
  • the slave gateway acts as the master gateway, replacing the original master gateway.
  • the replacing unit is disposed in the slave gateway; after the determining unit determines that the master gateway in the WSN is unable to work normally, the replacing unit further determines through the slave gateway in the WSN.
  • a new master gateway is used instead of the original master gateway.
  • the system further includes a setting unit and a sending unit, where
  • a setting unit configured to determine a backup gateway of the primary gateway in the WSN in advance, and set a priority for the backup gateway
  • a sending unit configured to send information about the priority of the backup gateway to each slave gateway and the management platform
  • the replacement unit is disposed in a slave gateway or a management platform
  • the replacing unit is further configured to notify the backup gateway with the highest priority of the backup gateway as the fault information of the primary gateway, and replace the original primary gateway with the backup gateway with the highest priority. jobs.
  • the management platform stores backup information of the primary gateway
  • the management platform sends the stored backup information of the primary gateway to the secondary gateway replacing the original primary gateway, and the secondary gateway replacing the original primary gateway uses the backup information of the original primary gateway in the WSN. working.
  • the system further includes a broadcast unit, configured to send a broadcast message in the WSN after the substitute unit replaces the original primary gateway, and notify the WSN terminal and the remaining slave gateways of the WSN of the information of the new primary gateway. .
  • a broadcast unit configured to send a broadcast message in the WSN after the substitute unit replaces the original primary gateway, and notify the WSN terminal and the remaining slave gateways of the WSN of the information of the new primary gateway.
  • multiple gateways are configured in one WSN, and multiple gateways use a master-slave working mode, and the multiple gateways respectively provide access to the telecommunication network for the WSN terminal in the WSN, and cannot be normal when the primary gateway fails.
  • the master gateway can be replaced by one of the slave gateways, and the slave gateway works instead of the original master gateway, so that the wireless sensor network and related services can operate normally, thereby improving the reliability of the wireless sensor network configuring multiple gateways.
  • FIG. 1 is a schematic diagram of a network architecture when multiple gateways exist in a WSN
  • 2 is a flowchart of configuring a multi-gateway for a WSN according to Embodiment 1 of the present invention
  • 3 is a flow chart of allocating a gateway to a WSN terminal when the WSN terminal joins the WSN and uses the working mode of the master-slave gateway according to the second embodiment of the present invention
  • FIG. 4 is a flowchart of a slave gateway replacing a master gateway in a WSN according to Embodiment 3 of the present invention
  • FIG. 5 is a flowchart of a slave gateway replacing a master gateway in a WSN according to Embodiment 4 of the present invention
  • FIG. 6 is a wireless sensor network according to the present invention. Schematic diagram of the structure of a system for accessing a telecommunications network. detailed description
  • the basic idea of the present invention is: in a wireless sensor network configured with multiple gateways and using a master-slave gateway working mode, when the primary gateway fails to work normally, it is determined that one slave gateway in the wireless sensor network replaces the master gateway, The determined slave gateway acts as a new master gateway in the wireless sensor network, thereby improving the communication reliability of the wireless sensor network.
  • communication is performed in a master-slave gateway working mode, wherein one gateway is set as the primary gateway, and the remaining gateways are slave gateways.
  • the primary gateway determines the gateway used by the WSN terminal in the WSN to access the telecommunication network, and the WSN terminal accesses the telecommunication network through the gateway designated by the primary gateway. It should be noted that the designated gateway may be the primary gateway itself or one of the secondary gateways.
  • the telecommunications network access is provided from the WSN terminal designated by the gateway (including the main gateway itself) as the primary gateway.
  • the primary gateway is responsible for the creation of the WSN, and the gateway is added to the WSN as a routing node in the WSN.
  • the management platform records related information of the slave gateway, including at least the identifier of the gateway, the address of the slave gateway in the telecommunication network, and the like, and is notified by the management platform.
  • the primary gateway in the WSN has a new slave gateway joining the WSN.
  • the master gateway records the information of the slave gateway.
  • the information of the slave gateway may include: an address from the gateway in the WSN, an address of the slave gateway in the telecommunication network, and a telecommunication network access that the slave gateway can provide.
  • the primary gateway only needs to record the address.
  • the communication between the primary gateway and the secondary gateway can be carried out through the WSN or through the telecommunications network.
  • the primary gateway allocates the gateway used by the access telecommunication network to the WSN terminal according to the relevant rules assigned by the gateway, and the allocated gateway may be the primary gateway or the secondary gateway.
  • the primary gateway can determine the gateway used by the WSN node to access the telecommunication network according to the topology of the network, the load balancing between the gateways, and the length of the route from the WSN node to the gateway, such as preferentially assigning WSN terminals to the WSN terminal.
  • the gateway of the same domain is used as a gateway for accessing the telecommunication network, or the WSN terminal is preferentially assigned a gateway with a lighter current load, or the WSN terminal is preferentially allocated to a gateway whose access to the telecommunication network is not greater than a set threshold;
  • the WSN terminal can be allocated a gateway for accessing the telecommunication network by referring to the above-mentioned gateway allocation rule.
  • the primary gateway When the gateway is allocated, the primary gateway provides the information of the assigned gateway (such as the address of the gateway in the WSN) to the WSN terminal, and the WSN terminal saves the information of the assigned gateway and creates routing information to the gateway;
  • the information of the WSN terminal (including the identifier of the WSN terminal, the address of the WSN terminal in the WSN) is provided to the assigned gateway, and the assigned gateway records the information of the WSN terminal.
  • the primary gateway saves the correspondence between the WSN terminal in the WSN and its assigned gateway, and sends the information of the corresponding relationship to the management platform of the telecommunication network, and the management platform saves the information of the corresponding relationship.
  • the correspondence may be implemented in the form of a correspondence table in which the identifier of the WSN terminal and the identity of the gateway to which it is assigned are recorded.
  • the corresponding relationship can be used to query the gateway used by a certain WSN terminal to access the telecommunication network, and a gateway in the WSN provides telecommunication network access for which WSN terminals in the WSN.
  • the primary gateway can change the gateway used by the WSN terminal to access the telecommunication network.
  • the newly designated gateway of the primary gateway provides the TSN terminal with telecommunication network access, and the original gateway no longer provides telecommunication network access for the WSN terminal.
  • the primary gateway and the WSN terminal access the telecommunication network.
  • the gateway can clear the information of the WSN terminal saved by the WSN terminal, and the gateway corresponding to the WSN terminal does not provide the TSN terminal with the telecommunication network access after the WSN terminal leaves the WSN.
  • the management platform may write the network configuration parameters required for joining the WSN in the WSN terminal through the client or other manner, and the network configuration parameter may be used by the management platform from the WSN terminal to join the primary gateway in the WSN. Obtained.
  • the WSN terminal joins the WSN, it submits a request to join the WSN to the primary gateway, where the request includes information such as the identifier of the WSN terminal, and the primary gateway can send the information of the WSN terminal to the management platform.
  • the WSN terminal is authenticated by the primary gateway or the management platform, and the WSN terminal is allowed to join the WSN after the verification is passed, and the WSN terminal is allocated by the primary gateway to the gateway used for accessing the telecommunication network.
  • the management platform in the telecommunication network stores the correspondence between the WSN terminal in the WSN and its assigned gateway. If a network element (such as a service platform) in the telecommunication network is ready to establish communication with the WSN terminal in the WSN, the network element in the telecommunication network can obtain information (such as a gateway) of the gateway used by the WSN terminal to access the telecommunication network from the management platform. Address information, identification information, etc.), and then communicate with the WSN terminal through the gateway.
  • information such as a gateway
  • configuration information or other information of the wireless sensor network in the primary gateway and the secondary gateway can be backed up and stored on the management platform.
  • the primary and secondary gateways can send data that needs to be backed up to the management platform and stored by the management platform.
  • the backup data of the primary gateway includes, but is not limited to, configuration information of the wireless sensor network, correspondence information between the WSN terminal and its assigned gateway; configuration information of the wireless sensor network includes the identifier of the wireless sensor network, and the network. Topological information, information from the gateway and the WSN terminal (including information such as identification, address, etc.), network security setting information, etc.; correspondence information between the WSN terminal and its assigned gateway is used to record the WSN terminal access to the telecommunications network. Gateway.
  • the backup data of the slave gateway includes but is not limited to: the identity and address of the slave gateway, the information of the WSN terminal of the telecommunications network accessed through the slave gateway, and the like.
  • the primary gateway may fail, and the primary gateway may not work properly. Since the main gateway plays an important role, it assumes the function of wireless sensor network management. When the main gateway fails to work normally, it needs to take necessary measures to make up for it.
  • the secondary gateway when the primary gateway is not functioning properly, the secondary gateway is replaced by a secondary gateway in the wireless sensor network, and the secondary gateway operates as a primary gateway in the wireless sensor network.
  • the slave gateway that replaces the master gateway can be specified by the management platform. After the management platform determines that the primary gateway is not working properly, it determines the secondary gateway of the replacement primary gateway in the wireless sensor network, and notifies the secondary gateway to operate as the primary gateway in the wireless sensor network.
  • the management platform can obtain the fault information of the primary gateway in time and take relevant measures.
  • the management platform can determine whether the primary gateway can work normally by the following methods:
  • the primary gateway fails but can still communicate with the management platform of the telecommunication network, the primary gateway notifies the management platform of the fault information;
  • the management platform periodically checks the gateway of the wireless sensor network, and detects that the primary gateway is faulty;
  • the gateway detects that the primary gateway is faulty, and notifies the management platform of the fault information
  • the WSN terminal detects that the primary gateway has failed, and notifies the fault information (such as notification from the gateway through its own access) management platform.
  • a slave gateway may be selected from the multiple slave gateways of the wireless sensor network, and the slave gateway replaces the master gateway, and the slave gateway acts as a new master gateway in the wireless Work in the sensor network.
  • a new primary gateway may also be negotiated by the secondary gateway.
  • the primary gateway may preset the backup gateway priority of the secondary gateway in the wireless sensor, and send the information of the backup gateway priority of each slave gateway to each slave gateway and the management platform.
  • the fault information of the primary gateway is notified to the secondary gateway with the highest priority of the backup gateway, and the secondary gateway with the highest priority of the backup gateway replaces the current active gateway that cannot work normally.
  • the slave gateway In order to realize that the slave gateway functions as a new master gateway in the wireless sensor network, the slave gateway needs to obtain and use configuration information of the wireless sensor network, correspondence information between the WSN terminal and its assigned gateway, and the like. The information is backed up by the original master gateway on the management platform, and the backup information of the master gateway can be provided by the management platform to the slave gateway, and the slave gateway works as a new master gateway in the wireless sensor network using the backup information.
  • the secondary gateway After the gateway replaces the original primary gateway, the secondary gateway sends a broadcast message in the wireless sensor network, and notifies the WSN terminal and other secondary gateways of the change of the primary gateway.
  • the new primary gateway determines, according to the correspondence information between the obtained WSN terminal and its assigned gateway, whether there is a WSN terminal accessing the telecommunication network through the original primary gateway; if yes, the new primary gateway reassigns the WSN terminal The WSN terminal that enters the gateway used by the telecommunication network accesses the telecommunication network through the newly assigned gateway.
  • multiple gateways are configured in the WSN, and multiple gateways use the master-slave working mode, and multiple gateways respectively provide access to the telecommunication network for the WSN terminal in the WSN, and when the primary gateway fails
  • the master gateway can be replaced by one of the slave gateways, and the slave gateway acts as a master gateway in the wireless sensor network, so that the wireless sensor network and related services can operate normally, and the configuration is improved. The reliability of the gateway's wireless sensor network.
  • the WSN of the present invention is a wireless network composed of a group of wireless sensor node devices, such as WSN terminals, in an ad hoc manner or a pre-configured manner; WSN terminals communicate by short-range wireless communication technology.
  • WSNs are typically deployed in areas ranging from a few meters to a few hundred meters, where WSN terminals are typically battery powered, with lower power and cost.
  • Near field communication technology generally uses Zigbee and IEEE 802.15.4 technology.
  • the combination of WSN and telecommunication network refers to connecting WSN with telecommunication network and utilizing telecommunication network.
  • the network monitors, manages and completes the service bearer and cooperation implementation of the WSN and the services it provides, and extends the services provided by the WSN through the telecommunication network.
  • the telecommunication network includes various communication networks such as mobile communication networks, xDSL, FTTx, and satellite communications.
  • FIG. 1 is a schematic diagram of a network architecture when multiple gateways exist in the WSN.
  • the shaded portions filled with cross lines indicate multiple WSN terminals.
  • the shaded portion filled with dots indicates the area where multiple WSN terminals are located.
  • the WSN is composed of multiple WSN terminals and multiple gateways. Multiple WSN terminals and multiple gateways can be used to set up wireless sensor networks according to the relevant technical standards of WSN.
  • the short-range communication technologies that can be used to form WSNs include Zigbee technology and IEEE. 802.15.4 standard, etc.
  • the WSN connects to the telecommunication network through multiple gateways, and establishes communication with the management platform in the telecommunication network. Among them, the working mode of the master-slave gateway is used between multiple gateways.
  • the WSN accesses the telecommunication network through multiple gateways, and is connected to the access network, the core network, the service platform, and the management platform via the telecommunication network.
  • the WSN terminal is connected to the telecommunications network through a plurality of gateways.
  • the WSN terminal is a sensor node constituting the WSN and is connected to the gateway by one or more hops.
  • the WSN terminal is responsible for collecting and uploading data, as well as receiving and executing commands.
  • the WSN terminals that make up the WSN are as few as a few hundreds, and the WSN terminals can be networked in a star, tree or mesh manner, some of which have strong groups. Network and data forwarding capabilities.
  • the gateway is responsible for connecting the WSN and the telecommunication network, and mainly performs functions such as protocol conversion, address mapping, and data forwarding, and can also integrate functions such as security and billing.
  • the functions supported by the gateway can include: Support internal data coordination and aggregation in the sensor network; Support second-generation (2G, 2nd Generation) mobile communication, third-generation (3G, 3rd Generation) mobile communication, xDSL, FTTx, broadband wireless access And one or more of long-distance communication access methods such as satellite/microwave, transmitting aggregated data to the communication peer; supporting service platform and remote management server to device authentication and user authentication of the gateway; supporting service platform and remote management Server-to-gateway parameters and software configuration; support User authentication and business security, device management security mechanisms.
  • the service platform is a functional entity that operates and manages the services combined with the WSN in the telecommunication network. It is responsible for integrating the services provided by the various service providers and providing them to the end users, and managing the use of the services by the terminal users.
  • the service platform cooperates with other functional entities in the telecommunication network to complete the entire business process according to the needs of different services, such as AAA, Authentication Authorization and Accounting (AAA).
  • AAA Authentication Authorization and Accounting
  • the business platform can also be connected to a remote server to update the business directly.
  • the management platform is an entity that implements management functions for the WSN.
  • the management platform can be composed of a management server that implements management functions for the WSN through the telecommunication network.
  • a WSN is first created by a gateway in a plurality of gateways. After the WSN is created, the gateway sends the information of the WSN (such as the network identifier of the WSN) to the management platform, and the management platform saves the WSN and the gateway. information.
  • the gateway having the WSN capability is the master gateway, and the other gateways are the slave gateways. This example is for the scenario where the WSN is initially established, that is, the primary gateway is responsible for the rest of the access from the gateway. It should be noted that, after the WSN is established, when a new gateway is added, the manner of updating the newly added gateway is basically the same as the new gateway joining manner described in this example, and the implementation details are not repeatedly described in the present invention.
  • FIG. 2 is a flowchart of configuring a multi-gateway for a WSN according to Embodiment 1 of the present invention. As shown in FIG. 2, the process of configuring a multi-gateway by the WSN of the present invention specifically includes the following steps:
  • Step 201 Other gateways (ie, other gateways other than the primary gateway, also called new gateways) are connected to the management platform through the communication provided by the telecommunication network, and are registered.
  • Other gateways ie, other gateways other than the primary gateway, also called new gateways
  • the new gateway can establish a communication connection with the management platform through the telecommunication network, and send a registration request to the management platform.
  • Management platform can pass new
  • the identity of the gateway is authenticated to determine the authenticity of the new gateway identity.
  • the information of the new gateway is pre-stored in the management platform, and the information includes the network access capability parameter of the new gateway, the location of the installation, and the like.
  • Step 202 The management platform notifies the primary gateway in the WSN that a new gateway applies to join the WSN.
  • the management platform determines the WSN that the new gateway is ready to join according to the location where the new gateway is to be installed, and then notifies the primary gateway in the WSN that a new gateway applies to join the WSN.
  • the management platform can simultaneously send the information of the new gateway to the primary gateway.
  • the information of the new gateway may include: an address of the new gateway in the telecommunication network, a network access capability parameter, and the like.
  • Step 203 The primary gateway sends the network configuration parameters required to join the WSN to the registered new gateway.
  • the primary gateway adds the network configuration parameters required by the new gateway to the WSN to the management platform, and then the management platform sends the network configuration parameters and the address of the primary gateway in the telecommunication network to the new gateway.
  • the network configuration parameters here include the address of the primary gateway in the WSN, the initial master key, and so on.
  • Step 204 The new gateway joins the WSN by using the obtained network configuration parameters.
  • the new gateway after obtaining the network configuration parameter of the WSN, the new gateway performs channel scanning in the coverage area of the WSN, and then sends an association request (Association Request) frame to the primary gateway, requesting to join the WSN.
  • the new gateway and the primary gateway negotiate based on the initial master key to determine the network key, link key, and address.
  • the new gateway records its own address and related routing information in the WSN, and the primary gateway records the address of the new gateway in the WSN and the information of the new gateway.
  • the gateway can communicate and exchange related data through the WSN.
  • the address of the gateway in the telecommunication network can use the IP address. Since the gateway stores the IP address of the opposite party in the telecommunication network, the two parties can also communicate through the telecommunication network.
  • multiple gateways can be configured in the WSN.
  • the WSN terminal in order to enable the WSN terminal to join the WSN, the WSN terminal needs to obtain the network configuration parameters required to join the WSN from the management platform.
  • the network configuration parameters include: the initial master key of the WSN to be joined and the address of the primary gateway.
  • the primary gateway verifies the authenticity of the initial master key of the WSN terminal, thereby verifying the identity of the WSN terminal. If the initial master key of the WSN terminal is correct, the WSN terminal is allowed to join the WSN, and the WSN terminal and the primary gateway can negotiate based on the initial master key to determine the link key and network secret required to join the WSN.
  • the primary gateway rejects the WSN terminal to join the WSN because the initial master key cannot be provided or the initial master key is not the correct key.
  • the WSN terminal manufacturer produces the WSN terminal
  • the network configuration parameter of the WSN is not written in the WSN terminal
  • the WSN terminal can write the WSN terminal through the client or other means before the WSN terminal is put into use.
  • the management platform can obtain the network configuration parameters required to join the WSN from the primary gateway.
  • the management platform can obtain the network configuration parameters of the WSN in two ways.
  • the first mode is: the management platform sends a request for acquiring the WSN network configuration parameter to the primary gateway, and the primary gateway provides the network configuration parameter required by the WSN terminal to join the WSN.
  • the second way is as follows: After the WSN is created, the primary gateway will add the network configuration parameters required by the WSN to the management platform and save it on the management platform.
  • the second embodiment of the present invention describes a process of allocating a gateway for the WSN terminal when the WSN terminal joins the WSN and uses the working mode of the master and slave gateways in the WSN formed by the Zigbee technology.
  • FIG. 3 is a flowchart of allocating a gateway to a WSN terminal when the WSN terminal joins the WSN and uses the working mode of the master-slave gateway according to the second embodiment of the present invention.
  • the step of allocating the gateway for the WSN terminal includes the following steps: Step 301: Write, in the WSN terminal, a network configuration parameter of the WSN to which the WSN terminal applies for joining.
  • Step 302 The WSN terminal applies to the WSN by using the network configuration parameter of the WSN, and the primary gateway verifies the WSN terminal. If the verification succeeds, step 303 is performed; if the verification fails, step 304 is performed.
  • the WSN terminal is placed in the area covered by the WSN to be joined.
  • the WSN terminal can perform network scanning on the set channel to determine the WSN to be added.
  • the network scan can send a Beacon Request frame on the channel.
  • the device in the WSN on the channel receives the Beacon Request, if a new WSN terminal is allowed to join the WSN, it will respond to the Beacon frame.
  • the Beacon frame contains the address information of the WSN terminal that sent the frame, and whether other WSN terminals are allowed to join in the manner of their child nodes.
  • the WSN terminal saves the information of the received Beacon frame in its own neighbor table.
  • the WSN terminal selects an appropriate parent node in the association table, and sends an Association Request frame request to the parent node to join the WSN.
  • the WSN terminal at the parent node of the WSN notifies the WSN of the primary gateway that a new WSN terminal requests to join the WSN.
  • the WSN's primary gateway authenticates the WSN terminal.
  • the authentication mode can be based on the way the node device joins the network in the Zigbee specification.
  • the primary gateway determines the authenticity of the initial master key in the WSN terminal. If the WSN terminal passes the verification, the operation of step 303 is performed; if the WSN terminal fails to verify, the operation of step 304 is performed.
  • Step 303 After the WSN terminal passes the verification, the communication protocol negotiates with the primary gateway to determine the link key and the network key, and the primary gateway adds the information of the WSN terminal in the node management table, and the parent node device of the WSN terminal is in its neighbor table. The information of the WSN terminal is saved, and the WSN terminal saves the information of the parent node and the master gateway in its own neighbor table. At this point, the WSN terminal successfully joined WSN.
  • Step 304 The WSN terminal fails to pass the authentication, and the primary gateway rejects the WSN terminal to join the WSN.
  • the communication connection configuration information is a link key required for establishing a communication connection between the designated gateway and the WSN terminal, and the designated gateway establishes a secure communication connection with the WSN terminal through the link key.
  • Step 306 The master gateway of the WSN notifies the management platform that the WSN terminal has joined the WSN, and sends the correspondence between the WSN terminal and its assigned gateway to the management platform.
  • the management platform saves related information of the WSN terminal, including the identifier of the WSN terminal, the correspondence between the WSN terminal and the WSN to which the WSN terminal belongs, and the correspondence between the WSN terminal and the gateway to which it is assigned.
  • the management platform also associates the WSN terminal.
  • the information is sent to the service platform, and the service platform configures related data of the WSN terminal, and enables the services supported by the WSN terminal.
  • the WSN terminal writes the network configuration parameter and joins the designated WSN, and the WSN's main gateway specifies the gateway used by the WSN terminal to access the telecommunication network, so that the WSN terminal can report to the service platform through the gateway. data.
  • the main gateway stores the corresponding relationship between the WSN terminal in the WSN and the assigned gateway.
  • the primary gateway may select another slave gateway closer to the WSN terminal for one WSN terminal, thereby reducing the WSN. Routing between the terminal and the slave gateway The path is achieved to reduce the communication complexity and energy saving effect in the WSN.
  • the main gateway may specify a new gateway for the WSN terminal to provide the telecommunication network access, and the main gateway may send the information and communication connection configuration information of the WSN terminal to the newly designated gateway, and notify the gateway change message that the The WSN terminal provides a gateway for telecommunications network access.
  • the newly designated gateway adds the configuration information of the WSN terminal to the gateway, and the original gateway deletes the telecommunication network access configuration information of the WSN terminal stored in the gateway.
  • the newly designated gateway provides telecommunication network access for the WSN terminal, and the original gateway no longer provides telecommunication network access for the WSN terminal.
  • the gateway used by the primary gateway and the WSN terminal to access the telecommunication network can clear the telecommunication network access configuration information of the WSN terminal that is saved, the gateway corresponding to the main gateway and the WSN terminal, The WSN terminal is no longer provided with telecommunication network access after leaving the WSN.
  • the primary gateway and the secondary gateway in the wireless sensor network can establish communication through the telecommunication network and the management platform; when the primary gateway and the secondary gateway perform data backup on the management platform, the backup data can be sent to the management platform through the communication connection.
  • the management platform receives and saves backup data. After the primary gateway and the secondary gateway perform data backup on the management platform, if the data that needs to be backed up by the primary gateway and the secondary gateway is updated, the primary gateway and the secondary gateway can send the updated data to the management platform.
  • FIG. 4 is a flowchart of a slave gateway replacing a master gateway in a WSN according to Embodiment 3 of the present invention. As shown in FIG. 4, the process of replacing a master gateway after the master gateway in the wireless sensor network fails to work normally includes the following steps. :
  • Step 401 Determine that the primary gateway in the wireless sensor network is not working properly.
  • the main gateway cannot work normally because it is caused by a fault. Moreover, whether the main gateway works normally is determined by the management platform. Specifically, the management platform can determine whether the main gateway works normally by the following means: 1. When the primary gateway fails but can still communicate with the management platform of the telecommunication network, the primary gateway notifies the management platform of the fault information;
  • the management platform periodically checks the gateway of the wireless sensor network, and detects that the primary gateway is faulty;
  • the gateway detects that the primary gateway is faulty, and notifies the management platform of the fault information
  • the WSN terminal detects that the primary gateway has failed, and notifies the fault information (such as notification from the gateway through its own access) management platform.
  • Step 402 The management platform determines that one slave gateway in the wireless sensor network replaces the primary gateway.
  • the management platform maintains information about the slave gateways in the wireless sensor network, and the management platform can select a slave gateway that replaces the master gateway according to factors such as functions, performance, and current load supported by the gateway device. After the management platform determines to replace the slave gateway of the master gateway, establish communication with the slave gateway through the telecommunication network, and notify the slave gateway to replace the master gateway in the wireless sensor network, and the slave gateway works as a new master gateway in the wireless sensor network. .
  • Step 403 The management platform provides the backup data of the original primary gateway to the determined secondary gateway (ie, the new primary gateway).
  • the slave gateway works as a new master gateway in the wireless sensor network, needs to obtain configuration information of the wireless sensor network, and uses the configuration information to manage the wireless sensor network, and the information is backed up by the original master gateway on the management platform.
  • the backup data can be provided to the slave gateway by the management platform.
  • the management platform and the slave gateway establish a communication connection through the telecommunication network, and the management platform can send the backup data of the original master gateway to the slave gateway through the communication connection, and receive and save the backup data from the gateway.
  • Step 404 The new primary gateway notifies the WSN terminal and other gateways in the wireless sensor network of the primary gateway change information.
  • the new primary gateway can notify the WSN terminal and other gateways in the wireless sensor network through broadcast messages in the wireless sensor network. After receiving the primary gateway change notification message, the WSN terminal and other gateways can create a communication path with the new primary gateway. Thereby, it is possible to communicate normally with the new primary gateway.
  • Step 405 The new primary gateway determines whether there is a WSN terminal accessing the telecommunication network through the original primary gateway. If yes, the process in step 406 is performed; if not, the process of replacing the primary gateway ends.
  • the new primary gateway can obtain the correspondence between the WSN terminal in the wireless sensor network and its assigned gateway according to the obtained backup data of the original primary gateway, and identify whether there is a WSN terminal accessing the telecommunication network through the original primary gateway.
  • Step 406 The new primary gateway specifies a new gateway for the WSN terminal accessing the telecommunication network through the original primary gateway.
  • the new primary gateway assigns a new access to the telecommunications network to the WSN terminal.
  • the method described in the second step 305 of the second embodiment of the present invention is not described herein.
  • the primary gateway in the wireless sensor network needs to preset the backup gateway priority of the secondary gateway in the wireless sensor network; when the backup gateway priority of the gateway indicates that the primary gateway fails, the gateway is selected as the new primary gateway to work; When the primary gateway fails, the slave gateway with the highest priority of the backup gateway is selected as the new primary gateway.
  • the priority of the backup gateway of the slave gateway may be set as follows: When the gateway joins the wireless sensor network as the routing node, the primary gateway sets the priority of the backup gateway of the slave gateway, and sends the setting information of the backup gateway priority of the slave gateway.
  • the backup gateways of other gateways are preferred.
  • the setup information of the predecessor is sent to the slave gateway.
  • the primary gateway, the secondary gateway, and the management platform grasp the priority of the backup gateway of each slave gateway in the wireless sensor network.
  • FIG. 5 is a flowchart of a slave gateway replacing a master gateway in a WSN according to Embodiment 4 of the present invention. As shown in FIG. 5, a process of replacing a master gateway after the master gateway in the wireless sensor network in this embodiment cannot work normally is specific. Includes the following steps:
  • Step 501 Determine, from the gateway or the management platform, that the primary gateway in the wireless sensor network is unable to work normally;
  • the primary gateway fails to work normally, it is usually caused by a fault or abnormality. You can determine whether the primary gateway works normally by the following methods:
  • the primary gateway fails but can still communicate with the management platform of the telecommunication network, the primary gateway notifies the management platform or the secondary gateway of the fault information;
  • the management platform or the gateway detects the gateway of the wireless sensor network periodically, and detects that the primary gateway is faulty;
  • the gateway detects that the primary gateway is faulty, and notifies the management platform of the fault information
  • the WSN terminal detects that the primary gateway is faulty, and notifies the fault information (such as notification from the gateway through its own access) to the management platform or the slave gateway.
  • Step 502 The gateway or the management platform notifies the failure information of the primary gateway that the backup gateway has the highest priority as the secondary gateway;
  • the gateway or the management platform determines that the primary gateway is faulty, it determines the secondary gateway with the highest priority of the backup gateway according to the setting information of the backup gateway priority of the gateway, and then notifies the secondary gateway of the failure of the primary gateway. Gateway.
  • Step 503 The slave gateway has the highest priority, and the slave gateway notifies the other slave gateways and the management platform that the master gateway can be replaced by the current master gateway.
  • Step 504 The management platform provides backup data of the original primary gateway to the new primary gateway.
  • Step 505 The new primary gateway notifies the WSN terminal and other gateways in the wireless sensor network of the primary gateway change information;
  • Step 506 The new primary gateway determines whether there is a WSN terminal that accesses the telecommunication network through the original primary gateway. If yes, the process in step 507 is performed; if not, the process of replacing the primary gateway ends.
  • Step 507 The new primary gateway specifies a new gateway for the WSN terminal accessing the telecommunication network through the original primary gateway.
  • one of the slave gateways replaces the master gateway when the master gateway in the wireless sensor network fails to work normally, so that the wireless sensor network can continue to work normally.
  • the following is the following related content related to the establishment of WSN and management of WSN through Zigbee technology.
  • ZigBee is an emerging short-range, low-rate, low-cost, low-power wireless network technology. It uses Direct Sequence Spread Spectrum (DSSS) technology and operates at 868MHz, 915MHz or 2.4GHz. There are three types of nodes in the ZigBee network: ZigBee coordination point, ZigBee routing node and ZigBee terminal node.
  • DSSS Direct Sequence Spread Spectrum
  • the ZigBee coordination point is also called the Personal Area Network (PAN) coordination point (ZC, ZigBee Coordinator) in IEEE 802.15.4, and can be used as a convergence node in the WSN.
  • the ZigBee coordination point must be a Full-Function Device (FFD).
  • a ZigBee network has only one ZigBee coordination point. It is often more powerful than other nodes in the network and is the master node of the entire network. It is responsible for initiating the establishment of new networks, setting network parameters, managing nodes in the network, and storing node information in the network. After the network is formed, it can also perform the functions of the router.
  • the ZigBee Routing Node (ZR, ZigBee Router) must also be a fully functional device.
  • ZigBee routing nodes can participate in route discovery, message forwarding, and extend the network by connecting other nodes. Coverage, etc.
  • the ZigBee routing node can also act as a common coordination point in its Personal Operating Space (POS), and IEEE 802.15.4 is called a coordination point.
  • POS Personal Operating Space
  • IEEE 802.15.4 IEEE 802.15.4
  • the ZigBee EndNode (ZE, ZigBee EndDevice) can be a full-featured device or a Reduced-Function Device (RFD), which connects to the network through ZigBee co-nodes or ZigBee routing nodes, but does not allow any other node to join through it.
  • RFD Reduced-Function Device
  • ZigBee endpoints can operate at very low power.
  • the primary gateway acts as a Zigbee coordination point in the Zigbee network and is responsible for the formation of the WSN.
  • the WSN terminal can join the WSN as a Zigbee routing node or a Zigbee terminal node; the slave gateway (or other gateways other than the primary gateway) joins the WSN as a Zigbee routing node.
  • the gateway and WSN terminal need to support Zigbee communication technology.
  • the keys used in the Zigbee network mainly include: Master Key, Link Key, and Network Key.
  • the master key is a shared key used in the process of performing a symmetric key establishment protocol, and is a long-term security basis between two devices, and can be used to generate a link key; the link key is in a PAN network, A key shared between two devices for secure communication between two devices; a network key is a shared key in a PAN network for the security of broadcast communication.
  • a trust center is a type of trusted device that distributes security keys across the network. It allows devices to join the network and assign keys, thus ensuring end-to-end security between devices.
  • the network coordinator can become a trust center.
  • the Trust Center provides the following three functions: (1) Trust Management: The task is responsible for verifying the device joining the network. (2) Network Management: The task is to obtain and assign network keys to the device.
  • Configuration management The task is to bind the application to the device it manages, and achieve end-to-end secure transmission between the two devices.
  • the device In order to implement trust management, the device needs to receive the initial master key from the trust center. For network management purposes, the device should receive the initial network key and can only obtain updates to the network key from the Trust Center. In order to implement network configuration, the device needs to receive a master key or a link key from the trust center to establish an end-to-end secure link between the two devices.
  • the additional link key, master key, and network key can only be obtained from the trust center in a secure manner.
  • the trust center should periodically update the network key according to a policy and pass the new network key to each device.
  • the primary gateway acts as a trust center for network security management.
  • the identity authentication and secure communication of the gateway can be implemented between the management platform and other network elements in the gateway and the telecommunication network through the identity of the gateway.
  • a WSN is identified by the network identifier of the WSN.
  • the network identifier of the WSN may be determined by the primary gateway or by the management platform.
  • the information about the network identifier and the network location of the WSN is recorded in the management platform.
  • the management platform can determine whether there is a WSN managed by the management platform according to a given location. If there is a WSN, the WSN of the location can be obtained, thereby determining the WSN at the location.
  • the system for accessing the telecommunication network of the wireless sensor network of the present invention can be specifically understood in conjunction with the system shown in FIG. 1 above. It should be noted that the system for accessing the telecommunication network of the wireless sensor network of the present invention is realized by updating the function of the corresponding network element on the basis of the existing combined network, and the connection structure of the network element in the network is not change.
  • 6 is a schematic structural diagram of a system for accessing a telecommunication network of a wireless sensor network according to the present invention. As shown in FIG. 6, the system for accessing a telecommunication network of the wireless sensor network of the present invention includes a determining unit 60 and a replacing unit 61, wherein
  • the determining unit 60 is configured to: when it is determined that the primary gateway is not working properly, trigger the replacement unit;
  • the replacing unit 61 is configured to operate one of the WSNs from the gateway as a primary gateway instead of the original primary gateway.
  • the determining unit 60 is disposed in the management platform, and after determining that the primary gateway in the WSN is not working properly, further determining a secondary gateway of the replacement primary gateway in the WSN, and notifying the determined secondary gateway by the proxy unit 61. As the primary gateway, it works instead of the original primary gateway.
  • the replacement unit 61 is disposed in the slave gateway. After the determining unit 60 determines that the master gateway in the WSN is not working properly, the replacing unit 61 further determines, by the slave gateway in the WSN, a new master gateway to work instead of the original master gateway.
  • the system for accessing a telecommunications network of the wireless sensor network of the present invention further includes a setting unit (not shown) and a transmitting unit (not shown), wherein
  • a setting unit configured to determine a backup gateway of the primary gateway in the WSN in advance, and set a priority for the backup gateway
  • a sending unit configured to send information about the priority of the backup gateway to each slave gateway and the management platform
  • the above replacement unit 61 is provided in the slave gateway or the management platform;
  • the replacing unit 61 is further configured to notify the backup gateway with the highest priority of the backup gateway, and replace the original gateway with the highest priority backup gateway. jobs.
  • the management platform stores backup information of the primary gateway
  • the management platform sends the stored backup information of the primary gateway to the secondary gateway replacing the original primary gateway, and the secondary gateway replacing the original primary gateway uses the backup information of the original primary gateway at the WSN. working.
  • the system for accessing a telecommunication network of the wireless sensor network of the present invention further includes a broadcasting unit (not shown) for transmitting a broadcast message in the WSN after the replacement unit replaces the original primary gateway from the gateway, and the new primary gateway is The information informs the WSN terminal and the rest of the WSN from the gateway.
  • a broadcasting unit (not shown) for transmitting a broadcast message in the WSN after the replacement unit replaces the original primary gateway from the gateway, and the new primary gateway is The information informs the WSN terminal and the rest of the WSN from the gateway.

Abstract

A method for a Wireless Sensor Network (WSN) connecting to a telecommunication network is disclosed in the present invention, wherein a WSN terminal and more than two WSN gateways are set in the WSN, and a main gateway is set in the more than two WSN gateways; a management platform is set in the telecommunication network; the method still comprises the following steps that: when the main gateway cannot work normally, one of the secondary gateways in the WSN is made as a main gateway to replace the original main gateway to perform work. A WSN connecting to a telecommunication network for realizing the above method is disclosed in the present invention simultaneously. In the present invention, when the main gateway is broken and can not perform work normally, one of the secondary gateways can replace the main gateway and work as a main gateway, so that the WSN and the relational service thereof can operate normally, thus improving the reliability of the Wireless Sensor Network which is collocated multi gateways.

Description

无线传感器网络接入电信网络的方法及系统 技术领域  Method and system for wireless sensor network accessing telecommunication network
本发明涉及结合网络中的接入技术, 尤其涉及一种无线传感器网络接 入电信网络的方法及系统。 背景技术  The present invention relates to an access technology in a combined network, and more particularly to a method and system for a wireless sensor network to access a telecommunications network. Background technique
无线传感器网络作为计算、 通信和传感器三项技术相结合的产物, 是 一种全新的信息获取和处理技术。 由于近来微型制造技术、 通讯技术及电 池技术的改进, 促使微小的传感器终端可具有感应、 无线通讯及处理信息 的能力。 此类传感器终端不但能够感应及侦测环境的目标物及其改变, 并 且可处理收集到的数据, 并将处理过后的资料以无线传输的方式送到数据 收集中心。 这些传感器终端通常由电源、 感知部件、 嵌入式处理器、 存储 器、 通信部件和执行软件这几部分构成。 其中, 电源为传感器节点提供正 常工作所必需的能源。 感知部件用于感知、 获取外界的信息, 并将其转换 为数字信号。 嵌入式处理器负责协调节点各部分的工作, 如对感知部件获 取的信息进行必要的处理、 保存, 控制感知部件和电源的工作模式等。 通 信部件负责与其他传感器或观察者进行通信。 执行软件则为传感器终端提 供必要的软件支持, 如嵌入式操作系统、 嵌入式数据库系统等。 借助于传 感器终端中内置的形式多样的感知部件来测量该传感器终端所在周边环境 中的热、 红外、 声纳、 雷达和地震波信号, 从而探测包括温度、 湿度、 噪 声、 光强度、 压力、 土壤成分、 移动物体的大小、 速度和方向等众多信息。 传感器终端一般通过自组织或预配置的方式构成网络。 在通信方式上, 虽 然可以釆用有线、 无线、 红外和光等多种形式, 但一般认为短距离的无线 低功率通信技术最适合传感器网络的使用, 一般称作无线传感器网络 ( WSN, Wireless Sensor Network )„ 目前使用比较广泛的无线低功率通信 技术包括: 美国电气和电子工程师协会 ( IEEE, Institute of Electrical and Electronics Engineers ) 802.15.4和 Zigbee技术。 As a product of the combination of computing, communication and sensor technologies, wireless sensor networks are a new information acquisition and processing technology. Due to recent improvements in microfabrication technology, communication technology, and battery technology, tiny sensor terminals have the ability to sense, wirelessly communicate and process information. Such sensor terminals can not only sense and detect the target of the environment and its changes, but also process the collected data and send the processed data to the data collection center by wireless transmission. These sensor terminals typically consist of a power supply, sensing components, an embedded processor, memory, communication components, and execution software. Among them, the power supply provides the sensor node with the energy necessary for normal operation. The sensing component is used to sense, acquire, and convert external information into digital signals. The embedded processor is responsible for coordinating the work of various parts of the node, such as performing necessary processing, saving, and controlling the operating mode of the sensing component and the power supply. The communication component is responsible for communicating with other sensors or observers. Execution software provides the necessary software support for sensor terminals, such as embedded operating systems, embedded database systems, and more. Detecting thermal, infrared, sonar, radar and seismic signals in the surrounding environment of the sensor terminal by means of a variety of sensing components built into the sensor terminal, thereby detecting temperature, humidity, noise, light intensity, pressure, soil composition , a lot of information such as the size, speed and direction of moving objects. Sensor terminals typically form a network in a self-organizing or pre-configured manner. In terms of communication methods, although wired, wireless, infrared, and optical formats can be used, it is generally considered that short-range wireless low-power communication technology is most suitable for the use of sensor networks, generally called wireless sensor networks. ( WSN, Wireless Sensor Network ) „ The current widely used wireless low-power communication technologies include: IEEE, Institute of Electrical and Electronics Engineers 802.15.4 and Zigbee technology.
IEEE 802.15.4 是由 IEEE开发的低速无线个域网 (WPAN, Wireless Personal Area Network )标准。 IEEE 802.15.4规定了物理层和介质访问控制 层(MAC, Media Access Control )标准。 符合 IEEE 802.15.4标准的通信模 块具备低成本、 低耗电、 小尺寸的特点。  IEEE 802.15.4 is a low-speed wireless personal area network (WPAN) standard developed by IEEE. IEEE 802.15.4 specifies the physical layer and medium access control layer (MAC, Media Access Control) standards. The IEEE 802.15.4 compliant communication module features low cost, low power consumption, and small size.
Zigbee联盟是一个致力于在开放的全球标准的基础上, 开发可靠的、 低成本、 低耗电、 无线网络连接的监测和控制产品的组织。 Zigbee 标准的 物理层和 MAC层釆用 IEEE 802.15.4技术, 网络层、 安全管理、 应用层规 范以及互通性由 Zigbee联盟开发。 Zigbee标准中的 Zigbee智能能源公共应 用规范 ( Zigbee smart energy public applications profile )和 Zigbee家庭自动 化应用规范 ( Zigbee home automation public applications profile )分另 ll针对商 业环境应用和家庭应用。  The Zigbee Alliance is an organization dedicated to developing reliable, low-cost, low-power, wireless network connectivity monitoring and control products based on open global standards. The Zigbee standard physical layer and MAC layer use IEEE 802.15.4 technology, and the network layer, security management, application layer specifications, and interoperability are developed by the Zigbee Alliance. The Zigbee smart energy public applications profile and the Zigbee home automation public applications profile in the Zigbee standard are for business environment applications and home applications.
WSN终端的微处理能力和无线通信能力使无线传感器网络有广阔的应 用前景, 其应用包括军事应用、 生物和环境监测、 健康应用、 家庭应用、 工业控制和监测等。  The WSN terminal's micro-processing capabilities and wireless communication capabilities make wireless sensor networks a promising application for military applications, biological and environmental monitoring, health applications, home applications, industrial control and monitoring.
无线传感器网络和电信网结合, 如第二代(2G, 2nd Generation )移动 通信、 第三代(3G, 3rd Generation )移动通信、 xDSL ( x Digital Subscriber Line )、 FTTx ( Fiber To The x, x 为 home、 building、 node、 premises )、 覔 带无线接入、 卫星 /微波等, 可以使无线传感器网络作为现有网络的延伸, 扩展通信网络的能力, 使通信对象从人扩展到物理世界, 具有良好的发展 前景。 无线传感器网络与现有的电信网络结合后, 可以使无线传感器网络 感知的数据有效地传递到数据中心, 通过对数据的整理和分析, 可以极大 程度地改变人类获取自然世界的数据的方式, 同时也能够对无线传感器网 络进行集中的管理, 解决目前分散在各处的无线传感器网络难以管理的问 题。 The combination of wireless sensor networks and telecommunication networks, such as second generation (2G, 2nd Generation) mobile communication, third generation (3G, 3rd Generation) mobile communication, xDSL (x Digital Subscriber Line), FTTx (Fiber To The x, x is Home, building, node, premises), wireless access, satellite/microwave, etc., can make wireless sensor networks an extension of existing networks, expand the capabilities of communication networks, and enable communication objects to extend from people to the physical world. Development prospects. When combined with the existing telecommunication network, the wireless sensor network can effectively transmit the data perceived by the wireless sensor network to the data center. By sorting and analyzing the data, the way of acquiring data of the natural world can be greatly changed. Wireless sensor network The centralized management of the network solves the problem that the wireless sensor networks that are currently scattered everywhere are difficult to manage.
无线传感器网络与电信网络结合, 是指将无线传感器网络与电信网络 相连接, 利用电信网络对无线传感器网络及其提供的业务进行监控、 管理 及完成业务的承载与合作实施, 并通过电信网络扩展无线传感器网络所提 供的业务。 无线传感器网络和电信网的结合一般是无线传感器网络通过网 关设备连接至电信网平台。  The combination of a wireless sensor network and a telecommunication network refers to connecting a wireless sensor network with a telecommunication network, and utilizing the telecommunication network to monitor, manage, and complete the service carrying and cooperation of the wireless sensor network and the services provided by the telecommunication network, and expand the telecom network. The services provided by wireless sensor networks. The combination of a wireless sensor network and a telecommunications network is generally a wireless sensor network connected to a telecommunications network platform through a gateway device.
WSN终端为构成 WSN的传感器节点, 通过一跳或多跳与网关连接。 WSN终端负责釆集并上传数据, 以及接收并执行命令。 组成 WSN的 WSN 终端少则几个多则几百个, WSN终端之间可根据需要以星形、 树形或网状 ( mesh )等方式组网,其中某些 WSN终端或具有较强的组网和数据转发能 力。 在 WSN中, 网关负责将 WSN终端上报的数据, 发送至电信网络中的 相关网络单元, 电信网络中的相关网络单元通过网关将相关指令发送给 WSN终端。而且在 WSN釆用常用的 IEEE 802.15.4和 Zigbee技术时,一般 由网关负责创建 WSN, 负责 WSN终端加入和离开传感网时的管理, 网关 中保存有 WSN终端的配置信息和传感网的业务配置信息等重要数据。  The WSN terminal is a sensor node constituting the WSN and is connected to the gateway by one or more hops. The WSN terminal is responsible for collecting and uploading data, as well as receiving and executing commands. The WSN terminals that make up the WSN are as few as a few hundreds, and WSN terminals can be networked in a star, tree or mesh manner, some of which have strong groups. Network and data forwarding capabilities. In the WSN, the gateway is responsible for transmitting the data reported by the WSN terminal to the relevant network unit in the telecommunication network, and the relevant network unit in the telecommunication network sends the relevant command to the WSN terminal through the gateway. Moreover, when the WSN uses the commonly used IEEE 802.15.4 and Zigbee technologies, the gateway is generally responsible for creating the WSN, which is responsible for the management of the WSN terminal when joining and leaving the sensor network, and the configuration information of the WSN terminal and the sensor network are stored in the gateway. Important data such as business configuration information.
WSN终端上报的数据, 需要通过网关发送给电信网络中的相关网络单 元, 而现有 WSN中通常只配置一个网关, 用于将 WSN终端上报的数据转 发给电信网络中的相关网络单元,从而当 WSN中的 WSN终端数量比较多、 或者 WSN终端频繁上报数据时, WSN中的网关负荷很大而导致 WSN终 端的数据不能及时发送以及 WSN终端与网关之间的通信发生拥塞。 这样, 会严重地影响到 WSN的正常工作。 另外, 电信网络侧的网络单元执行对无 线传感器网络中的 WSN终端的管理时,需要通过无线传感器网络的网关建 立和 WSN终端的通信;如果电信网络侧的网关单元只通过一个网关和无线 传感器网络中的 WSN终端建立通信,同样会给该网关造成比较大的承载压 力,导致电信网络侧的网关单元不能及时地与无线传感器网络中的 WSN终 端建立通信, 影响相关业务的正常运行。 因此, 需要考虑电信网络侧的相 关网络单元如何通过 WSN网关与无线传感器网络中的 WSN终端进行更顺 畅的通信等问题。 对于该问题, 一种可行的解决方案是在无线传感器网络 中配置多个网关,无线传感器内的 WSN终端通过这些网关上 4艮数据以及电 信网络侧的网络单元通过这些网关建立和 WSN终端进行通信;无线传感器 网络配置的多个网关可以釆用主从网关工作模式, 由一个网关作为主网关, 其余的网关作为从网关; 主网关负责创建无线传感器网络的创建和管理, 主网关为 WSN终端分配接入电信网络所使用的网关,该分配的网关可以为 主网关, 也可以为其中的一个从网关, WSN终端通过分配的网关接入电信 网络, 从网关根据主网关的调度为所述 WSN终端提供电信网络接入。 因此 在这种解决方案中, 主网关在无线传感器网络的正常运行中起着重要的作 用。 如果主网关在出现故障等情况并导致不能正常工作时, 无线传感器网 络以及相关业务将不能正常运行, 需要有相应的解决方法, 在主网关出现 故障时, 釆取相关方法使无线传感器网络及其相关业务能够正常工作。 目 前对于该问题, 还没有相应的解决方案。 发明内容 The data reported by the WSN terminal needs to be sent to the relevant network unit in the telecommunication network through the gateway, and the existing WSN usually only configures one gateway for forwarding the data reported by the WSN terminal to the relevant network unit in the telecommunication network, so that When the number of WSN terminals in the WSN is relatively large, or when the WSN terminal frequently reports data, the gateway load in the WSN is so large that the data of the WSN terminal cannot be sent in time and the communication between the WSN terminal and the gateway is congested. This will seriously affect the normal operation of the WSN. In addition, when the network unit on the telecommunication network side performs management of the WSN terminal in the wireless sensor network, it is required to establish communication with the WSN terminal through the gateway of the wireless sensor network; if the gateway unit on the telecommunication network side only passes through one gateway and the wireless sensor network The WSN terminal in the establishment of communication will also cause a relatively large load on the gateway. The force causes the gateway unit on the telecommunication network side to fail to establish communication with the WSN terminal in the wireless sensor network in time, which affects the normal operation of related services. Therefore, it is necessary to consider how the relevant network element on the telecommunication network side performs more smooth communication with the WSN terminal in the wireless sensor network through the WSN gateway. For this problem, a feasible solution is to configure multiple gateways in the wireless sensor network. The WSN terminals in the wireless sensors communicate with the WSN terminals through the gateways and the network elements on the telecommunication network side through these gateways. The multiple gateways configured in the wireless sensor network can use the master-slave gateway working mode, with one gateway as the primary gateway and the remaining gateways as the slave gateways; the primary gateway is responsible for creating the creation and management of the wireless sensor network, and the primary gateway is assigned to the WSN terminal. Accessing the gateway used by the telecommunication network, the allocated gateway may be the primary gateway, or may be one of the secondary gateways, and the WSN terminal accesses the telecommunication network through the allocated gateway, and the secondary gateway is the WSN terminal according to the scheduling of the primary gateway. Provide telecommunications network access. Therefore, in this solution, the primary gateway plays an important role in the normal operation of the wireless sensor network. If the primary gateway is in a faulty situation and causes it to malfunction, the wireless sensor network and related services will not operate normally. A corresponding solution is needed. When the primary gateway fails, the relevant methods are used to make the wireless sensor network and its Related business can work normally. There is currently no corresponding solution to this problem. Summary of the invention
有鉴于此, 本发明的主要目的在于提供一种无线传感器网络接入电信 网络的方法及系统, 能在主网关故障时及时确认新的主网关而不影响 WSN 与电信网络的通信。  In view of this, the main object of the present invention is to provide a method and system for a wireless sensor network to access a telecommunications network, which can timely confirm a new primary gateway when the primary gateway fails without affecting communication between the WSN and the telecommunications network.
为达到上述目的, 本发明的技术方案是这样实现的:  In order to achieve the above object, the technical solution of the present invention is achieved as follows:
一种无线传感器网络接入电信网络的方法, 所述 WSN中设有 WSN终 端和两个以上的 WSN网关, 所述两个以上的 WSN网关中设置有主网关; 所述电信网络中设置有管理平台; 所述方法还包括:  A method for a wireless sensor network to access a telecommunication network, wherein the WSN is provided with a WSN terminal and two or more WSN gateways, and the two or more WSN gateways are provided with a main gateway; the telecommunication network is provided with management Platform; the method further includes:
所述主网关不能正常工作时, 将所述 WSN 中的一个从网关作为主网 关, 代替原主网关进行工作。 When the primary gateway fails to work normally, one of the WSNs is used as a primary network from the gateway. Off, instead of working with the original primary gateway.
优选地, 所述将所述 WSN中的一个从网关作为主网关, 代替原主网关 进行工作, 为:  Preferably, the one of the WSNs is used as a primary gateway instead of the original primary gateway, and is:
所述代替原主网关的从网关由所述管理平台指定, 由该从网关代替原 主网关进行工作。  The slave gateway replacing the original primary gateway is designated by the management platform, and the slave gateway works in place of the original master gateway.
优选地, 管理平台指定代替原主网关的从网关, 为:  Preferably, the management platform specifies a slave gateway that replaces the original primary gateway, and is:
所述管理平台确定 WSN中的主网关不能正常工作后,进一步确定所述 WSN中的替换主网关的从网关, 并通知所确定的从网关作为主网关, 代替 原主网关进行工作。  After the management platform determines that the primary gateway in the WSN is not working properly, the slave gateway of the replacement primary gateway in the WSN is further determined, and the determined secondary gateway is notified as the primary gateway to work instead of the original primary gateway.
优选地, 所述将所述 WSN中的一个从网关作为主网关, 代替原主网关 进行工作, 为:  Preferably, the one of the WSNs is used as a primary gateway instead of the original primary gateway, and is:
WSN中的从网关协商确定出新的主网关, 代替原主网关进行工作。 优选地, 所述将所述 WSN中的一个从网关作为主网关, 代替原主网关 进行工作, 为:  The slave gateway in the WSN negotiates to determine a new master gateway to work in place of the original master gateway. Preferably, the one of the WSNs is used as a primary gateway instead of the original primary gateway, and is:
预先在 WSN 中确定主网关的后备网关, 并为所述后备网关设置优先 级, 并将所述后备网关优先级的信息发送给各从网关及所述管理平台; 所述主网关不能正常工作时, 从网关或管理平台将主网关的故障信息 通知后备网关优先级为最高的后备网关, 由所述优先级为最高的后备网关 代替原主网关进行工作。  Determining a backup gateway of the primary gateway in the WSN, and setting a priority for the backup gateway, and sending the information of the backup gateway priority to each slave gateway and the management platform; The gateway or the management platform notifies the failure gateway of the primary gateway to the backup gateway with the highest priority of the backup gateway, and the backup gateway with the highest priority replaces the original primary gateway.
优选地, 所述方法还包括:  Preferably, the method further includes:
所述管理平台中存储有主网关的备份信息;  The management platform stores backup information of the primary gateway;
所述从网关代替原主网关时, 所述管理平台将所存储的主网关的备份 信息发送给代替原主网关的从网关, 所述代替原主网关的从网关使用原主 网关的备份信息在 WSN进行工作。  When the slave gateway replaces the original master gateway, the management platform sends the stored backup information of the master gateway to the slave gateway replacing the original master gateway, and the slave gateway replacing the original master gateway uses the backup information of the original master gateway to work in the WSN.
优选地, 所述方法还包括: 从网关代替原主网关后, 在所述 WSN中发送广播消息, 将新主网关的 信息通知 WSN终端和 WSN的其余从网关。 Preferably, the method further includes: After the gateway replaces the original primary gateway, a broadcast message is sent in the WSN, and the information of the new primary gateway is notified to the WSN terminal and the remaining slave gateways of the WSN.
优选地, 所述管理平台中存储有主网关和从网关的备份信息; 所述主网关的备份信息包括 WSN的配置信息、 WSN终端和为 WSN 终端分配的网关之间的对应关系信息; 所述 WSN的配置信息包括 WSN的 标识、 网络拓朴信息、从网关信息、 WSN终端的信息和网络安全设置信息; 所述从网关的备份信息包括从网关信息、 通过从网关接入的电信网络的 WSN终端的信息;其中,所述从网关信息包括从网关标识信息和地址信息, 所述 WSN终端的信息包括 WSN终端标识信息和地址信息。  Preferably, the management platform stores backup information of the primary gateway and the secondary gateway; the backup information of the primary gateway includes configuration information of the WSN, correspondence information between the WSN terminal and the gateway allocated for the WSN terminal; The configuration information of the WSN includes the identifier of the WSN, the network topology information, the slave gateway information, the information of the WSN terminal, and the network security setting information. The backup information of the slave gateway includes the gateway information, and the WSN of the telecommunication network accessed through the slave gateway. Information about the terminal; wherein the slave gateway information includes slave gateway identification information and address information, and the information of the WSN terminal includes WSN terminal identification information and address information.
优选地, 所述方法还包括:  Preferably, the method further includes:
新主网关根据所获得的 WSN终端和为 WSN终端分配的网关之间的对 应关系信息确定存在通过原主网关接入电信网络的 WSN终端时,为所述通 过原主网关接入电信网络的 WSN终端重新分配接入电信网络的网关。  The new primary gateway determines, according to the correspondence information between the obtained WSN terminal and the gateway allocated for the WSN terminal, that the WSN terminal accessing the telecommunication network through the original primary gateway exists for the WSN terminal accessing the telecommunication network through the original primary gateway. Assign a gateway to the telecommunications network.
一种无线传感器网络接入电信网络的系统, 所述 WSN中设有 WSN终 端和两个以上的 WSN网关, 所述两个以上的 WSN网关中设置有主网关; 所述电信网络中设置有管理平台; 所述系统包括确定单元和代替单元, 其 中,  A system for accessing a telecommunication network by a wireless sensor network, wherein the WSN is provided with a WSN terminal and two or more WSN gateways, and the two or more WSN gateways are provided with a main gateway; the telecommunication network is provided with management a platform; the system includes a determining unit and a replacing unit, wherein
确定单元, 用于确定主网关不能正常工作时, 触发代替单元; 代替单元, 用于将所述 WSN中的一个从网关作为主网关, 代替原主网 关进行工作。  a determining unit, configured to: when the primary gateway is not working properly, trigger a replacement unit; and the replacing unit is configured to use one of the WSNs as a primary gateway instead of the original primary gateway to work.
优选地, 所述确定单元设于所述管理平台中, 在确定 WSN中的主网关 不能正常工作后, 进一步确定所述 WSN中的替换主网关的从网关, 并由所 述代理单元通知所确定的从网关作为主网关, 代替原主网关进行工作。  Preferably, the determining unit is disposed in the management platform, after determining that the primary gateway in the WSN is not working normally, further determining a secondary gateway of the replacement primary gateway in the WSN, and notifying by the proxy unit The slave gateway acts as the master gateway, replacing the original master gateway.
优选地, 所述代替单元设于从网关中; 所述确定单元确定 WSN中的主 网关不能正常工作后,所述代替单元进一步通过 WSN中的从网关协商确定 出新的主网关, 代替原主网关进行工作。 Preferably, the replacing unit is disposed in the slave gateway; after the determining unit determines that the master gateway in the WSN is unable to work normally, the replacing unit further determines through the slave gateway in the WSN. A new master gateway is used instead of the original master gateway.
优选地, 所述系统还包括设置单元和发送单元, 其中,  Preferably, the system further includes a setting unit and a sending unit, where
设置单元, 用于预先在 WSN中确定主网关的后备网关, 并为所述后备 网关设置优先级;  a setting unit, configured to determine a backup gateway of the primary gateway in the WSN in advance, and set a priority for the backup gateway;
发送单元, 用于将所述后备网关优先级的信息发送给各从网关及所述 管理平台;  a sending unit, configured to send information about the priority of the backup gateway to each slave gateway and the management platform;
所述代替单元设于从网关或管理平台中;  The replacement unit is disposed in a slave gateway or a management platform;
所述确定单元确定主网关不能正常工作时, 所述代替单元进一步用于 将主网关的故障信息通知后备网关优先级为最高的后备网关, 由所述优先 级为最高的后备网关代替原主网关进行工作。  When the determining unit determines that the primary gateway is not working properly, the replacing unit is further configured to notify the backup gateway with the highest priority of the backup gateway as the fault information of the primary gateway, and replace the original primary gateway with the backup gateway with the highest priority. jobs.
优选地, 所述管理平台中存储有主网关的备份信息;  Preferably, the management platform stores backup information of the primary gateway;
所述代替单元将从网关代替原主网关时, 所述管理平台将所存储的主 网关的备份信息发送给代替原主网关的从网关, 所述代替原主网关的从网 关使用原主网关的备份信息在 WSN进行工作。  When the replacing unit replaces the original primary gateway from the gateway, the management platform sends the stored backup information of the primary gateway to the secondary gateway replacing the original primary gateway, and the secondary gateway replacing the original primary gateway uses the backup information of the original primary gateway in the WSN. working.
优选地, 所述系统还包括广播单元, 用于在所述代替单元将从网关代 替原主网关后,在所述 WSN中发送广播消息,将新主网关的信息通知 WSN 终端和 WSN的其余从网关。  Preferably, the system further includes a broadcast unit, configured to send a broadcast message in the WSN after the substitute unit replaces the original primary gateway, and notify the WSN terminal and the remaining slave gateways of the WSN of the information of the new primary gateway. .
本发明中, 在一个 WSN中配置多个网关, 多个网关釆用主从的工作模 式, 该多个网关分别为 WSN中的 WSN终端提供电信网络的接入, 并当主 网关出现故障而不能正常工作时, 可以由其中的一个从网关代替该主网关, 由该从网关代替原主网关进行工作, 使无线传感器网络及其有关业务可以 正常运行, 从而提高了配置多个网关的无线传感器网络的可靠性。 附图说明  In the present invention, multiple gateways are configured in one WSN, and multiple gateways use a master-slave working mode, and the multiple gateways respectively provide access to the telecommunication network for the WSN terminal in the WSN, and cannot be normal when the primary gateway fails. When working, the master gateway can be replaced by one of the slave gateways, and the slave gateway works instead of the original master gateway, so that the wireless sensor network and related services can operate normally, thereby improving the reliability of the wireless sensor network configuring multiple gateways. Sex. DRAWINGS
图 1为 WSN中存在多个网关时的网络架构示意图;  FIG. 1 is a schematic diagram of a network architecture when multiple gateways exist in a WSN;
图 2为本发明实施例一中 WSN配置多网关的流程图; 图 3为本发明实施例二中 WSN终端加入 WSN以及釆用主从网关的工 作模式时为 WSN终端分配网关的流程图; 2 is a flowchart of configuring a multi-gateway for a WSN according to Embodiment 1 of the present invention; 3 is a flow chart of allocating a gateway to a WSN terminal when the WSN terminal joins the WSN and uses the working mode of the master-slave gateway according to the second embodiment of the present invention;
图 4为本发明实施例三中 WSN中的从网关代替主网关的流程图; 图 5为本发明实施例四中 WSN中的从网关代替主网关的流程图; 图 6为本发明无线传感器网络接入电信网络的系统的组成结构示意图。 具体实施方式  4 is a flowchart of a slave gateway replacing a master gateway in a WSN according to Embodiment 3 of the present invention; FIG. 5 is a flowchart of a slave gateway replacing a master gateway in a WSN according to Embodiment 4 of the present invention; FIG. 6 is a wireless sensor network according to the present invention; Schematic diagram of the structure of a system for accessing a telecommunications network. detailed description
本发明的基本思想是: 在配置多个网关并釆用主从网关工作模式的无 线传感器网络中, 在主网关不能正常工作时, 确定无线传感器网络中的一 个从网关代替该主网关, 由该确定的从网关作为新的主网关在无线传感器 网络中工作, 从而提高了无线传感器网络的通信可靠性。  The basic idea of the present invention is: in a wireless sensor network configured with multiple gateways and using a master-slave gateway working mode, when the primary gateway fails to work normally, it is determined that one slave gateway in the wireless sensor network replaces the master gateway, The determined slave gateway acts as a new master gateway in the wireless sensor network, thereby improving the communication reliability of the wireless sensor network.
为使本发明的目的、 技术方案和优点更加清楚明白, 以下举实施例并 参照附图, 对本发明进一步详细说明。  The present invention will be further described in detail below with reference to the accompanying drawings.
本发明中 WSN配置的多个网关中, 以主从网关工作模式进行通信, 其 中设定一个网关为主网关, 其余的网关为从网关。 主网关确定 WSN 中的 WSN终端接入电信网络时所使用的网关, WSN终端通过主网关所指定的 网关接入到电信网络。 需要指出的是, 该指定的网关可以为主网关自身, 也可以为其中的一个从网关。 从网关 (包括主网关自身) 为主网关所指定 的 WSN终端提供电信网络接入。  In the multiple gateways configured by the WSN in the present invention, communication is performed in a master-slave gateway working mode, wherein one gateway is set as the primary gateway, and the remaining gateways are slave gateways. The primary gateway determines the gateway used by the WSN terminal in the WSN to access the telecommunication network, and the WSN terminal accesses the telecommunication network through the gateway designated by the primary gateway. It should be noted that the designated gateway may be the primary gateway itself or one of the secondary gateways. The telecommunications network access is provided from the WSN terminal designated by the gateway (including the main gateway itself) as the primary gateway.
主网关负责 WSN的创建,从网关作为 WSN中的路由节点加入到 WSN。 从网关加入到 WSN时, 需要在电信网络的管理平台进行注册, 管理平台记 录该从网关的相关信息, 至少包括从网关的标识、 从网关在电信网络中的 地址等信息, 并由管理平台通知 WSN 中的主网关有新的从网关加入到该 WSN。 从网关加入到该 WSN后, 主网关记录该从网关的信息, 从网关的 信息可以包括: 从网关在 WSN中的地址、 从网关在电信网络中的地址、 从 网关能够提供的电信网络接入能力等等。如果从网关在该 WSN中的地址和 在电信网络中的地址釆用同一个地址, 那么主网关只需要记录该地址。 主 网关和从网关之间的通信可以通过 WSN进行, 也可以通过电信网络进行。 The primary gateway is responsible for the creation of the WSN, and the gateway is added to the WSN as a routing node in the WSN. When the gateway joins the WSN, it needs to be registered on the management platform of the telecommunication network. The management platform records related information of the slave gateway, including at least the identifier of the gateway, the address of the slave gateway in the telecommunication network, and the like, and is notified by the management platform. The primary gateway in the WSN has a new slave gateway joining the WSN. After the gateway joins the WSN, the master gateway records the information of the slave gateway. The information of the slave gateway may include: an address from the gateway in the WSN, an address of the slave gateway in the telecommunication network, and a telecommunication network access that the slave gateway can provide. Ability and so on. If the address from the gateway in the WSN and If the address in the telecommunications network uses the same address, then the primary gateway only needs to record the address. The communication between the primary gateway and the secondary gateway can be carried out through the WSN or through the telecommunications network.
WSN终端加入 WSN时, 主网关才艮据网关分配的相关规则为该 WSN 终端分配接入电信网所使用的网关, 该分配的网关可以为主网关, 也可以 为从网关。 主网关可以才艮据网络的拓朴、 网关间的负载均衡、 WSN节点到 网关的路由的长度等方面确定 WSN节点接入电信网络所使用的网关,如为 WSN终端优先分配与该 WSN终端属于同一个域的网关作为接入电信网络 的网关,或者, 为 WSN终端优先分配当前载荷较轻的网关, 或者, 为 WSN 终端优先分配接入到电信网络条数不大于设定阔值的网关; 当然, 可以综 合参考上述的网关分配规则为 WSN终端分配接入电信网络的网关。进行网 关的分配时, 主网关将分配的网关的信息(如网关在 WSN中的地址)提供 给该 WSN终端, WSN终端保存所分配的网关的信息, 并创建到该网关的 路由信息; 主网关将该 WSN终端的信息 (包括 WSN终端的标识、 WSN 终端在 WSN中的地址 )提供给所分配的网关, 所分配的网关记录该 WSN 终端的信息。  When the WSN terminal joins the WSN, the primary gateway allocates the gateway used by the access telecommunication network to the WSN terminal according to the relevant rules assigned by the gateway, and the allocated gateway may be the primary gateway or the secondary gateway. The primary gateway can determine the gateway used by the WSN node to access the telecommunication network according to the topology of the network, the load balancing between the gateways, and the length of the route from the WSN node to the gateway, such as preferentially assigning WSN terminals to the WSN terminal. The gateway of the same domain is used as a gateway for accessing the telecommunication network, or the WSN terminal is preferentially assigned a gateway with a lighter current load, or the WSN terminal is preferentially allocated to a gateway whose access to the telecommunication network is not greater than a set threshold; Of course, the WSN terminal can be allocated a gateway for accessing the telecommunication network by referring to the above-mentioned gateway allocation rule. When the gateway is allocated, the primary gateway provides the information of the assigned gateway (such as the address of the gateway in the WSN) to the WSN terminal, and the WSN terminal saves the information of the assigned gateway and creates routing information to the gateway; The information of the WSN terminal (including the identifier of the WSN terminal, the address of the WSN terminal in the WSN) is provided to the assigned gateway, and the assigned gateway records the information of the WSN terminal.
主网关保存 WSN中的 WSN终端与其被分配的网关的对应关系, 并将 该对应关系的信息发送给电信网络的管理平台, 管理平台保存该对应关系 的信息。 该对应关系可以釆用对应表的形式实现, 该对应关系中记录 WSN 终端的标识以及其所被分配的网关的标识。 通过该对应关系可以查询到某 个 WSN终端接入电信网络所使用的网关,以及 WSN中的某个网关为 WSN 中的哪些 WSN终端提供电信网络接入。  The primary gateway saves the correspondence between the WSN terminal in the WSN and its assigned gateway, and sends the information of the corresponding relationship to the management platform of the telecommunication network, and the management platform saves the information of the corresponding relationship. The correspondence may be implemented in the form of a correspondence table in which the identifier of the WSN terminal and the identity of the gateway to which it is assigned are recorded. The corresponding relationship can be used to query the gateway used by a certain WSN terminal to access the telecommunication network, and a gateway in the WSN provides telecommunication network access for which WSN terminals in the WSN.
另夕卜, WSN终端加入 WSN后, 主网关可以变更 WSN终端接入电信 网络所使用的网关。由主网关新指定的网关为该 WSN终端提供电信网络接 入, 原先的网关不再为该 WSN终端提供电信网络接入。  In addition, after the WSN terminal joins the WSN, the primary gateway can change the gateway used by the WSN terminal to access the telecommunication network. The newly designated gateway of the primary gateway provides the TSN terminal with telecommunication network access, and the original gateway no longer provides telecommunication network access for the WSN terminal.
WSN终端离开 WSN时, 主网关和该 WSN终端接入电信网络所使用 的网关可以清除各自保存的该 WSN终端的信息, 主网关和该 WSN终端对 应的网关在 WSN终端离开 WSN后, 不再为该 WSN终端提供电信网络接 入。 When the WSN terminal leaves the WSN, the primary gateway and the WSN terminal access the telecommunication network. The gateway can clear the information of the WSN terminal saved by the WSN terminal, and the gateway corresponding to the WSN terminal does not provide the TSN terminal with the telecommunication network access after the WSN terminal leaves the WSN.
WSN终端加入 WSN前, 可以由管理平台通过客户端或者其他方式在 WSN终端中写入加入 WSN所需要的网络配置参数, 该网络配置参数可以 由管理平台从 WSN终端申请加入的 WSN中的主网关处获得。 WSN终端 加入 WSN时, 向主网关提出加入 WSN的请求, 该请求中包括 WSN终端 的标识等信息, 主网关可以将 WSN终端的信息发送给管理平台。 由主网关 或者管理平台对该 WSN终端进行身份验证, 验证通过后允许该 WSN终端 加入该 WSN,并由主网关为该 WSN终端分配接入电信网络所使用的网关。  Before the WSN terminal joins the WSN, the management platform may write the network configuration parameters required for joining the WSN in the WSN terminal through the client or other manner, and the network configuration parameter may be used by the management platform from the WSN terminal to join the primary gateway in the WSN. Obtained. When the WSN terminal joins the WSN, it submits a request to join the WSN to the primary gateway, where the request includes information such as the identifier of the WSN terminal, and the primary gateway can send the information of the WSN terminal to the management platform. The WSN terminal is authenticated by the primary gateway or the management platform, and the WSN terminal is allowed to join the WSN after the verification is passed, and the WSN terminal is allocated by the primary gateway to the gateway used for accessing the telecommunication network.
电信网络中的管理平台保存有 WSN中的 WSN终端与其被分配的网关 的对应关系。 如果电信网络中的网络单元(如业务平台)准备建立和 WSN 中的 WSN终端的通信,电信网络中的网络单元可以从管理平台获得该 WSN 终端接入电信网所使用的网关的信息 (如网关的地址信息、 标识信息等), 然后通过该网关与该 WSN终端进行通信。  The management platform in the telecommunication network stores the correspondence between the WSN terminal in the WSN and its assigned gateway. If a network element (such as a service platform) in the telecommunication network is ready to establish communication with the WSN terminal in the WSN, the network element in the telecommunication network can obtain information (such as a gateway) of the gateway used by the WSN terminal to access the telecommunication network from the management platform. Address information, identification information, etc.), and then communicate with the WSN terminal through the gateway.
为增加无线传感器网络的可靠性, 主网关和从网关中的无线传感器网 络的配置信息或者其它信息可以在管理平台备份存储。 主网关和从网关可 以将需要备份的数据发送给管理平台并由管理平台存储。  To increase the reliability of the wireless sensor network, configuration information or other information of the wireless sensor network in the primary gateway and the secondary gateway can be backed up and stored on the management platform. The primary and secondary gateways can send data that needs to be backed up to the management platform and stored by the management platform.
在本发明中, 主网关的备份数据包括但不局限于无线传感器网络的配 置信息、 WSN终端和其分配的网关之间的对应关系信息; 无线传感器网络 的配置信息包括无线传感器网络的标识、 网络拓朴信息、从网关和 WSN终 端的信息 (包括标识、 地址等信息)、 网络安全设置信息等; WSN 终端和 其分配的网关之间的对应关系信息用于记录 WSN 终端接入电信网络所对 应的网关。 从网关的备份数据包括但不局限于: 从网关的标识和地址、 通 过该从网关接入的电信网络的 WSN终端的信息等。 无线传感器配置多网关后, 主网关可能会出现故障, 从而导致主网关 不能正常工作。 而由于主网关起着重要的作用, 承担着无线传感器网络管 理的功能, 在主网关不能正常工作时需要及时釆取必要的措施进行弥补。 In the present invention, the backup data of the primary gateway includes, but is not limited to, configuration information of the wireless sensor network, correspondence information between the WSN terminal and its assigned gateway; configuration information of the wireless sensor network includes the identifier of the wireless sensor network, and the network. Topological information, information from the gateway and the WSN terminal (including information such as identification, address, etc.), network security setting information, etc.; correspondence information between the WSN terminal and its assigned gateway is used to record the WSN terminal access to the telecommunications network. Gateway. The backup data of the slave gateway includes but is not limited to: the identity and address of the slave gateway, the information of the WSN terminal of the telecommunications network accessed through the slave gateway, and the like. After the wireless sensor is configured with multiple gateways, the primary gateway may fail, and the primary gateway may not work properly. Since the main gateway plays an important role, it assumes the function of wireless sensor network management. When the main gateway fails to work normally, it needs to take necessary measures to make up for it.
在本发明中, 当主网关不能正常工作时, 由该无线传感器网络中的一 个从网关代替该主网关, 该从网关在无线传感器网络作为主网关进行工作。  In the present invention, when the primary gateway is not functioning properly, the secondary gateway is replaced by a secondary gateway in the wireless sensor network, and the secondary gateway operates as a primary gateway in the wireless sensor network.
在本发明中, 可以由管理平台指定替换主网关的从网关。 管理平台确 定主网关不能正常工作后, 确定该无线传感器网络中的替换主网关的从网 关, 并通知该从网关作为主网关在该无线传感器网络进行工作。  In the present invention, the slave gateway that replaces the master gateway can be specified by the management platform. After the management platform determines that the primary gateway is not working properly, it determines the secondary gateway of the replacement primary gateway in the wireless sensor network, and notifies the secondary gateway to operate as the primary gateway in the wireless sensor network.
为了实现主网关出现故障时, 管理平台能够及时获取到主网关的故障 信息并釆取有关处理措施, 管理平台可以通过以下的方式确定主网关能否 正常工作:  In order to implement the failure of the primary gateway, the management platform can obtain the fault information of the primary gateway in time and take relevant measures. The management platform can determine whether the primary gateway can work normally by the following methods:
1、 主网关出现故障但仍能与电信网络的管理平台进行通信的情况下, 由主网关将故障信息通知管理平台;  1. When the primary gateway fails but can still communicate with the management platform of the telecommunication network, the primary gateway notifies the management platform of the fault information;
2、 管理平台对无线传感器网络的网关进行定期检测, 检测到主网关出 现故障;  2. The management platform periodically checks the gateway of the wireless sensor network, and detects that the primary gateway is faulty;
3、 从网关检测到主网关出现故障, 将故障信息通知管理平台;  3. The gateway detects that the primary gateway is faulty, and notifies the management platform of the fault information;
4、 WSN 终端检测到主网关出现故障, 并将故障信息通知 (如通过自 身接入的从网关进行通知)管理平台。  4. The WSN terminal detects that the primary gateway has failed, and notifies the fault information (such as notification from the gateway through its own access) management platform.
管理平台确定无线传感器网络中的主网关不能正常工作后, 可以从该 无线传感器网络的多个从网关中选择一个从网关, 由该从网关代替主网关, 该从网关作为新的主网关在无线传感器网中进行工作。  After the management platform determines that the primary gateway in the wireless sensor network is not working properly, a slave gateway may be selected from the multiple slave gateways of the wireless sensor network, and the slave gateway replaces the master gateway, and the slave gateway acts as a new master gateway in the wireless Work in the sensor network.
在本发明中, 除由管理平台指定新的主网关外, 也可以由从网关协商 确定新的主网关。 主网关可以预先设置无线传感器中的从网关的后备网关 优先级, 并将各从网关的后备网关优先级的信息发送给各从网关及管理平 台。 主网关不能正常工作时, 从网关或管理平台检测到主网关的异常时, 将主网关的故障信息通知后备网关优先级为最高的从网关, 后备网关优先 级为最高的从网关替代当前的不能正常工作的主网关。 In the present invention, in addition to specifying a new primary gateway by the management platform, a new primary gateway may also be negotiated by the secondary gateway. The primary gateway may preset the backup gateway priority of the secondary gateway in the wireless sensor, and send the information of the backup gateway priority of each slave gateway to each slave gateway and the management platform. When the primary gateway is not working properly, when the gateway or management platform detects an abnormality of the primary gateway, The fault information of the primary gateway is notified to the secondary gateway with the highest priority of the backup gateway, and the secondary gateway with the highest priority of the backup gateway replaces the current active gateway that cannot work normally.
为实现从网关作为新的主网关在无线传感器网络中能够正常工作, 该 从网关需要获得并使用该无线传感器网络的配置信息、 WSN终端和其分配 的网关之间的对应关系信息等。 这些信息由原来的主网关在管理平台进行 了备份, 可以由管理平台将主网关的备份信息提供给该从网关, 该从网关 使用备份信息在无线传感器网络中作为新的主网关进行工作。  In order to realize that the slave gateway functions as a new master gateway in the wireless sensor network, the slave gateway needs to obtain and use configuration information of the wireless sensor network, correspondence information between the WSN terminal and its assigned gateway, and the like. The information is backed up by the original master gateway on the management platform, and the backup information of the master gateway can be provided by the management platform to the slave gateway, and the slave gateway works as a new master gateway in the wireless sensor network using the backup information.
从网关代替原来的主网关后, 该从网关在无线传感器网络内发送广播 消息, 将主网关变更的消息通知 WSN终端和其它的从网关。  After the gateway replaces the original primary gateway, the secondary gateway sends a broadcast message in the wireless sensor network, and notifies the WSN terminal and other secondary gateways of the change of the primary gateway.
新的主网关根据获得的 WSN 终端和其分配的网关之间的对应关系信 息判断是否存在通过原来的主网关接入电信网络的 WSN终端; 如果存在, 新的主网关为的 WSN终端重新分配接入电信网络所使用的网关, 的 WSN 终端通过新分配的网关接入电信网络。  The new primary gateway determines, according to the correspondence information between the obtained WSN terminal and its assigned gateway, whether there is a WSN terminal accessing the telecommunication network through the original primary gateway; if yes, the new primary gateway reassigns the WSN terminal The WSN terminal that enters the gateway used by the telecommunication network accesses the telecommunication network through the newly assigned gateway.
在 WSN和电信网络结合时, 在 WSN中配置多个网关, 多个网关釆用 主从的工作模式, 由多个网关分别为 WSN中的 WSN终端提供电信网络的 接入, 并且当主网关出现故障导致不能正常工作时, 可以由其中的一个从 网关代替该主网关, 由该从网关作为主网关在无线传感器网络中进行工作, 使无线传感器网络及其有关业务可以正常运行, 提高了配置多个网关的无 线传感器网络的可靠性。  When the WSN and the telecommunication network are combined, multiple gateways are configured in the WSN, and multiple gateways use the master-slave working mode, and multiple gateways respectively provide access to the telecommunication network for the WSN terminal in the WSN, and when the primary gateway fails When the system fails to work normally, the master gateway can be replaced by one of the slave gateways, and the slave gateway acts as a master gateway in the wireless sensor network, so that the wireless sensor network and related services can operate normally, and the configuration is improved. The reliability of the gateway's wireless sensor network.
本发明的 WSN是由一组无线传感器节点设备, 比如 WSN终端以自组 织方式或者预配置方式组成的无线网络; WSN终端间以近距离无线通信技 术进行通信。 WSN 通常部署在几米至几百米的区域范围内, 其中, WSN 终端通常是由电池供电, 具有较低的功耗和成本。 近距离通信技术一般釆 用 Zigbee和 IEEE 802.15.4技术。  The WSN of the present invention is a wireless network composed of a group of wireless sensor node devices, such as WSN terminals, in an ad hoc manner or a pre-configured manner; WSN terminals communicate by short-range wireless communication technology. WSNs are typically deployed in areas ranging from a few meters to a few hundred meters, where WSN terminals are typically battery powered, with lower power and cost. Near field communication technology generally uses Zigbee and IEEE 802.15.4 technology.
WSN与电信网络结合, 是指将 WSN与电信网络相连接, 利用电信网 络对 WSN及其提供的业务进行监控、 管理及完成业务的承载与合作实施, 并通过电信网络扩展 WSN 所提供的业务。 电信网络包括移动通信网络、 xDSL、 FTTx、 卫星通信等多种通信网络。 The combination of WSN and telecommunication network refers to connecting WSN with telecommunication network and utilizing telecommunication network. The network monitors, manages and completes the service bearer and cooperation implementation of the WSN and the services it provides, and extends the services provided by the WSN through the telecommunication network. The telecommunication network includes various communication networks such as mobile communication networks, xDSL, FTTx, and satellite communications.
本实施例中, WSN同电信网络相结合时, 图 1为 WSN中存在多个网 关时的网络架构示意图, 如图 1所示, 图 1 中, 以交叉线填充的阴影部分 表示多个 WSN终端,以点填充的阴影部分表示多个 WSN终端所在的区域。 图 1中, WSN由多个 WSN终端和多个网关组成, 多个 WSN终端和多个 网关可以按照 WSN的相关技术标准组建无线传感器网络,可用于组建 WSN 的近距离通信技术包括 Zigbee技术、 IEEE 802.15.4标准等。 WSN通过多 个网关连接到电信网络, 和电信网络中管理平台等建立通信。 其中, 多个 网关之间釆用主从网关的工作模式。  In this embodiment, when the WSN is combined with the telecommunication network, FIG. 1 is a schematic diagram of a network architecture when multiple gateways exist in the WSN. As shown in FIG. 1, in FIG. 1, the shaded portions filled with cross lines indicate multiple WSN terminals. The shaded portion filled with dots indicates the area where multiple WSN terminals are located. In Figure 1, the WSN is composed of multiple WSN terminals and multiple gateways. Multiple WSN terminals and multiple gateways can be used to set up wireless sensor networks according to the relevant technical standards of WSN. The short-range communication technologies that can be used to form WSNs include Zigbee technology and IEEE. 802.15.4 standard, etc. The WSN connects to the telecommunication network through multiple gateways, and establishes communication with the management platform in the telecommunication network. Among them, the working mode of the master-slave gateway is used between multiple gateways.
为了实现 WSN和电信网络的连接, WSN通过多个网关接入电信网络, 并经由电信网络与接入网、 核心网、 业务平台、 管理平台相连。 WSN终端 通过多个网关连接至电信网络。 WSN终端为构成 WSN的传感器节点, 通 过一跳或多跳与网关连接。 WSN终端负责釆集并上传数据, 以及接收并执 行命令。 组成 WSN的 WSN终端少则几个多则几百个, WSN终端间可才艮 据需要以星形、 树形或网状(mesh )方式组网, 其中某些 WSN终端或具有 较强的组网和数据转发能力。  In order to realize the connection between the WSN and the telecommunication network, the WSN accesses the telecommunication network through multiple gateways, and is connected to the access network, the core network, the service platform, and the management platform via the telecommunication network. The WSN terminal is connected to the telecommunications network through a plurality of gateways. The WSN terminal is a sensor node constituting the WSN and is connected to the gateway by one or more hops. The WSN terminal is responsible for collecting and uploading data, as well as receiving and executing commands. The WSN terminals that make up the WSN are as few as a few hundreds, and the WSN terminals can be networked in a star, tree or mesh manner, some of which have strong groups. Network and data forwarding capabilities.
网关负责连接 WSN和电信网络, 主要完成协议转换、地址映射和数据 转发等功能, 也可以集成安全和计费等功能。 网关支持的功能可以包括: 支持传感器网络内部数据协同和汇聚; 支持以第二代(2G, 2nd Generation ) 移动通信、 第三代(3G, 3rd Generation )移动通信、 xDSL、 FTTx、 宽带 无线接入、 卫星 /微波等远距离通信接入方式的一种或多种, 将汇聚的数据 传输到通信对端; 支持业务平台和远程管理服务器对网关的设备认证和用 户认证; 支持业务平台和远程管理服务器对网关的参数和软件配置; 支持 用户认证和业务安全、 设备管理安全机制。 The gateway is responsible for connecting the WSN and the telecommunication network, and mainly performs functions such as protocol conversion, address mapping, and data forwarding, and can also integrate functions such as security and billing. The functions supported by the gateway can include: Support internal data coordination and aggregation in the sensor network; Support second-generation (2G, 2nd Generation) mobile communication, third-generation (3G, 3rd Generation) mobile communication, xDSL, FTTx, broadband wireless access And one or more of long-distance communication access methods such as satellite/microwave, transmitting aggregated data to the communication peer; supporting service platform and remote management server to device authentication and user authentication of the gateway; supporting service platform and remote management Server-to-gateway parameters and software configuration; support User authentication and business security, device management security mechanisms.
业务平台是电信网络中运行和管理与 WSN相结合的业务的功能实体, 负责整合各个服务提供商提供的业务, 并将其提供给终端用户, 同时对终 端用户使用业务的情况进行管理。 业务平台会根据不同业务的需要, 协同 电信网络中其他功能实体完成整个业务流程,例如认证、授权及计费 ( AAA, Authentication Authorization and Accounting )月良务器。 业务平台还可以与远 程服务器连接, 直接对业务进行更新。  The service platform is a functional entity that operates and manages the services combined with the WSN in the telecommunication network. It is responsible for integrating the services provided by the various service providers and providing them to the end users, and managing the use of the services by the terminal users. The service platform cooperates with other functional entities in the telecommunication network to complete the entire business process according to the needs of different services, such as AAA, Authentication Authorization and Accounting (AAA). The business platform can also be connected to a remote server to update the business directly.
管理平台是对 WSN实施管理功能的实体,管理平台可以由管理服务器 组成, 管理服务器通过电信网络对 WSN实施管理功能。  The management platform is an entity that implements management functions for the WSN. The management platform can be composed of a management server that implements management functions for the WSN through the telecommunication network.
基于上述网络结构, 进一步对本发明无线传感器网络如何在主网关不 能正常工作时如何接入电信网络进行详细说明。  Based on the above network structure, how the wireless sensor network of the present invention accesses the telecommunication network when the primary gateway fails to operate normally is further described in detail.
实施例一  Embodiment 1
本发明实施例一中, 多个网关中首先由一个网关创建 WSN, 该网关创 建 WSN后, 将 WSN的信息 (如 WSN的网络标识等 )发送给管理平台, 管理平台保存该 WSN以及该网关的信息。 在本发明中, 具有创建 WSN能 力的网关为主网关, 其他网关为从网关。 本示例针对的是 WSN初始建立的 场景, 即由主网关负责其余从网关的接入等处理。 需要说明的是, 在 WSN 建立后, 当有新网关加入时, 对该新加入的网关进行更新的方式, 与本示 例所记载的新网关加入方式基本相同, 本发明不再赘述其实现细节。  In the first embodiment of the present invention, a WSN is first created by a gateway in a plurality of gateways. After the WSN is created, the gateway sends the information of the WSN (such as the network identifier of the WSN) to the management platform, and the management platform saves the WSN and the gateway. information. In the present invention, the gateway having the WSN capability is the master gateway, and the other gateways are the slave gateways. This example is for the scenario where the WSN is initially established, that is, the primary gateway is responsible for the rest of the access from the gateway. It should be noted that, after the WSN is established, when a new gateway is added, the manner of updating the newly added gateway is basically the same as the new gateway joining manner described in this example, and the implementation details are not repeatedly described in the present invention.
图 2为本发明实施例一中 WSN配置多网关的流程图, 如图 2所示, 本 发明 WSN配置多网关的流程具体包括以下步骤:  2 is a flowchart of configuring a multi-gateway for a WSN according to Embodiment 1 of the present invention. As shown in FIG. 2, the process of configuring a multi-gateway by the WSN of the present invention specifically includes the following steps:
步骤 201 , 其他网关(即除了主网关之外的其他网关, 也称新网关)通 过电信网络提供的通信与管理平台连接, 并进行注册。  Step 201: Other gateways (ie, other gateways other than the primary gateway, also called new gateways) are connected to the management platform through the communication provided by the telecommunication network, and are registered.
这里, 新网关在申请加入的 WSN区域并安装后, 可以通过电信网络同 管理平台建立通信连接, 向管理平台发送注册请求。 管理平台可以通过新 网关的身份标识进行身份认证, 确定新网关身份的真实性。 在管理平台中 预先保存有新网关的信息, 该信息包括新网关的网络接入能力参数、 安装 的位置等。 Here, after the new gateway is installed and added to the WSN area, the new gateway can establish a communication connection with the management platform through the telecommunication network, and send a registration request to the management platform. Management platform can pass new The identity of the gateway is authenticated to determine the authenticity of the new gateway identity. The information of the new gateway is pre-stored in the management platform, and the information includes the network access capability parameter of the new gateway, the location of the installation, and the like.
步骤 202、 管理平台通知 WSN 中的主网关, 有新网关申请加入到该 WSN。  Step 202: The management platform notifies the primary gateway in the WSN that a new gateway applies to join the WSN.
这里, 管理平台根据新网关准备安装的位置确定新网关准备加入的 WSN, 然后通知该 WSN中的主网关有新网关申请加入到该 WSN。 管理平 台可以同时将该新网关的信息发送给主网关, 该新网关的信息可以包括: 新网关在电信网络中的地址、 网络接入能力参数等。  Here, the management platform determines the WSN that the new gateway is ready to join according to the location where the new gateway is to be installed, and then notifies the primary gateway in the WSN that a new gateway applies to join the WSN. The management platform can simultaneously send the information of the new gateway to the primary gateway. The information of the new gateway may include: an address of the new gateway in the telecommunication network, a network access capability parameter, and the like.
步骤 203, 主网关将加入到该 WSN所需要的网络配置参数发送给注册 的新网关。  Step 203: The primary gateway sends the network configuration parameters required to join the WSN to the registered new gateway.
这里,主网关将该新网关加入到该 WSN需要的网络配置参数发送给管 理平台, 然后由管理平台将该网络配置参数、 以及主网关在电信网络中的 地址发送给该新网关。 这里的网络配置参数包括主网关在 WSN中的地址、 初始主密钥等。  Here, the primary gateway adds the network configuration parameters required by the new gateway to the WSN to the management platform, and then the management platform sends the network configuration parameters and the address of the primary gateway in the telecommunication network to the new gateway. The network configuration parameters here include the address of the primary gateway in the WSN, the initial master key, and so on.
步骤 204, 新网关使用获得的网络配置参数加入到 WSN。  Step 204: The new gateway joins the WSN by using the obtained network configuration parameters.
这里, 新网关获得 WSN的网络配置参数后, 在该 WSN的覆盖区域内 进行信道扫描, 然后向主网关发送关联请求(Association Request ) 帧, 请 求加入到该 WSN。 新网关和主网关根据初始主密钥进行协商, 确定网络密 钥、链接密钥和地址等。 新网关记录自身在该 WSN中的地址和相关路由信 息, 主网关记录新网关在该 WSN中的地址和新网关的信息。  Here, after obtaining the network configuration parameter of the WSN, the new gateway performs channel scanning in the coverage area of the WSN, and then sends an association request (Association Request) frame to the primary gateway, requesting to join the WSN. The new gateway and the primary gateway negotiate based on the initial master key to determine the network key, link key, and address. The new gateway records its own address and related routing information in the WSN, and the primary gateway records the address of the new gateway in the WSN and the information of the new gateway.
网关加入 WSN后, 网关之间可以通过该 WSN进行通信和交换相关数 据等。 网关在电信网络中的地址可以釆用 IP地址, 由于网关之间保存有对 方的在电信网络中的 IP地址, 双方也可以通过电信网络进行通信。  After the gateway joins the WSN, the gateway can communicate and exchange related data through the WSN. The address of the gateway in the telecommunication network can use the IP address. Since the gateway stores the IP address of the opposite party in the telecommunication network, the two parties can also communicate through the telecommunication network.
通过上述实施例一, WSN中可以配置多个网关。 在 Zigbee网络中, 为了使 WSN终端可以加入 WSN, WSN终端需要 先从管理平台获得加入 WSN所需的网络配置参数, 网络配置参数包括: 要 加入的 WSN的初始主密钥和主网关的地址。 WSN终端加入 WSN时, 主 网关验证 WSN终端的初始主密钥的真实性,从而验证该 WSN终端的身份。 如果该 WSN终端的初始主密钥是正确的, 则允许该 WSN终端加入 WSN, WSN终端和主网关之间可以基于初始主密钥进行协商, 确定加入该 WSN 所需要的链接密钥、 网络密钥和地址等, 从而实现 WSN终端成功的加入该 WSN。 不具备网络配置参数的 WSN终端申请加入 WSN时, 因不能提供初 始主密钥或者初始主密钥不是正确的密钥,主网关则会拒绝该 WSN终端加 入该 WSN。 Through the foregoing embodiment 1, multiple gateways can be configured in the WSN. In the Zigbee network, in order to enable the WSN terminal to join the WSN, the WSN terminal needs to obtain the network configuration parameters required to join the WSN from the management platform. The network configuration parameters include: the initial master key of the WSN to be joined and the address of the primary gateway. When the WSN terminal joins the WSN, the primary gateway verifies the authenticity of the initial master key of the WSN terminal, thereby verifying the identity of the WSN terminal. If the initial master key of the WSN terminal is correct, the WSN terminal is allowed to join the WSN, and the WSN terminal and the primary gateway can negotiate based on the initial master key to determine the link key and network secret required to join the WSN. The key and the address, etc., thereby enabling the WSN terminal to successfully join the WSN. When a WSN terminal that does not have the network configuration parameter applies to join the WSN, the primary gateway rejects the WSN terminal to join the WSN because the initial master key cannot be provided or the initial master key is not the correct key.
这里, WSN终端生产商在生产 WSN终端时, 并没有在 WSN终端中 写入 WSN的网络配置参数, 可以在 WSN终端在投入使用前由管理平台通 过客户端或者其他方式在 WSN终端中写入其要加入的 WSN的网络配置参 数。 管理平台可以从主网关获得加入该 WSN所需要的网络配置参数。  Here, when the WSN terminal manufacturer produces the WSN terminal, the network configuration parameter of the WSN is not written in the WSN terminal, and the WSN terminal can write the WSN terminal through the client or other means before the WSN terminal is put into use. The network configuration parameters of the WSN to be joined. The management platform can obtain the network configuration parameters required to join the WSN from the primary gateway.
需要指出的是, 管理平台可以通过两种方式获得 WSN 的网络配置参 数。 第一种方式为: 管理平台向主网关发送获取 WSN网络配置参数请求, 主网关提供 WSN终端加入该 WSN所需要的网络配置参数。第二种方式为: WSN创建后, 主网关将加入该 WSN所需要的网络配置参数, 提供给管理 平台, 并在管理平台进行保存。  It should be noted that the management platform can obtain the network configuration parameters of the WSN in two ways. The first mode is: the management platform sends a request for acquiring the WSN network configuration parameter to the primary gateway, and the primary gateway provides the network configuration parameter required by the WSN terminal to join the WSN. The second way is as follows: After the WSN is created, the primary gateway will add the network configuration parameters required by the WSN to the management platform and save it on the management platform.
实施例二  Embodiment 2
本发明实施例二描述了釆用 Zigbee技术组建的 WSN中, WSN终端加 入 WSN, 以及釆用主、 从网关的工作模式时, 为该 WSN终端分配网关的 过程。 图 3为本发明实施例二中 WSN终端加入 WSN以及釆用主从网关的 工作模式时为 WSN终端分配网关的流程图, 如图 3所示, 为 WSN终端分 配网关具体包括以下步骤: 步骤 301 , 在 WSN终端中写入 WSN终端申请加入的 WSN的网络配 置参数。 The second embodiment of the present invention describes a process of allocating a gateway for the WSN terminal when the WSN terminal joins the WSN and uses the working mode of the master and slave gateways in the WSN formed by the Zigbee technology. FIG. 3 is a flowchart of allocating a gateway to a WSN terminal when the WSN terminal joins the WSN and uses the working mode of the master-slave gateway according to the second embodiment of the present invention. As shown in FIG. 3, the step of allocating the gateway for the WSN terminal includes the following steps: Step 301: Write, in the WSN terminal, a network configuration parameter of the WSN to which the WSN terminal applies for joining.
步骤 302、 WSN终端使用 WSN的网络配置参数申请加入到 WSN, 主 网关对 WSN终端进行验证, 如果验证通过, 则执行步骤 303; 如果验证失 败, 则执行步骤 304。  Step 302: The WSN terminal applies to the WSN by using the network configuration parameter of the WSN, and the primary gateway verifies the WSN terminal. If the verification succeeds, step 303 is performed; if the verification fails, step 304 is performed.
本步骤中, WSN终端被放置在准备加入的 WSN所覆盖的区域。 WSN 终端开机启动后, WSN终端可以先在设定的信道上进行网络扫描, 确定要 加入的 WSN。 网络扫描可以通过在信道上发送信标请求( Beacon Request ) 帧, 在该信道上的 WSN中的设备收到 Beacon Request后, 如果允许有新的 WSN终端加入该 WSN, 将会回应 Beacon帧, 该 Beacon帧包含了发送该 帧的 WSN终端的地址信息, 以及是否允许其他 WSN终端以其子节点的方 式加入。 WSN终端将收到的 Beacon帧的信息保存在自身的关联表( neighbor table ) 中。  In this step, the WSN terminal is placed in the area covered by the WSN to be joined. After the WSN terminal is powered on, the WSN terminal can perform network scanning on the set channel to determine the WSN to be added. The network scan can send a Beacon Request frame on the channel. After the device in the WSN on the channel receives the Beacon Request, if a new WSN terminal is allowed to join the WSN, it will respond to the Beacon frame. The Beacon frame contains the address information of the WSN terminal that sent the frame, and whether other WSN terminals are allowed to join in the manner of their child nodes. The WSN terminal saves the information of the received Beacon frame in its own neighbor table.
这里, WSN终端在关联表中选择合适的父节点, 并向父节点发送关联 请求( Association Request )帧请求加入 WSN。 处于 WSN的父节点的 WSN 终端收到加入 WSN的请求后, 通知 WSN的主网关有新的 WSN终端请求 加入 WSN。  Here, the WSN terminal selects an appropriate parent node in the association table, and sends an Association Request frame request to the parent node to join the WSN. After receiving the request to join the WSN, the WSN terminal at the parent node of the WSN notifies the WSN of the primary gateway that a new WSN terminal requests to join the WSN.
WSN的主网关对 WSN终端进行验证, 验证方式可以按照 Zigbee规范 中节点设备加入到网络的方式,主网关判断 WSN终端中的初始主密钥的真 实性。 如果 WSN终端验证通过, 则执行步骤 303的操作; 如果 WSN终端 验证失败, 则进行步骤 304的操作。  The WSN's primary gateway authenticates the WSN terminal. The authentication mode can be based on the way the node device joins the network in the Zigbee specification. The primary gateway determines the authenticity of the initial master key in the WSN terminal. If the WSN terminal passes the verification, the operation of step 303 is performed; if the WSN terminal fails to verify, the operation of step 304 is performed.
步骤 303, WSN终端验证通过后, 与主网关进行通信协商确定链接密 钥和网络密钥, 主网关在节点管理表中添加该 WSN终端的信息, WSN终 端的父节点设备在自身的相邻表中保存该 WSN终端的信息, WSN终端在 自身的相邻表中保存父节点和主网关的信息。 至此, WSN 终端成功加入 WSN。 Step 303: After the WSN terminal passes the verification, the communication protocol negotiates with the primary gateway to determine the link key and the network key, and the primary gateway adds the information of the WSN terminal in the node management table, and the parent node device of the WSN terminal is in its neighbor table. The information of the WSN terminal is saved, and the WSN terminal saves the information of the parent node and the master gateway in its own neighbor table. At this point, the WSN terminal successfully joined WSN.
步骤 304, WSN终端认证不通过,主网关拒绝该 WSN终端加入 WSN„ 步骤 305 , 主网关为该 WSN终端指定接入电信网络所使用的网关。 这里,主网关根据网关分配的相关原则确定该 WSN终端接入电信网络 所使用的网关。主网关可以将该 WSN终端的信息和通信连接配置信息发送 给所分配的网关, 主网关将所分配的网关的信息和通信连接配置信息发送 给该 WSN终端。  Step 304: The WSN terminal fails to pass the authentication, and the primary gateway rejects the WSN terminal to join the WSN. Step 305: The primary gateway specifies the gateway used by the WSN terminal to access the telecommunication network. Here, the primary gateway determines the WSN according to the relevant principle of the gateway allocation. The terminal accesses the gateway used by the telecommunication network. The main gateway may send the information and communication connection configuration information of the WSN terminal to the allocated gateway, and the main gateway sends the information of the allocated gateway and the communication connection configuration information to the WSN terminal. .
通信连接配置信息是该指定的网关和该 WSN 终端之间建立通信连接 所需要的链接密钥,该指定的网关和该 WSN终端之间通过该链接密钥建立 安全的通信连接。  The communication connection configuration information is a link key required for establishing a communication connection between the designated gateway and the WSN terminal, and the designated gateway establishes a secure communication connection with the WSN terminal through the link key.
步骤 306, WSN的主网关通知管理平台该 WSN终端已经加入到 WSN, 并将 WSN终端与其被分配的网关的对应关系发送给管理平台。  Step 306: The master gateway of the WSN notifies the management platform that the WSN terminal has joined the WSN, and sends the correspondence between the WSN terminal and its assigned gateway to the management platform.
在本步骤中, 管理平台保存该 WSN终端的相关信息, 包括 WSN终端 的标识、 WSN终端与其所属的 WSN的对应关系、 WSN终端与其被分配的 网关的对应关系; 管理平台还将 WSN终端的相关信息发送给业务平台, 业 务平台配置 WSN终端的相关数据, 启用 WSN终端所支持的业务。  In this step, the management platform saves related information of the WSN terminal, including the identifier of the WSN terminal, the correspondence between the WSN terminal and the WSN to which the WSN terminal belongs, and the correspondence between the WSN terminal and the gateway to which it is assigned. The management platform also associates the WSN terminal. The information is sent to the service platform, and the service platform configures related data of the WSN terminal, and enables the services supported by the WSN terminal.
可见, 通过上述过程, WSN 终端中写入网络配置参数并加入指定的 WSN,并且 WSN的主网关指定了该 WSN终端接入电信网络所使用的网关, 使该 WSN终端能够通过网关向业务平台上报数据。  It can be seen that, through the above process, the WSN terminal writes the network configuration parameter and joins the designated WSN, and the WSN's main gateway specifies the gateway used by the WSN terminal to access the telecommunication network, so that the WSN terminal can report to the service platform through the gateway. data.
需要说明的是, 为了记录 WSN中的 WSN终端接入电信网络所使用的 网关等信息, 主网关保存有 WSN中的 WSN终端与其被分配的网关的对应 关系。  It should be noted that, in order to record information such as a gateway used by the WSN terminal in the WSN to access the telecommunication network, the main gateway stores the corresponding relationship between the WSN terminal in the WSN and the assigned gateway.
WSN终端加入到 WSN后, 可能存在需要变更 WSN终端接入电信网 络所使用的网关的情况, 例如: 主网关可以为一个 WSN终端选择另外一个 距离该 WSN终端更近的从网关, 从而减少该 WSN终端和从网关间的路由 路径, 达到减少 WSN内的通信复杂度和节能的效果。 此时, 可以由主网关 指定为 WSN终端提供电信网络接入的新网关, 主网关可以将该 WSN终端 的信息和通信连接配置信息发送给新指定的网关, 并将网关变更消息通知 原来为该 WSN终端提供电信网络接入的网关。新指定的网关在该网关中添 加该 WSN终端的配置信息, 原来的网关删除该网关中保存的该 WSN终端 的电信网络接入配置信息。 新指定的网关为该 WSN 终端提供电信网络接 入, 原来的网关不再为该 WSN终端提供电信网络接入。 After the WSN terminal joins the WSN, there may be a situation in which the gateway used by the WSN terminal to access the telecommunication network needs to be changed. For example, the primary gateway may select another slave gateway closer to the WSN terminal for one WSN terminal, thereby reducing the WSN. Routing between the terminal and the slave gateway The path is achieved to reduce the communication complexity and energy saving effect in the WSN. At this time, the main gateway may specify a new gateway for the WSN terminal to provide the telecommunication network access, and the main gateway may send the information and communication connection configuration information of the WSN terminal to the newly designated gateway, and notify the gateway change message that the The WSN terminal provides a gateway for telecommunications network access. The newly designated gateway adds the configuration information of the WSN terminal to the gateway, and the original gateway deletes the telecommunication network access configuration information of the WSN terminal stored in the gateway. The newly designated gateway provides telecommunication network access for the WSN terminal, and the original gateway no longer provides telecommunication network access for the WSN terminal.
加入 WSN的终端在离开 WSN时, 主网关和该 WSN终端接入电信网 络所使用的网关,可以清除各自保存的该 WSN终端的电信网络接入配置信 息, 主网关和该 WSN终端对应的网关, 在 WSN终端离开 WSN后不再为 该 WSN终端提供电信网络接入。  When the terminal that joins the WSN leaves the WSN, the gateway used by the primary gateway and the WSN terminal to access the telecommunication network can clear the telecommunication network access configuration information of the WSN terminal that is saved, the gateway corresponding to the main gateway and the WSN terminal, The WSN terminal is no longer provided with telecommunication network access after leaving the WSN.
在本发明中, 无线传感器网络中的主网关与从网关可以通过电信网络 和管理平台建立通信; 主网关和从网关在管理平台进行数据备份时, 可以 通过通信连接将备份数据发送给管理平台, 管理平台接收并保存备份数据。 主网关和从网关在管理平台进行数据备份后, 如果主网关和从网关的需要 备份的数据发生了更新, 主网关和从网关可以将更新后的数据发送给管理 平台。  In the present invention, the primary gateway and the secondary gateway in the wireless sensor network can establish communication through the telecommunication network and the management platform; when the primary gateway and the secondary gateway perform data backup on the management platform, the backup data can be sent to the management platform through the communication connection. The management platform receives and saves backup data. After the primary gateway and the secondary gateway perform data backup on the management platform, if the data that needs to be backed up by the primary gateway and the secondary gateway is updated, the primary gateway and the secondary gateway can send the updated data to the management platform.
实施例三  Embodiment 3
图 4为本发明实施例三中 WSN中的从网关代替主网关的流程图,如图 4所示,当无线传感器网络中的主网关不能正常工作后的替换主网关的处理 过程具体包括以下步骤:  4 is a flowchart of a slave gateway replacing a master gateway in a WSN according to Embodiment 3 of the present invention. As shown in FIG. 4, the process of replacing a master gateway after the master gateway in the wireless sensor network fails to work normally includes the following steps. :
步骤 401 , 确定无线传感器网络中的主网关不能正常工作。  Step 401: Determine that the primary gateway in the wireless sensor network is not working properly.
主网关不能正常工作一般是由出现故障造成的, 并且, 主网关能否 正常工作一般是由管理平台来确定, 具体的, 管理平台可以通过以下的方 式确定主网关能否正常工作:: 1、 主网关出现故障但仍能与电信网络的管理平台进行通信的情况下, 由主网关将故障信息通知管理平台; The main gateway cannot work normally because it is caused by a fault. Moreover, whether the main gateway works normally is determined by the management platform. Specifically, the management platform can determine whether the main gateway works normally by the following means: 1. When the primary gateway fails but can still communicate with the management platform of the telecommunication network, the primary gateway notifies the management platform of the fault information;
2、 管理平台对无线传感器网络的网关进行定期检测, 检测到主网关出 现故障;  2. The management platform periodically checks the gateway of the wireless sensor network, and detects that the primary gateway is faulty;
3、 从网关检测到主网关出现故障, 将故障信息通知管理平台; 3. The gateway detects that the primary gateway is faulty, and notifies the management platform of the fault information;
4、 WSN 终端检测到主网关出现故障, 并将故障信息通知 (如通过自 身接入的从网关进行通知)管理平台。 4. The WSN terminal detects that the primary gateway has failed, and notifies the fault information (such as notification from the gateway through its own access) management platform.
步骤 402, 管理平台确定该无线传感器网络中的一个从网关代替主网 关。  Step 402: The management platform determines that one slave gateway in the wireless sensor network replaces the primary gateway.
管理平台保存有该无线传感器网络中的从网关的信息, 管理平台可以 根据从网关设备所支持的功能、 性能以及当前的负载等因素选择替代主网 关的从网关。 管理平台确定代替主网关的从网关后, 通过电信网络和该从 网关建立通信, 通知该从网关代替该无线传感器网络中的主网关, 由该从 网关作为新的主网关在无线传感器网络进行工作。  The management platform maintains information about the slave gateways in the wireless sensor network, and the management platform can select a slave gateway that replaces the master gateway according to factors such as functions, performance, and current load supported by the gateway device. After the management platform determines to replace the slave gateway of the master gateway, establish communication with the slave gateway through the telecommunication network, and notify the slave gateway to replace the master gateway in the wireless sensor network, and the slave gateway works as a new master gateway in the wireless sensor network. .
步骤 403 ,管理平台将原来的主网关的备份数据提供给所确定的从网关 (即新的主网关)。  Step 403: The management platform provides the backup data of the original primary gateway to the determined secondary gateway (ie, the new primary gateway).
该从网关作为新的主网关在无线传感器网络进行工作, 需要获取无线 传感器网络的配置信息等, 并使用这些配置信息进行无线传感器网络的管 理, 这些信息由原来的主网关在管理平台进行了备份, 可以由管理平台将 备份数据提供给该从网关。  The slave gateway works as a new master gateway in the wireless sensor network, needs to obtain configuration information of the wireless sensor network, and uses the configuration information to manage the wireless sensor network, and the information is backed up by the original master gateway on the management platform. The backup data can be provided to the slave gateway by the management platform.
管理平台和从网关之间通过电信网络建立通信连接, 管理平台可以通 过该通信连接将原来的主网关的备份数据发送给从网关, 从网关接收并保 存备份数据。  The management platform and the slave gateway establish a communication connection through the telecommunication network, and the management platform can send the backup data of the original master gateway to the slave gateway through the communication connection, and receive and save the backup data from the gateway.
步骤 404 , 新的主网关将主网关变更信息通知无线传感器网络中的 WSN终端和其他网关。 新的主网关可以在无线传感器网络内通过广播消息通知无线传感器网 络中的 WSN终端和其他网关, WSN终端和其他网关收到主网关变更通知 消息后, 可以创建和新的主网关的通信路径, 从而可以和新的主网关能够 正常进行通信。 Step 404: The new primary gateway notifies the WSN terminal and other gateways in the wireless sensor network of the primary gateway change information. The new primary gateway can notify the WSN terminal and other gateways in the wireless sensor network through broadcast messages in the wireless sensor network. After receiving the primary gateway change notification message, the WSN terminal and other gateways can create a communication path with the new primary gateway. Thereby, it is possible to communicate normally with the new primary gateway.
步骤 405,新的主网关判断是否存在通过原来的主网关接入电信网络的 WSN终端, 如果存在, 执行步骤 406中的处理过程; 如果不存在, 替换主 网关的处理流程结束。  Step 405: The new primary gateway determines whether there is a WSN terminal accessing the telecommunication network through the original primary gateway. If yes, the process in step 406 is performed; if not, the process of replacing the primary gateway ends.
新的主网关可以根据获得的原来的主网关的备份数据获得无线传感器 网络中的 WSN终端与其分配的网关的对应关系,识别出是否存在通过原来 的主网关接入电信网络的 WSN终端。  The new primary gateway can obtain the correspondence between the WSN terminal in the wireless sensor network and its assigned gateway according to the obtained backup data of the original primary gateway, and identify whether there is a WSN terminal accessing the telecommunication network through the original primary gateway.
步骤 406, 新的主网关为通过原来的主网关接入电信网络的 WSN终端 指定新的网关。  Step 406: The new primary gateway specifies a new gateway for the WSN terminal accessing the telecommunication network through the original primary gateway.
新的主网关为 WSN 终端指定新的接入电信网络的网关釆用本发明实 施例二步骤 305中描述的方式, 在此不再赘述。  The new primary gateway assigns a new access to the telecommunications network to the WSN terminal. The method described in the second step 305 of the second embodiment of the present invention is not described herein.
通过上述的处理流程实现在无线传感器网络中的主网关不能正常工作 时由其中的一个从网关代替该主网关, 从而使无线传感器网络可以继续正 常工作。  Through the above processing flow, when the primary gateway in the wireless sensor network fails to work normally, one of the slave gateways replaces the primary gateway, so that the wireless sensor network can continue to work normally.
在本发明中, 主网关不能正常工作时, 确定新的主网关也可以釆用从 网关协商的方式。 无线传感器网络中的主网关需要预先设置该无线传感器 网络中的从网关的后备网关优先级; 从网关的后备网关优先级表示主网关 出现故障时, 从网关作为新的主网关工作的选择排序; 主网关出现故障时, 首先选择后备网关优先级为最高的从网关作为新的主网关。 从网关的后备 网关优先级的设置方式可以为: 从网关作为路由节点加入到无线传感器网 络时, 主网关设置该从网关的后备网关优先级, 将该从网关的后备网关优 先级的设置信息发送给其它从网关和管理平台, 将其它网关的后备网关优 先级的设置信息发送给该从网关。 通过该方式, 主网关、 从网关和管理平 台掌握无线传感器网络中的各从网关的后备网关优先级。 In the present invention, when the primary gateway is not working properly, it is determined that the new primary gateway can also use the manner negotiated from the gateway. The primary gateway in the wireless sensor network needs to preset the backup gateway priority of the secondary gateway in the wireless sensor network; when the backup gateway priority of the gateway indicates that the primary gateway fails, the gateway is selected as the new primary gateway to work; When the primary gateway fails, the slave gateway with the highest priority of the backup gateway is selected as the new primary gateway. The priority of the backup gateway of the slave gateway may be set as follows: When the gateway joins the wireless sensor network as the routing node, the primary gateway sets the priority of the backup gateway of the slave gateway, and sends the setting information of the backup gateway priority of the slave gateway. For other slave gateways and management platforms, the backup gateways of other gateways are preferred. The setup information of the predecessor is sent to the slave gateway. In this way, the primary gateway, the secondary gateway, and the management platform grasp the priority of the backup gateway of each slave gateway in the wireless sensor network.
实施例四  Embodiment 4
图 5为本发明实施例四中 WSN中的从网关代替主网关的流程图,如图 5所示,本实施例的无线传感器网络中的主网关不能正常工作后的替换主网 关的处理过程具体包括以下步骤:  FIG. 5 is a flowchart of a slave gateway replacing a master gateway in a WSN according to Embodiment 4 of the present invention. As shown in FIG. 5, a process of replacing a master gateway after the master gateway in the wireless sensor network in this embodiment cannot work normally is specific. Includes the following steps:
步骤 501 ,从网关或管理平台确定无线传感器网络中的主网关已经不能 正常工作;  Step 501: Determine, from the gateway or the management platform, that the primary gateway in the wireless sensor network is unable to work normally;
主网关不能正常工作一般是由出现故障或异常造成, 可以通过以下的 方式确定主网关能否正常工作:  If the primary gateway fails to work normally, it is usually caused by a fault or abnormality. You can determine whether the primary gateway works normally by the following methods:
1、 主网关出现故障但仍能与电信网络的管理平台进行通信的情况下, 由主网关将故障信息通知管理平台或从网关;  1. When the primary gateway fails but can still communicate with the management platform of the telecommunication network, the primary gateway notifies the management platform or the secondary gateway of the fault information;
2、 管理平台或从网关对无线传感器网络的网关进行定期检测, 检测到 主网关出现故障;  2. The management platform or the gateway detects the gateway of the wireless sensor network periodically, and detects that the primary gateway is faulty;
3、 从网关检测到主网关出现故障, 将故障信息通知管理平台; 3. The gateway detects that the primary gateway is faulty, and notifies the management platform of the fault information;
4、 WSN 终端检测到主网关出现故障, 并将故障信息通知 (如通过自 身接入的从网关进行通知 )管理平台或从网关。 4. The WSN terminal detects that the primary gateway is faulty, and notifies the fault information (such as notification from the gateway through its own access) to the management platform or the slave gateway.
步骤 502,从网关或管理平台将主网关出现故障的信息通知后备网关优 先级为最高的从网关;  Step 502: The gateway or the management platform notifies the failure information of the primary gateway that the backup gateway has the highest priority as the secondary gateway;
从网关或者管理平台确定主网关出现故障后, 根据其保存的从网关的 后备网关优先级的设置信息, 确定后备网关优先级为最高的从网关, 然后 将主网关出现故障的信息通知给该从网关。  After the gateway or the management platform determines that the primary gateway is faulty, it determines the secondary gateway with the highest priority of the backup gateway according to the setting information of the backup gateway priority of the gateway, and then notifies the secondary gateway of the failure of the primary gateway. Gateway.
步骤 503 ,后备网关优先级为最高的从网关通知其它从网关和管理平台 自身可以代替现在的主网关。  Step 503: The slave gateway has the highest priority, and the slave gateway notifies the other slave gateways and the management platform that the master gateway can be replaced by the current master gateway.
步骤 504, 管理平台将原来的主网关的备份数据提供给新的主网关; 步骤 505 , 新的主网关将主网关变更信息通知无线传感器网络中的 WSN终端和其他网关; Step 504: The management platform provides backup data of the original primary gateway to the new primary gateway. Step 505: The new primary gateway notifies the WSN terminal and other gateways in the wireless sensor network of the primary gateway change information;
步骤 506,新的主网关判断是否存在通过原来的主网关接入电信网络的 WSN终端, 如果存在, 执行步骤 507中的处理过程; 如果不存在, 替换主 网关的处理流程结束。  Step 506: The new primary gateway determines whether there is a WSN terminal that accesses the telecommunication network through the original primary gateway. If yes, the process in step 507 is performed; if not, the process of replacing the primary gateway ends.
步骤 507 , 新的主网关为通过原来的主网关接入电信网络的 WSN终端 指定新的网关。  Step 507: The new primary gateway specifies a new gateway for the WSN terminal accessing the telecommunication network through the original primary gateway.
通过实施例四中的上述流程, 实现了在无线传感器网络中的主网关不 能正常工作时由其中的一个从网关代替该主网关, 从而使无线传感器网络 可以继续正常工作。  Through the above process in the fourth embodiment, it is realized that one of the slave gateways replaces the master gateway when the master gateway in the wireless sensor network fails to work normally, so that the wireless sensor network can continue to work normally.
下面再对以上涉及到的通过 Zigbee技术组建 WSN和对 WSN进行管理 的相关内容, 说明如下:  The following is the following related content related to the establishment of WSN and management of WSN through Zigbee technology.
ZigBee是一种新兴的短距离、 低速率、 低成本、 低功耗的无线网络技 术。 其釆用直接序列扩频(DSSS , Direct Sequence Spread Spectrum )技术, 工作频率为 868MHz、 915MHz或 2.4GHz。 ZigBee网络中有 3种类型的节 点: ZigBee协调点、 ZigBee路由节点和 ZigBee终端节点。  ZigBee is an emerging short-range, low-rate, low-cost, low-power wireless network technology. It uses Direct Sequence Spread Spectrum (DSSS) technology and operates at 868MHz, 915MHz or 2.4GHz. There are three types of nodes in the ZigBee network: ZigBee coordination point, ZigBee routing node and ZigBee terminal node.
其中, ZigBee协调点在 IEEE 802.15.4中也称为个域网(PAN, Personal Area Network )协调点 (ZC, ZigBee Coordinator ), 在 WSN中可以作为汇 聚节点。 ZigBee协调点必须是全功能设备(FFD, Full-Function Device ), 一个 ZigBee网络只有一个 ZigBee协调点,它往往比网络中其他节点的功能 更强大, 是整个网络的主控节点。 它负责发起建立新的网络、 设定网络参 数、 管理网络中的节点以及存储网络中节点信息等, 网络形成后也可以执 行路由器的功能。  Among them, the ZigBee coordination point is also called the Personal Area Network (PAN) coordination point (ZC, ZigBee Coordinator) in IEEE 802.15.4, and can be used as a convergence node in the WSN. The ZigBee coordination point must be a Full-Function Device (FFD). A ZigBee network has only one ZigBee coordination point. It is often more powerful than other nodes in the network and is the master node of the entire network. It is responsible for initiating the establishment of new networks, setting network parameters, managing nodes in the network, and storing node information in the network. After the network is formed, it can also perform the functions of the router.
ZigBee路由节点 (ZR, ZigBee Router )也必须是全功能设备。 ZigBee 路由节点可以参与路由发现、 消息转发, 通过连接别的节点来扩展网络的 覆盖范围等。 此外, ZigBee路由节点还可以在它的个人操作空间 (POS, Personal Operating Space ) 中充当普通协调点, IEEE 802.15.4称为协调点。 普通协调点与 ZigBee协调点不同, 它仍然受 ZigBee协调点的控制。 The ZigBee Routing Node (ZR, ZigBee Router) must also be a fully functional device. ZigBee routing nodes can participate in route discovery, message forwarding, and extend the network by connecting other nodes. Coverage, etc. In addition, the ZigBee routing node can also act as a common coordination point in its Personal Operating Space (POS), and IEEE 802.15.4 is called a coordination point. The normal coordination point is different from the ZigBee coordination point, which is still controlled by the ZigBee coordination point.
ZigBee终端节点 (ZE, ZigBee EndDevice ) 可以是全功能设备或者精 简功能设备 ( RFD , Reduced-Function Device ) , 它通过 ZigBee协凋点或者 ZigBee 路由节点连接到网络, 但不允许其他任何节点通过它加入网络, ZigBee终端节点能够以非常低的功率运行。  The ZigBee EndNode (ZE, ZigBee EndDevice) can be a full-featured device or a Reduced-Function Device (RFD), which connects to the network through ZigBee co-nodes or ZigBee routing nodes, but does not allow any other node to join through it. Network, ZigBee endpoints can operate at very low power.
本发明中, 主网关 (或负责 WSN创建的网关)作为 Zigbee网络中的 Zigbee协调点, 负责 WSN的组建。 WSN终端可以作为 Zigbee路由节点、 或者 Zigbee终端节点加入 WSN; 从网关(或除主网关之外的其他网关)作 为 Zigbee路由节点加入 WSN„网关和 WSN终端需要支持 Zigbee通信技术。  In the present invention, the primary gateway (or the gateway responsible for the WSN) acts as a Zigbee coordination point in the Zigbee network and is responsible for the formation of the WSN. The WSN terminal can join the WSN as a Zigbee routing node or a Zigbee terminal node; the slave gateway (or other gateways other than the primary gateway) joins the WSN as a Zigbee routing node. The gateway and WSN terminal need to support Zigbee communication technology.
另外, 为了实现 Zigbee网络的安全, 需要对 WSN中的通信进行加密, Zigbee 网络中的加密运算, 釆用先进加密标准算法 (AES , Advanced Encryption Standard ), 釆用的对称密钥长度为 128位。 Zigbee网络中使用的 密钥主要包括: 主密钥 (Master Key ), 链接密钥 (Link Key )和网络密钥 ( Network Key )。 其中, 主密钥是执行对称密钥建立协议过程中使用的一 个共享密钥, 是两个设备之间长期安全的基础, 并可用于生成链接密钥; 链接密钥在一个 PAN网中, 是两个设备之间共享的密钥, 用于两个设备之 间的安全通信; 网络密钥为一个 PAN网络中共享的密钥, 用于广播通信的 安全。  In addition, in order to realize the security of the Zigbee network, it is necessary to encrypt the communication in the WSN, the encryption operation in the Zigbee network, and the advanced encryption standard algorithm (AES, Advanced Encryption Standard), and the symmetric key length used is 128 bits. The keys used in the Zigbee network mainly include: Master Key, Link Key, and Network Key. The master key is a shared key used in the process of performing a symmetric key establishment protocol, and is a long-term security basis between two devices, and can be used to generate a link key; the link key is in a PAN network, A key shared between two devices for secure communication between two devices; a network key is a shared key in a PAN network for the security of broadcast communication.
为实现 Zigbee网络的安全和密钥的管理等, Zigbee网络中存在信任中 心。 信任中心是在网络中分配安全钥匙的一种信任设备, 它允许设备加入 网络, 并分配密钥, 因而确保设备之间端到端的安全性。 在釆用安全机制 的网络中, 网络协调者可成为信任中心。 信任中心提供以下三种功能: ( 1 )信任管理: 任务是负责对加入网络的设备验证。 ( 2 ) 网络管理: 任务是负责获取和分配网络钥匙给设备。 In order to realize the security and key management of the Zigbee network, there is a trust center in the Zigbee network. A trust center is a type of trusted device that distributes security keys across the network. It allows devices to join the network and assign keys, thus ensuring end-to-end security between devices. In a network that uses security mechanisms, the network coordinator can become a trust center. The Trust Center provides the following three functions: (1) Trust Management: The task is responsible for verifying the device joining the network. (2) Network Management: The task is to obtain and assign network keys to the device.
( 3 )配置管理: 任务是对其管理的设备绑定应用程序, 在两个设备之 间实现端到端的安全传输。  (3) Configuration management: The task is to bind the application to the device it manages, and achieve end-to-end secure transmission between the two devices.
为了实现信任管理, 设备需要从信任中心接收初始主密钥。 为了实现 网络管理的目的, 设备应接收初始的网络密钥, 并且只能从信任中心获得 网络密钥的更新。 为了实现网络配置, 设备需要从信任中心接收主密钥或 链路密钥, 以建立两个设备间的端对端安全链路。  In order to implement trust management, the device needs to receive the initial master key from the trust center. For network management purposes, the device should receive the initial network key and can only obtain updates to the network key from the Trust Center. In order to implement network configuration, the device needs to receive a master key or a link key from the trust center to establish an end-to-end secure link between the two devices.
除了初始的主密钥, 附加的链路密钥、 主密钥、 网络密钥只能够釆用 安全的方式从信任中心获得。 信任中心应当根据某一策略周期性地更新网 络密钥, 并将新的网络密钥传送给每个设备。  In addition to the initial master key, the additional link key, master key, and network key can only be obtained from the trust center in a secure manner. The trust center should periodically update the network key according to a policy and pass the new network key to each device.
本发明中, 由主网关作为信任中心进行网络的安全管理。 网关和电信 网中的管理平台和其他网络单元之间可以通过网关的身份标识实现对网关 的身份认证和安全通信。  In the present invention, the primary gateway acts as a trust center for network security management. The identity authentication and secure communication of the gateway can be implemented between the management platform and other network elements in the gateway and the telecommunication network through the identity of the gateway.
本发明中, 通过 WSN的网络标识识别某个 WSN。 主网关创建 WSN 后, 可以由主网关或者由管理平台确定该 WSN的网络标识, 管理平台中记 录 WSN的包括网络标识和网络位置的相关信息。 由此, 管理平台可以根据 一个给定的位置判断该位置是否存在由该管理平台管理的 WSN, 如果存在 WSN可以获得在该位置的 WSN的标识, 从而确定在该位置的 WSN。  In the present invention, a WSN is identified by the network identifier of the WSN. After the primary gateway creates the WSN, the network identifier of the WSN may be determined by the primary gateway or by the management platform. The information about the network identifier and the network location of the WSN is recorded in the management platform. Thus, the management platform can determine whether there is a WSN managed by the management platform according to a given location. If there is a WSN, the WSN of the location can be obtained, thereby determining the WSN at the location.
本发明的无线传感器网络接入电信网络的系统, 具体可结合前述图 1 所示的系统而理解。 需要说明的是, 本发明的无线传感器网络接入电信网 络的系统正是在现有的结合网络的基础上, 通过更新相应网元的功能而实 现的, 对网络中网元连接结构等并未改变。 图 6为本发明无线传感器网络 接入电信网络的系统的组成结构示意图, 如图 6所示, 本发明无线传感器 网络接入电信网络的系统包括确定单元 60和代替单元 61 , 其中,  The system for accessing the telecommunication network of the wireless sensor network of the present invention can be specifically understood in conjunction with the system shown in FIG. 1 above. It should be noted that the system for accessing the telecommunication network of the wireless sensor network of the present invention is realized by updating the function of the corresponding network element on the basis of the existing combined network, and the connection structure of the network element in the network is not change. 6 is a schematic structural diagram of a system for accessing a telecommunication network of a wireless sensor network according to the present invention. As shown in FIG. 6, the system for accessing a telecommunication network of the wireless sensor network of the present invention includes a determining unit 60 and a replacing unit 61, wherein
确定单元 60, 用于确定主网关不能正常工作时, 触发代替单元; 代替单元 61 , 用于将所述 WSN中的一个从网关作为主网关, 代替原 主网关进行工作。 The determining unit 60 is configured to: when it is determined that the primary gateway is not working properly, trigger the replacement unit; The replacing unit 61 is configured to operate one of the WSNs from the gateway as a primary gateway instead of the original primary gateway.
上述确定单元 60设于所述管理平台中, 在确定 WSN中的主网关不能 正常工作后, 进一步确定所述 WSN中的替换主网关的从网关, 并由上述代 理单元 61通知所确定的从网关作为主网关, 代替原主网关进行工作。  The determining unit 60 is disposed in the management platform, and after determining that the primary gateway in the WSN is not working properly, further determining a secondary gateway of the replacement primary gateway in the WSN, and notifying the determined secondary gateway by the proxy unit 61. As the primary gateway, it works instead of the original primary gateway.
上述代替单元 61设于从网关中;上述确定单元 60确定 WSN中的主网 关不能正常工作后, 上述代替单元 61进一步通过 WSN中的从网关协商确 定出新的主网关, 代替原主网关进行工作。  The replacement unit 61 is disposed in the slave gateway. After the determining unit 60 determines that the master gateway in the WSN is not working properly, the replacing unit 61 further determines, by the slave gateway in the WSN, a new master gateway to work instead of the original master gateway.
本发明的无线传感器网络接入电信网络的系统还包括设置单元 (未图 示)和发送单元(未图示), 其中,  The system for accessing a telecommunications network of the wireless sensor network of the present invention further includes a setting unit (not shown) and a transmitting unit (not shown), wherein
设置单元, 用于预先在 WSN中确定主网关的后备网关, 并为所述后备 网关设置优先级;  a setting unit, configured to determine a backup gateway of the primary gateway in the WSN in advance, and set a priority for the backup gateway;
发送单元, 用于将所述后备网关优先级的信息发送给各从网关及所述 管理平台;  a sending unit, configured to send information about the priority of the backup gateway to each slave gateway and the management platform;
上述代替单元 61设于从网关或管理平台中;  The above replacement unit 61 is provided in the slave gateway or the management platform;
上述确定单元 60确定主网关不能正常工作时, 上述代替单元 61进一 步用于将主网关的故障信息通知后备网关优先级为最高的后备网关, 由所 述优先级为最高的后备网关代替原主网关进行工作。  When the determining unit 60 determines that the primary gateway is not working properly, the replacing unit 61 is further configured to notify the backup gateway with the highest priority of the backup gateway, and replace the original gateway with the highest priority backup gateway. jobs.
所述管理平台中存储有主网关的备份信息;  The management platform stores backup information of the primary gateway;
上述代替单元 61将从网关代替原主网关时, 所述管理平台将所存储的 主网关的备份信息发送给代替原主网关的从网关, 所述代替原主网关的从 网关使用原主网关的备份信息在 WSN进行工作。  When the replacing unit 61 replaces the original primary gateway from the gateway, the management platform sends the stored backup information of the primary gateway to the secondary gateway replacing the original primary gateway, and the secondary gateway replacing the original primary gateway uses the backup information of the original primary gateway at the WSN. working.
本发明的无线传感器网络接入电信网络的系统还包括广播单元(未图 示), 用于在所述代替单元将从网关代替原主网关后, 在所述 WSN中发送 广播消息, 将新主网关的信息通知 WSN终端和 WSN的其余从网关。 本发明的无线传感器网络接入电信网络的系统, 所更新的网元的功能 及信息交互方式, 可参见前述实施例一至实施例四的相关描述而理解。 The system for accessing a telecommunication network of the wireless sensor network of the present invention further includes a broadcasting unit (not shown) for transmitting a broadcast message in the WSN after the replacement unit replaces the original primary gateway from the gateway, and the new primary gateway is The information informs the WSN terminal and the rest of the WSN from the gateway. The system for accessing the telecommunication network of the wireless sensor network of the present invention, the function of the updated network element and the information interaction manner can be understood by referring to the related descriptions of the first embodiment to the fourth embodiment.
以上所述, 仅为本发明的较佳实施例而已, 并非用于限定本发明的保 护范围。  The above is only the preferred embodiment of the present invention and is not intended to limit the scope of the present invention.

Claims

权利要求书 Claim
1、 一种无线传感器网络接入电信网络的方法, 所述 WSN中设有 WSN 终端和两个以上的 WSN网关,所述两个以上的 WSN网关中设置有主网关; 所述电信网络中设置有管理平台; 其特征在于, 所述方法还包括:  A method for a wireless sensor network to access a telecommunication network, wherein the WSN is provided with a WSN terminal and two or more WSN gateways, and the two or more WSN gateways are provided with a main gateway; There is a management platform; and the method further includes:
所述主网关不能正常工作时, 将所述 WSN 中的一个从网关作为主网 关, 代替原主网关进行工作。  When the primary gateway fails to work normally, one of the WSNs is used as a primary gateway instead of the original primary gateway.
2、 根据权利要求 1所述的方法, 其特征在于, 所述将所述 WSN中的 一个从网关作为主网关, 代替原主网关进行工作, 为:  2. The method according to claim 1, wherein the one of the WSNs is used as a primary gateway instead of the original primary gateway, and is:
所述代替原主网关的从网关由所述管理平台指定, 由该从网关代替原 主网关进行工作。  The slave gateway replacing the original primary gateway is designated by the management platform, and the slave gateway works in place of the original master gateway.
3、 根据权利要求 2所述的方法, 其特征在于, 管理平台指定代替原主 网关的从网关, 为:  3. The method according to claim 2, wherein the management platform specifies a slave gateway that replaces the original primary gateway, and is:
所述管理平台确定 WSN中的主网关不能正常工作后,进一步确定所述 WSN中的替换主网关的从网关, 并通知所确定的从网关作为主网关, 代替 原主网关进行工作。  After the management platform determines that the primary gateway in the WSN is not working properly, the slave gateway of the replacement primary gateway in the WSN is further determined, and the determined secondary gateway is notified as the primary gateway to work instead of the original primary gateway.
4、 根据权利要求 1所述的方法, 其特征在于, 所述将所述 WSN中的 一个从网关作为主网关, 代替原主网关进行工作, 为:  The method according to claim 1, wherein the one of the WSNs acts as a master gateway instead of the original master gateway, and is:
WSN中的从网关协商确定出新的主网关, 代替原主网关进行工作。 The slave gateway in the WSN negotiates to determine a new master gateway to work in place of the original master gateway.
5、 根据权利要求 4所述的方法, 其特征在于, 所述将所述 WSN中的 一个从网关作为主网关, 代替原主网关进行工作, 为: The method according to claim 4, wherein the one of the WSNs acts as a master gateway instead of the original master gateway, and is:
预先在 WSN 中确定主网关的后备网关, 并为所述后备网关设置优先 级, 并将所述后备网关优先级的信息发送给各从网关及所述管理平台; 所述主网关不能正常工作时, 从网关或管理平台将主网关的故障信息 通知后备网关优先级为最高的后备网关, 由所述优先级为最高的后备网关 代替原主网关进行工作。 Determining a backup gateway of the primary gateway in the WSN, and setting a priority for the backup gateway, and sending the information of the backup gateway priority to each slave gateway and the management platform; The gateway or the management platform notifies the failure gateway of the primary gateway to the backup gateway with the highest priority of the backup gateway, and the backup gateway with the highest priority replaces the original primary gateway.
6、 根据权利要求 1至 5任一项所述的方法, 其特征在于, 所述方法还 包括: The method according to any one of claims 1 to 5, wherein the method further comprises:
所述管理平台中存储有主网关的备份信息;  The management platform stores backup information of the primary gateway;
所述从网关代替原主网关时, 所述管理平台将所存储的主网关的备份 信息发送给代替原主网关的从网关, 所述代替原主网关的从网关使用原主 网关的备份信息在 WSN进行工作。  When the slave gateway replaces the original master gateway, the management platform sends the stored backup information of the master gateway to the slave gateway replacing the original master gateway, and the slave gateway replacing the original master gateway uses the backup information of the original master gateway to work in the WSN.
7、 根据权利要求 1至 5任一项所述的方法, 其特征在于, 所述方法还 包括:  The method according to any one of claims 1 to 5, wherein the method further comprises:
从网关代替原主网关后, 在所述 WSN中发送广播消息, 将新主网关的 信息通知 WSN终端和 WSN的其余从网关。  After the gateway replaces the original primary gateway, a broadcast message is sent in the WSN, and the information of the new primary gateway is notified to the WSN terminal and the remaining secondary gateways of the WSN.
8、 根据权利要求 6所述的方法, 其特征在于, 所述管理平台中存储有 从网关的备份信息;  The method according to claim 6, wherein the management platform stores backup information of the slave gateway;
所述主网关的备份信息包括 WSN的配置信息、 WSN终端和为 WSN 终端分配的网关之间的对应关系信息; 所述 WSN的配置信息包括 WSN的 标识、 网络拓朴信息、从网关信息、 WSN终端的信息和网络安全设置信息; 所述从网关的备份信息包括从网关信息、 通过从网关接入的电信网络的 WSN终端的信息;其中,所述从网关信息包括从网关标识信息和地址信息, 所述 WSN终端的信息包括 WSN终端标识信息和地址信息。  The backup information of the primary gateway includes configuration information of the WSN, correspondence information between the WSN terminal and the gateway allocated for the WSN terminal, and the configuration information of the WSN includes the identifier of the WSN, the network topology information, the slave gateway information, and the WSN. Information of the terminal and network security setting information; the backup information of the slave gateway includes information from the gateway information, the WSN terminal of the telecommunication network accessed through the gateway; wherein the slave gateway information includes the slave gateway identification information and the address information The information of the WSN terminal includes WSN terminal identification information and address information.
9、 根据权利要求 8所述的方法, 其特征在于, 所述方法还包括: 新主网关根据所获得的 WSN终端和为 WSN终端分配的网关之间的对 应关系信息确定存在通过原主网关接入电信网络的 WSN终端时,为所述通 过原主网关接入电信网络的 WSN终端重新分配接入电信网络的网关。  The method according to claim 8, wherein the method further comprises: determining, by the new primary gateway, that the existing primary gateway is accessed according to the correspondence information between the obtained WSN terminal and the gateway allocated for the WSN terminal When the WSN terminal of the telecommunication network re-allocates the gateway accessing the telecommunication network for the WSN terminal accessing the telecommunication network through the original primary gateway.
10、一种无线传感器网络接入电信网络的系统,所述 WSN中设有 WSN 终端和两个以上的 WSN网关,所述两个以上的 WSN网关中设置有主网关; 所述电信网络中设置有管理平台; 其特征在于, 所述系统包括确定单元和 代替单元, 其中, A system for accessing a telecommunication network by a wireless sensor network, wherein the WSN is provided with a WSN terminal and two or more WSN gateways, and the two or more WSN gateways are provided with a main gateway; a management platform; wherein the system includes a determining unit and Substitute unit, where
确定单元, 用于确定主网关不能正常工作时, 触发代替单元; 代替单元, 用于将所述 WSN中的一个从网关作为主网关, 代替原主网 关进行工作。  a determining unit, configured to: when the primary gateway is not working properly, trigger a replacement unit; and the replacing unit is configured to use one of the WSNs as a primary gateway instead of the original primary gateway to work.
11、 根据权利要求 10所述的系统, 其特征在于, 所述确定单元设于所 述管理平台中, 在确定 WSN中的主网关不能正常工作后, 进一步确定所述 WSN中的替换主网关的从网关, 并由所述代理单元通知所确定的从网关作 为主网关, 代替原主网关进行工作。  The system according to claim 10, wherein the determining unit is disposed in the management platform, and after determining that the primary gateway in the WSN is not working properly, further determining the replacement primary gateway in the WSN From the gateway, and the proxy unit notifies the determined slave gateway as the master gateway to work instead of the original master gateway.
12、 根据权利要求 10所述的系统, 其特征在于, 所述代替单元设于从 网关中; 所述确定单元确定 WSN中的主网关不能正常工作后, 所述代替单 元进一步通过 WSN中的从网关协商确定出新的主网关,代替原主网关进行 工作。  The system according to claim 10, wherein the replacement unit is provided in the slave gateway; after the determining unit determines that the master gateway in the WSN is not working properly, the substitute unit further passes the slave in the WSN. The gateway negotiates to determine a new primary gateway to work in place of the original primary gateway.
13、 根据权利要求 10所述的系统, 其特征在于, 所述系统还包括设置 单元和发送单元, 其中,  The system according to claim 10, wherein the system further comprises a setting unit and a sending unit, wherein
设置单元, 用于预先在 WSN中确定主网关的后备网关, 并为所述后备 网关设置优先级;  a setting unit, configured to determine a backup gateway of the primary gateway in the WSN in advance, and set a priority for the backup gateway;
发送单元, 用于将所述后备网关优先级的信息发送给各从网关及所述 管理平台;  a sending unit, configured to send information about the priority of the backup gateway to each slave gateway and the management platform;
所述代替单元设于从网关或管理平台中;  The replacement unit is disposed in a slave gateway or a management platform;
所述确定单元确定主网关不能正常工作时, 所述代替单元进一步用于 将主网关的故障信息通知后备网关优先级为最高的后备网关, 由所述优先 级为最高的后备网关代替原主网关进行工作。  When the determining unit determines that the primary gateway is not working properly, the replacing unit is further configured to notify the backup gateway with the highest priority of the backup gateway as the fault information of the primary gateway, and replace the original primary gateway with the backup gateway with the highest priority. jobs.
14、 根据权利要求 10至 13任一项所述的系统, 其特征在于, 所述管 理平台中存储有主网关的备份信息;  The system according to any one of claims 10 to 13, wherein the management platform stores backup information of the primary gateway;
所述代替单元将从网关代替原主网关时, 所述管理平台将所存储的主 网关的备份信息发送给代替原主网关的从网关, 所述代替原主网关的从网 关使用原主网关的备份信息在 WSN进行工作。 When the replacement unit replaces the original primary gateway from the gateway, the management platform will store the stored primary The backup information of the gateway is sent to the slave gateway instead of the original master gateway, and the slave gateway replacing the original master gateway uses the backup information of the original master gateway to work in the WSN.
15、 根据权利要求 10至 13任一项所述的系统, 其特征在于, 所述系 统还包括广播单元, 用于在所述代替单元将从网关代替原主网关后, 在所 述 WSN中发送广播消息, 将新主网关的信息通知 WSN终端和 WSN的其 余从网关。  The system according to any one of claims 10 to 13, wherein the system further comprises a broadcasting unit, configured to send a broadcast in the WSN after the replacement unit replaces the original primary gateway from the gateway. The message informs the WSN terminal and the remaining slave gateways of the WSN of the information of the new primary gateway.
PCT/CN2011/075974 2011-03-18 2011-06-20 Method and system for wireless sensor network connecting to telecommunication network WO2012126208A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201110066941.1A CN102685787B (en) 2011-03-18 Wireless sensor network accesses the method and system of communication network
CN201110066941.1 2011-03-18

Publications (1)

Publication Number Publication Date
WO2012126208A1 true WO2012126208A1 (en) 2012-09-27

Family

ID=46817013

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2011/075974 WO2012126208A1 (en) 2011-03-18 2011-06-20 Method and system for wireless sensor network connecting to telecommunication network

Country Status (1)

Country Link
WO (1) WO2012126208A1 (en)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1531262A (en) * 2003-03-11 2004-09-22 ��Ϊ�������޹�˾ Network communication method for carrying out load division
CN1855900A (en) * 2005-04-26 2006-11-01 横河电机株式会社 Gateway system
CN101076992A (en) * 2004-08-13 2007-11-21 塞特里克斯系统公司 A method and systems for securing remote access to private networks

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1531262A (en) * 2003-03-11 2004-09-22 ��Ϊ�������޹�˾ Network communication method for carrying out load division
CN101076992A (en) * 2004-08-13 2007-11-21 塞特里克斯系统公司 A method and systems for securing remote access to private networks
CN1855900A (en) * 2005-04-26 2006-11-01 横河电机株式会社 Gateway system

Also Published As

Publication number Publication date
CN102685787A (en) 2012-09-19

Similar Documents

Publication Publication Date Title
WO2012065418A1 (en) Method and system for accessing wireless sensor network
Liu et al. Efficient naming, addressing and profile services in Internet-of-Things sensory environments
Olivier et al. SDN based architecture for clustered WSN
WO2011116617A1 (en) Combination network and method for accessing network of wireless sensor network terminal
Athreya et al. Network self-organization in the Internet of Things
WO2011116589A1 (en) Combination network and method for wireless sensor network terminal to join in network
De Poorter et al. Enabling direct connectivity between heterogeneous objects in the internet of things through a network-service-oriented architecture
WO2012126211A1 (en) Method and system for wireless sensor network accessing to telecom network
US20180302290A1 (en) Coap enhancements to enable an autonomic control plane
CN103297256B (en) The management method of a kind of thing network sensing layer node and system
WO2011113262A1 (en) Access method and system for wireless sensor network
WO2012058845A1 (en) Method for processing reported data from wsn terminals, wsn gateway and combination network thereof
WO2011116598A1 (en) Method and system for achieving management of gateway
WO2012051777A1 (en) Access control method and device for wireless sensor network (wsn) to access telecommunication network via multiple gateways
Guo et al. Smart service system (sss): A novel architecture enabling coordination of heterogeneous networking technologies and devices for internet of things
WO2011160413A1 (en) Wireless sensor network terminal addressing method and combined network
CN101599834B (en) Method for identification and deployment and management equipment thereof
Chen et al. CogMesh: cognitive wireless mesh networks
Martinez-Yelmo et al. eHDDP: Enhanced Hybrid Domain Discovery Protocol for network topologies with both wired/wireless and SDN/non-SDN devices
WO2011116588A1 (en) Integrated network and method for wireless sensor network terminal to join in network
CN103458423B (en) The methods, devices and systems of transmitting cognitive stream between isomery cognition wireless network
WO2012126208A1 (en) Method and system for wireless sensor network connecting to telecommunication network
CN102457581B (en) The addressing method of Wireless Sensor Network Terminal and in conjunction with network
Asaamoning et al. A study for a name-based coordination of autonomic IoT functions
Punitha et al. Adoptive parent based framework for zigbee cluster tree networks

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 11861616

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 11861616

Country of ref document: EP

Kind code of ref document: A1