CN104684094A - Automatic time slot management method of wireless sensor network - Google Patents

Automatic time slot management method of wireless sensor network Download PDF

Info

Publication number
CN104684094A
CN104684094A CN201510068509.4A CN201510068509A CN104684094A CN 104684094 A CN104684094 A CN 104684094A CN 201510068509 A CN201510068509 A CN 201510068509A CN 104684094 A CN104684094 A CN 104684094A
Authority
CN
China
Prior art keywords
time slot
slot
point
vehicle detector
wireless vehicle
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201510068509.4A
Other languages
Chinese (zh)
Other versions
CN104684094B (en
Inventor
任俊伟
刘向东
何赐文
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Mai Rui Data (beijing) Co Ltd
Original Assignee
Mai Rui Data (beijing) Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Mai Rui Data (beijing) Co Ltd filed Critical Mai Rui Data (beijing) Co Ltd
Priority to CN201510068509.4A priority Critical patent/CN104684094B/en
Publication of CN104684094A publication Critical patent/CN104684094A/en
Application granted granted Critical
Publication of CN104684094B publication Critical patent/CN104684094B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W24/00Supervisory, monitoring or testing arrangements
    • H04W24/04Arrangements for maintaining operational condition
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W72/00Local resource management
    • H04W72/04Wireless resource allocation
    • H04W72/044Wireless resource allocation based on the type of the allocated resource
    • H04W72/0446Resources in time domain, e.g. slots or frames

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention relates to an automatic time slot management method of a wireless sensor network, which particularly comprises the steps of determining nodes at a next second point, inquiring a node with time slot collision from the nodes at the next second point, judging a free time slot from time slots allowed to be used by the node with the time slot collision, assigning the free time slot to the node with the time slot collision at the next second point, writing an ID (identification) of the node and the free time slot assigned to the node into an integral point synchronization packet of the next second point, and issuing the integral point synchronization packet of the next second point when timing to the next second point. The automatic time slot management method of the wireless sensor network can quickly assign the time slot to the node with the time slot collision in the wireless sensor network quickly and further reduces the probability of data upload delay caused by the time slot collision.

Description

Wireless sensor network manages slot approach automatically
Technical field
The present invention relates to wireless sensor network field, especially a kind of wireless sensor network manages slot approach automatically.
Background technology
Wireless sensor network for vehicle detection mostly is the Star Network be made up of wireless vehicle detector and gateway node, and because laying the impacts such as environment, wireless vehicle detector is directly connected with gateway node or is connected with gateway node by repeater; The method of management time slot conventional at present comprises the following steps:
Steps A: wireless vehicle detector network after on the time slot of Default Value to gateway node uploading data bag/state bag;
Step B: the time slot receiving packet/state bag is reported host computer by gateway node, and report host computer by No. ID of the wireless vehicle detector uploading this packet/state bag; Wherein, namely gateway node receives the time slot of packet/state bag is the current time slot taken of wireless vehicle detector uploading this packet/state bag;
Step C: No. ID of each wireless vehicle detector that this gateway node reports by host computer respectively and time slot shared by it store as a record and show; Each bar record that host computer inspection stores, when finding time slot collision, highlights the record of the conflict time slot that record finds to some extent;
Step D: an optional record highlighted on host computer is that the wireless vehicle detector of the record correspondence selected distributes free timeslot, and issues the ID of this wireless vehicle detector and this free timeslot to gateway node; Described free timeslot refers to: keep in whole time slots of wireless vehicle detector current do not detected by wireless vehicle shared by time slot;
Step e: gateway node receives ID and the free timeslot of the wireless vehicle detector that host computer issues, in time putting the second of the wireless vehicle detector that this ID identifies, issue this ID and this free timeslot, think that the wireless vehicle detector successfully identified for this ID distributes time slot, can start as other wireless vehicle detector distributes time slot.
In above-mentioned time slot management method, whole timing second of wireless sensor network adopts from 0s ~ 29s circulation timing, within each second, point issues an integral point sync packet, point second issuing this integral point sync packet is marked with in each integral point sync packet, the described second until the wireless vehicle detector that this ID identifies issues this ID when putting and this free timeslot is: gateway node inquires about some second of wireless detector corresponding to this ID, puts in the integral point sync packet issued carry this ID and this free timeslot in the second inquired; Wherein, wireless vehicle detector second point numerical value be No. ID remainder divided by 30 gained of this wireless vehicle detector, namely some second of wireless vehicle detector is in 0s ~ 29s, and this wireless vehicle detector receives the integral point sync packet that gateway node issues when self second every puts after networking.
In sum, this time slot management method, in a wireless vehicle detector time slot allocation procedures, the maximum duration that the second of wait wireless vehicle detector puts can reach 30s, and wait for that the second of wireless vehicle detector can not be other wireless vehicle detector distribution time slot during point at gateway node, namely the time slot allocation procedures of each wireless vehicle detector can not parallelly/interspersed carry out, and visible, it is very consuming time that above-mentioned time slot management method distributes time slot.
Summary of the invention
A kind of wireless sensor network manages slot approach automatically, comprises the following steps:
A, the integral point sync packet issued on point current second;
B, the node judged whether on next second point, if had, perform step C; Otherwise, perform step F;
C, inquire about on next second point node in whether have the node of time slot collision, if existed, perform step D; If there is no, then step F is performed;
Whether available free time slot in D, the time slot that judges to have the node of time slot collision to use described in permitting, if had, execution step e; If no, perform step F;
E, be the peer distribution free timeslot having time slot collision on next second point, the ID of this node and the free timeslot distributing to this node write the integral point sync packet of next second point;
When F, timing were put to next second, return steps A.
Further, described node has wireless vehicle detector and repeater; Describedly judge whether that the node on next second point is: judge whether the wireless vehicle detector on next second point; Accordingly,
The node of time slot collision that has on described inquiry next second point is: inquire about the wireless vehicle detector whether having time slot collision in the wireless vehicle detector on next second point;
Described judge whether available free time slot for: to judge in the time slot having the wireless vehicle detector of time slot collision to use described in permitting whether available free time slot;
Described for peer distribution free timeslot and the integral point sync packet writing next second point be: be that the wireless vehicle detector of time slot collision that has on next second point distributes free timeslot, the ID of this wireless vehicle detector and the free timeslot distributing to this wireless vehicle detector write the integral point sync packet of next second point.
Further, the method also comprises:
Gateway node is provided with detector slot table, repeater slot table and cache table; Wherein, described detector slot table comprise Field ID, second point, time slot and access way mark; Described repeater slot table comprise Field ID, second point, time slot; Cache table comprises slot fields; Accordingly,
The state bag that gateway node is uploaded according to the repeater received safeguards repeater slot table and cache table, the state bag preservation & testing device slot table uploaded according to the packet received and wireless vehicle detector and cache table;
After the ID of wireless vehicle detector is write the integral point sync packet of next second point with the free timeslot distributing to this wireless vehicle detector by gateway node, by the described free timeslot write cache table distributing to this wireless vehicle detector;
Gateway node monitors in detector slot table, repeater slot table and cache table the record exceeding setting duration and be not updated, and deletes the record that this monitors.
Further, the state bag that the repeater that described foundation receives is uploaded safeguards that repeater slot table and cache table are specially:
The repeater ID that the state bag that a11, foundation receive carries calculates some second of repeater;
Whether there is this repeater ID carried in the id field of b11, inquiry repeater slot table, if existed, perform step c11, e11; Otherwise, perform steps d 11, e11;
C11, cover the respective field of repeater ID place record that this carries in repeater slot table with this repeater ID carried, some second of repeater calculated, the time slot that receives this state bag;
D11, add in repeater slot table one comprise this repeater ID carried, calculate repeater some second, receive the record of the time slot of this state bag;
E11, determine to exist in cache table to receive the time slot of this state bag, then delete the time slot receiving this state bag in cache table.
Further, the state bag preservation & testing device slot table that the wireless vehicle detector that described foundation receives is uploaded and cache table are specially:
The wireless vehicle detector ID that the state bag that a21, foundation receive carries calculates some second of wireless vehicle detector;
B21, determine the ID whether carrying the repeater forwarding this state bag in the state bag that receives, if had, then upload the access way of the wireless vehicle detector of this state bag for switching; Otherwise the access way uploading the wireless vehicle detector of this state bag is direct-connected;
Whether there is the wireless vehicle detector ID that the state bag that receives carries in the id field of c21, inquiry detector slot table, if existed, perform steps d 21, f21; Otherwise, perform step e21, f21;
D21, the wireless vehicle detector ID carried with the state bag received, some second of wireless vehicle detector calculated, the mark that receives the time slot of this state bag and the access way of this identification cover the respective field of the wireless vehicle detector ID place record that the state bag that receives in detector slot table carries;
E21, in detector slot table, add a record, the point and receive the mark of the time slot of state bag and the access way of this identification second of wireless vehicle detector that this record comprises wireless vehicle detector ID that the state bag that receives carries, calculates;
F21, determine to exist in cache table to receive the time slot of this state bag, then delete the time slot receiving this state bag in cache table.
Further, the packet preservation & testing device slot table received described in and cache table are specially:
The wireless vehicle detector ID that the packet that a22, foundation receive carries calculates some second of wireless vehicle detector;
Whether there is the wireless vehicle detector ID that the packet that receives carries in the id field of b22, inquiry detector slot table, if existed, perform step c22, e22; Otherwise, perform steps d 22, e22;
C22, the wireless vehicle detector ID carried with the packet received, some second of wireless vehicle detector calculated, the time slot that receives this packet cover the respective field of the wireless vehicle detector ID place record that the packet that receives in detector slot table carries;
D22, in detector slot table, add a record, the point and receive the time slot of packet second of wireless vehicle detector that this record comprises wireless vehicle detector ID that the packet that receives carries, calculates;
E22, determine to exist in cache table to receive the time slot of this packet, then delete the time slot receiving this packet in cache table.
Further, judge whether described in that the wireless vehicle detector on next second point is specially:
The second of inquiry detector slot table puts in field whether there is next second point, if existed, thinks the wireless vehicle detector had on next second point; Otherwise point does not have node to think next second.
8, wireless sensor network according to claim 3 manages slot approach automatically, it is characterized in that, the wireless vehicle detector whether described inquiry has time slot collision is specially:
041, the index that in buffer memory detector slot table, next second some place is respectively recorded, gets the index ranked the first in the index of buffer memory;
042, to find in detector slot table get the record of index point; The time slot identical with the time slot in the record found in all the other records of sequential query detector slot table, if found, then stops this inquiring about, and has the node of time slot collision in the node thinking on next second point; Fail to inquire the time slot identical with the time slot in the record found, then perform step 043;
043, identical with the time slot in the described record found in sequential query repeater slot table time slot, if found, then stops this inquiring about, and has the node of time slot collision in the node thinking on next second point; Fail to inquire the time slot identical with the time slot in the described record found, then perform step 044;
044, determine whether the index do not taken out in addition, if had, in the index of not taking of buffer memory, get the index ranked the first, return step 042; If do not have the node of time slot collision in the node no, then thinking on next second point.
Further, the method also comprises: on gateway node, store the first time slot sets and the second time slot sets; Accordingly,
Described judge permit described in have the wireless vehicle detector of time slot collision to use time slot in whether available free time slot is specially:
051, inquire about the access way mark in the detector slot table record having the wireless vehicle detector of time slot collision corresponding on next second point, if direct-connected mark, perform step 052; If switching mark, perform step 053;
052, search and whether there is the first time slot sets and have but the time slot all do not had in detector slot table and in cache table, if existed, think have the node of time slot collision to use described in license time slot in available free time slot; Otherwise, perform step 053;
053, search and whether there is the second time slot sets and have but the time slot all do not had in detector slot table, repeater slot table and cache table, if existed, think have the node of time slot collision to use described in license time slot in available free time slot; Otherwise, think license described in have the node of time slot collision to use time slot in there is no free timeslot.
Based on above-mentioned, wireless sensor network provided by the invention manages slot approach automatically, has the following advantages and feature:
1, by putting as the peer distribution free timeslot having time slot collision on next second point in current second, and to during next second point, the free timeslot of distribution is handed down to the node that this has time slot collision in timing, can fast for wireless sensor network have the peer distribution time slot of time slot collision, and then reduce because time slot collision causes the probability of data upload time delay; And automatically manage time slot, make wireless vehicle detector to arrange work easy, and not easily to make mistakes;
2, preservation & testing device slot table, repeater slot table and cache table, fast as far as possible takies slot synchronization with node is actual, can as early as possible the transfer resource that node discharges be redistributed, use, add utilization ratio of transmission resources, reduce without the assignable probability of free timeslot;
3, the time slot collision of wireless vehicle detector and wireless vehicle detector is solved, and the time slot collision of wireless vehicle detector and repeater, ignore the time slot collision of repeater and repeater, both can respond the time slot collision problem of the large node of Time Slot Occupancy rate faster, too increase utilization ratio of transmission resources;
4, judge that whether time slot is idle according to cache table, detector slot table and repeater slot table, avoid and a free timeslot is distributed to two or more wireless vehicle detector/repeater, and then avoid the new time slot collision of generation.
Accompanying drawing explanation
Fig. 1 is the schematic flow sheet that the embodiment of the present invention one wireless sensor network manages slot approach automatically.
The schematic flow sheet of Fig. 2 to be the embodiment of the present invention two for the wireless sensor network of vehicle detection manage automatically slot approach.
Embodiment
Basic conception of the present invention is: by putting the node having time slot collision determined on next second point in current second, for the peer distribution free timeslot having time slot collision determined, and with the integral point sync packet of next second point, the free timeslot of distribution is handed down to the node that this has time slot collision, namely wait for that the time issued is less than 1s after distributing time slot, and can then be the peer distribution time slot of next second point after issuing, visible, the embodiment of the present invention can fast for wireless sensor network has the peer distribution time slot of time slot collision, and then reduce because time slot collision causes the probability of data upload time delay.
The embodiment of the present invention one wireless sensor network manages the flow process of slot approach as shown in Figure 1 automatically, comprising:
Step 101: gateway node issues the integral point sync packet on point current second;
Here, gateway node, at each second, point issues integral point sync packet, puts the integral point sync packet issued be the integral point sync packet on putting current second in current second.
Step 102: gateway node judges whether the node on next second point, if had, performs step 103; Otherwise, perform step 106.
Here, wireless sensor network timing whole second adopts circulation timing, represents cycle period with N, and namely from 0 ~ (N-1) s circulation timing, then some second of each node is the remainder of ID divided by N gained of this node self;
Receive the integral point sync packet that gateway node issues after node networks when timing was put to himself second, the node on described next second point and second point be the node of next second point.
Step 103: gateway node inquires about the node whether having time slot collision in the node on next second point, if existed, performs step 104; If there is no, then step 106 is performed.
Here, the node of time slot collision that has on next second point refers to: the node on next second point, and this node with coexist the time slot collision of other node on next second point, or with the time slot collision of the node on other second point;
In order to save query time, this inquiry can be terminated inquiring having during the node of time slot collision on next a second point, performing step 104.
Step 104: whether available free time slot in the time slot having the node of time slot collision to use described in gateway node judges to permit; If had, perform step 105; If no, perform step 106.
Step 105: gateway node is the peer distribution free timeslot having time slot collision on next second point, writes the integral point sync packet of next second point by the ID of this node and the free timeslot distributing to this node; Concrete:
Point only there is a situation having the node of time slot collision for next second, or namely the node of time slot collision that has only inquired on next a second point stops the mechanism of inquiring about, an optional free timeslot distributes to the node having time slot collision on this next second point, and the have ID of the node of time slot collision and the free timeslot of this distribution by this on next second point write the integral point sync packet of next second point;
For inquiring two or more situation having the node of time slot collision, then select the first node having time slot collision inquired, or an optional node having a time slot collision, and an optional free timeslot gives this first or optional node having time slot collision, the have ID of the node of time slot collision and the free timeslot of this distribution that this is first or optional write the integral point sync packet of next second point;
For inquiring two or more situation having the node of time slot collision, can also be: be respectively the peer distribution free timeslot having time slot collision partly or entirely inquired, and the ID of these nodes and the free timeslot distributing to it are write the integral point sync packet of next second point one to one.
Step 106: when gateway node timing was put to next second, return step 101.
Now, within next second, point is point current second, and the integral point sync packet of next second point in step 105 is the integral point sync packet on point current second;
Return step 101, issue integral point sync packet, it is synchronous that the node on current second point receives this integral point, can obtain ID that this integral point sync packet carries and free timeslot, that is, the node that the ID that this integral point sync packet is carried identifies can know that gateway node is the time slot that it distributes.
The embodiment of the present invention two manages the flow process of slot approach as shown in Figure 2 automatically for the wireless sensor network of vehicle detection, comprising:
Step 201: gateway node issues the integral point sync packet on point current second;
Step 202: gateway node judges whether the wireless vehicle detector on next second point, if had, performs step 203; Otherwise, perform step 206;
Step 204: gateway node determines the wireless vehicle detector whether having time slot collision in the wireless vehicle detector on next second point; If existed, perform step 205; If there is no, then step 207 is performed;
Whether available free time slot in the time slot having the wireless vehicle detector of time slot collision to use described in step 205, gateway node judge to permit, if had, execution step 206; If no, perform step 207;
Step 206: gateway node is that the wireless vehicle detector of time slot collision that has on next second point distributes free timeslot, writes the integral point sync packet of next second point by the ID of this wireless vehicle detector and the free timeslot distributing to this wireless vehicle detector;
Step 207: when gateway node timing was put to next second, return step 202.
The embodiment of the present invention two also comprises: on gateway node, arrange detector slot table, repeater slot table and cache table in advance, and preservation & testing device slot table, repeater slot table and cache table;
Wherein, described detector slot table comprise Field ID, second point, time slot and access way, the ID of the wireless vehicle detector of corresponding stored access gateway node, second point, time slot and access way mark, access way mark has direct-connected mark and switching mark two kinds, identify the wireless vehicle detector of direct access gateway node respectively and turned the wireless vehicle detector of access gateway node by repeater, here, arrange and be direct-connectedly designated 0, switching is designated 1; Described repeater slot table comprise Field ID, second point, time slot, the ID of the repeater of corresponding stored gateway node, second point and time slot; Cache table comprises slot fields, stores the free timeslot in the integral point sync packet of write next second point;
Here, wireless vehicle detector and repeater are all configured with the time slot that dispatches from the factory when dispatching from the factory, all using the time slot of time slot as self that dispatch from the factory after wireless vehicle detector and repeater network, to gateway node uploading data bag/state bag on the time slot that dispatches from the factory of self, until gateway node is assigned with time slot for it.Here, wireless vehicle detector and repeater are uploads a state bag every fixing duration on the time slot of self, and described fixing duration can be the integral multiple of the cycle period N of whole timing second; First state bag is uploaded at the time slot of self after wireless vehicle detector and repeater network; Wireless vehicle detector often detect vehicle by time at self time slot uploading data bag; Repeater, when receiving packet/state bag that wireless vehicle detector is uploaded, the time slot of wireless vehicle detector uploading this packet/state bag forwards this packet/state bag.Accordingly,
Preservation & testing device slot table, repeater slot table and cache table comprise:
The state bag that gateway node is uploaded according to the repeater received safeguards repeater slot table and cache table, the state bag preservation & testing device slot table uploaded according to the packet received and wireless vehicle detector and cache table;
After the ID of wireless vehicle detector is write the integral point sync packet of next second point with the free timeslot distributing to this wireless vehicle detector by gateway node, by the described free timeslot write cache table distributing to this wireless vehicle detector;
Gateway node monitors in detector slot table, repeater slot table and cache table the record exceeding setting duration and be not updated, and deletes the record that this monitors; Wherein, the value of described setting duration and wireless vehicle detector upload the time interval of state bag, and/or repeater upload state bag the time interval be correlated with, the integral multiple in this time interval can be got, here, wireless vehicle detector and repeater are uploads a state bag every 30s, sets the span of duration as [30s, 300s], preferred 30s, 60s, 90s, 120s, 150s, 300s.
Concrete, the state bag that the repeater that described foundation receives is uploaded safeguards that repeater slot table and cache table are specially:
Step a11: the repeater ID carried according to the state bag received calculates some second of repeater;
Whether there is this repeater ID carried in the id field of step b11, inquiry repeater slot table, if existed, perform step c11, e11; Otherwise, perform steps d 11, e11;
Point second of repeater step c11: the repeater ID carried with this, calculated, the time slot receiving this state bag cover the respective field of repeater ID place record that this carries in repeater slot table;
Steps d 11: add in repeater slot table one comprise this repeater ID carried, calculate repeater some second, receive the record of the time slot of this state bag;
Step e11: determine to there is the time slot receiving this state bag in cache table, then delete the time slot receiving this state bag in cache table, completes this and safeguard.
The state bag preservation & testing device slot table that the wireless vehicle detector that described foundation receives is uploaded and cache table are specially:
Step a21: the wireless vehicle detector ID carried according to the state bag received calculates some second of wireless vehicle detector;
Step b21: determine the ID whether carrying the repeater forwarding this state bag in the state bag received, if had, then assert that the access way uploading the wireless vehicle detector of this state bag is switching; Otherwise, assert that the access way uploading the wireless vehicle detector of this state bag is direct-connected;
Step c21: whether there is the wireless vehicle detector ID that the state bag that receives carries in the id field of inquiry detector slot table, if existed, perform steps d 21, f21; Otherwise, perform step e21, f21;
Steps d 21: the wireless vehicle detector ID carried with the state bag received, some second of wireless vehicle detector calculated, the mark that receives the time slot of this state bag and the access way of this identification cover the respective field of the wireless vehicle detector ID place record that the state bag that receives in detector slot table carries;
Step e21: add a record in detector slot table, the point and receive the mark of the time slot of state bag and the access way of this identification second of wireless vehicle detector that this record comprises wireless vehicle detector ID that the state bag that receives carries, calculates;
Step f21: determine to there is the time slot receiving this state bag in cache table, then delete the time slot receiving this state bag in cache table, completes this and safeguard.
The described packet preservation & testing device slot table that receives and cache table are specially:
Step a22: the wireless vehicle detector ID carried according to the packet received calculates some second of wireless vehicle detector;
Step b22: whether there is the wireless vehicle detector ID that the packet that receives carries in the id field of inquiry detector slot table, if existed, perform step c22, e22; Otherwise, perform steps d 22, e22;
Point second of wireless vehicle detector step c22: the wireless vehicle detector ID carried with the packet received, calculated, the time slot receiving this packet cover the respective field of the wireless vehicle detector ID place record that the packet that receives in detector slot table carries;
Steps d 22: add a record in detector slot table, the point and receive the time slot of packet second of wireless vehicle detector that this record comprises wireless vehicle detector ID that the packet that receives carries, calculates;
Step e22: determine to there is the time slot receiving this packet in cache table, then delete the time slot receiving this packet in cache table, completes this and safeguard.
In the embodiment of the present invention two, any one field value in record is updated all thinks that record is updated.
Accordingly,
In step 201, described in judge whether that the wireless vehicle detector on next second point is specially:
The second of inquiry detector slot table puts in field whether there is next second point, if existed, the wireless vehicle detector of this next second some place record correspondence is the wireless vehicle detector on next second point; Otherwise, think the wireless vehicle detector do not had on next second point.
In step 204, described in determine whether there is time slot collision wireless vehicle detector be specially gateway node and perform following steps:
Step 041: the index that in buffer memory detector slot table, next second some place is respectively recorded, gets the index ranked the first in the index of buffer memory;
Step 042: to find in detector slot table get the record of index point; The time slot identical with the time slot in the record found in all the other records of sequential query detector slot table, if found, then stops this inquiring about, and has the wireless vehicle detector of time slot collision in the wireless vehicle detector thinking on next second point; Fail to inquire the time slot identical with the time slot in the record found, then perform step 043;
Step 043: time slot identical with the time slot in the described record found in sequential query repeater slot table, if found, then stops this inquiring about, and has the wireless vehicle detector of time slot collision in the wireless vehicle detector thinking on next second point; Fail to inquire the time slot identical with the time slot in the described record found, then perform step 044;
Step 044: determine whether the index do not taken out in addition, if had, gets the index ranked the first, returns step 042 in the index of not taking of buffer memory; If do not have the wireless vehicle detector of time slot collision in the wireless vehicle detector no, then thinking on next second point.
Step 205 also comprises: on gateway node, store the first time slot sets and the second time slot sets; Wherein,
Time slot in first time slot sets, permits that the wireless vehicle detector of direct access gateway node uses;
Time slot in second time slot sets, permit that the wireless vehicle detector of being transferred by repeater and repeater are used, further, when not having free timeslot in the first time slot sets, the wireless vehicle detector that the time slot in the second time slot sets also can distribute to direct access gateway node uses; Accordingly,
In step 205, described in judge whether available free time slot be specially gateway node perform following steps:
Step 051: inquire about the access way mark in the detector slot table record having the wireless vehicle detector of time slot collision corresponding on next second point, if direct-connected mark, perform step 052; If switching mark, perform step 053;
Step 052: search and whether there is the first time slot sets and have but the time slot that all do not have in detector slot table and in cache table, if existed, think have the wireless vehicle detector of time slot collision to use described in license time slot in available free time slot; Otherwise, perform step 053;
Step 053: search and whether there is the second time slot sets and have but the time slot all do not had in detector slot table, repeater slot table and cache table, if existed, think have the wireless vehicle detector of time slot collision to use described in license time slot in available free time slot; Otherwise, think license described in have the wireless vehicle detector of time slot collision to use time slot in there is no free timeslot.
Here, adopt the free timeslot in the integral point sync packet of cache table storage write next second point, judge that whether time slot is idle according to cache table, detector slot table or repeater slot table, avoid in the interval before free timeslot being distributed to preservation & testing device slot table after wireless vehicle detector/repeater and corresponding or repeater slot table, the free timeslot this being distributed to wireless vehicle detector/repeater distributes to other wireless vehicle detector/repeater, and then avoids the new time slot collision of generation.
Describedly distribute free timeslot after writing the integral point sync packet of next second point, step 206 also comprises, by the described free timeslot write cache table distributing to this wireless vehicle detector for wireless vehicle detector.
Here, only solve the time slot collision of wireless vehicle detector and wireless vehicle detector, and the time slot collision of wireless vehicle detector and repeater, and have ignored the time slot collision of repeater and repeater, reason is: wireless vehicle detector needs uploading detection data and the state bag of self, Time Slot Occupancy rate is large, and the time slot of repeater is only for uploading the state bag of repeater, each cycle period only needs to upload a bag, Time Slot Occupancy rate is very little, visible, be the time slot collision problem solving the large node of Time Slot Occupancy rate like this and vacate the time, to respond the time slot collision problem of this category node faster, too increase utilization ratio of transmission resources.
The embodiment of the present invention two discloses gateway node and knows and record the wireless vehicle detector accessing it, repeater takies resource, the method of the situations such as access way, but be not limit gateway node must be known by the method and record these contents, also existing gateway node can be adopted to know and record its mode of situation of each node of access and realize, accordingly, the method of the wireless vehicle sensor having time slot collision is judged whether disclosed in the embodiment of the present invention two, also do not limit judging to have the specific implementation of the wireless vehicle sensor of time slot collision to form.
The above, be only preferred embodiment of the present invention, be not intended to limit protection scope of the present invention.

Claims (9)

1. wireless sensor network manages a slot approach automatically, it is characterized in that, comprises the following steps:
A, the integral point sync packet issued on point current second;
B, the node judged whether on next second point, if had, perform step C; Otherwise, perform step F;
C, inquire about on next second point node in whether have the node of time slot collision, if existed, perform step D; If there is no, then step F is performed;
Whether available free time slot in D, the time slot that judges to have the node of time slot collision to use described in permitting, if had, execution step e; If no, perform step F;
E, be the peer distribution free timeslot having time slot collision on next second point, the ID of this node and the free timeslot distributing to this node write the integral point sync packet of next second point;
When F, timing were put to next second, return steps A.
2. wireless sensor network according to claim 1 manages slot approach automatically, it is characterized in that, described node has wireless vehicle detector and repeater; Describedly judge whether that the node on next second point is: judge whether the wireless vehicle detector on next second point; Accordingly,
The node of time slot collision that has on described inquiry next second point is: inquire about the wireless vehicle detector whether having time slot collision in the wireless vehicle detector on next second point;
Described judge whether available free time slot for: to judge in the time slot having the wireless vehicle detector of time slot collision to use described in permitting whether available free time slot;
Described for peer distribution free timeslot and the integral point sync packet writing next second point be: be that the wireless vehicle detector of time slot collision that has on next second point distributes free timeslot, the ID of this wireless vehicle detector and the free timeslot distributing to this wireless vehicle detector write the integral point sync packet of next second point.
3. wireless sensor network according to claim 2 manages slot approach automatically, it is characterized in that, the method also comprises:
Gateway node is provided with detector slot table, repeater slot table and cache table; Wherein, described detector slot table comprise Field ID, second point, time slot and access way mark; Described repeater slot table comprise Field ID, second point, time slot; Cache table comprises slot fields; Accordingly,
The state bag that gateway node is uploaded according to the repeater received safeguards repeater slot table and cache table, the state bag preservation & testing device slot table uploaded according to the packet received and wireless vehicle detector and cache table;
After the ID of wireless vehicle detector is write the integral point sync packet of next second point with the free timeslot distributing to this wireless vehicle detector by gateway node, by the described free timeslot write cache table distributing to this wireless vehicle detector;
Gateway node monitors in detector slot table, repeater slot table and cache table the record exceeding setting duration and be not updated, and deletes the record that this monitors.
4. wireless sensor network according to claim 3 manages slot approach automatically, it is characterized in that, the state bag that the repeater that described foundation receives is uploaded safeguards that repeater slot table and cache table are specially:
The repeater ID that the state bag that a11, foundation receive carries calculates some second of repeater;
Whether there is this repeater ID carried in the id field of b11, inquiry repeater slot table, if existed, perform step c11, e11; Otherwise, perform steps d 11, e11;
C11, cover the respective field of repeater ID place record that this carries in repeater slot table with this repeater ID carried, some second of repeater calculated, the time slot that receives this state bag;
D11, add in repeater slot table one comprise this repeater ID carried, calculate repeater some second, receive the record of the time slot of this state bag;
E11, determine to exist in cache table to receive the time slot of this state bag, then delete the time slot receiving this state bag in cache table.
5. wireless sensor network according to claim 3 manages slot approach automatically, it is characterized in that, the state bag preservation & testing device slot table that the wireless vehicle detector that described foundation receives is uploaded and cache table are specially:
The wireless vehicle detector ID that the state bag that a21, foundation receive carries calculates some second of wireless vehicle detector;
B21, determine the ID whether carrying the repeater forwarding this state bag in the state bag that receives, if had, then upload the access way of the wireless vehicle detector of this state bag for switching; Otherwise the access way uploading the wireless vehicle detector of this state bag is direct-connected;
Whether there is the wireless vehicle detector ID that the state bag that receives carries in the id field of c21, inquiry detector slot table, if existed, perform steps d 21, f21; Otherwise, perform step e21, f21;
D21, the wireless vehicle detector ID carried with the state bag received, some second of wireless vehicle detector calculated, the mark that receives the time slot of this state bag and the access way of this identification cover the respective field of the wireless vehicle detector ID place record that the state bag that receives in detector slot table carries;
E21, in detector slot table, add a record, the point and receive the mark of the time slot of state bag and the access way of this identification second of wireless vehicle detector that this record comprises wireless vehicle detector ID that the state bag that receives carries, calculates;
F21, determine to exist in cache table to receive the time slot of this state bag, then delete the time slot receiving this state bag in cache table.
6. wireless sensor network according to claim 3 manages slot approach automatically, it is characterized in that, described in the packet preservation & testing device slot table that receives and cache table be specially:
The wireless vehicle detector ID that the packet that a22, foundation receive carries calculates some second of wireless vehicle detector;
Whether there is the wireless vehicle detector ID that the packet that receives carries in the id field of b22, inquiry detector slot table, if existed, perform step c22, e22; Otherwise, perform steps d 22, e22;
C22, the wireless vehicle detector ID carried with the packet received, some second of wireless vehicle detector calculated, the time slot that receives this packet cover the respective field of the wireless vehicle detector ID place record that the packet that receives in detector slot table carries;
D22, in detector slot table, add a record, the point and receive the time slot of packet second of wireless vehicle detector that this record comprises wireless vehicle detector ID that the packet that receives carries, calculates;
E22, determine to exist in cache table to receive the time slot of this packet, then delete the time slot receiving this packet in cache table.
7. wireless sensor network according to claim 3 manages slot approach automatically, it is characterized in that, described in judge whether that the wireless vehicle detector on next second point is specially:
The second of inquiry detector slot table puts in field whether there is next second point, if existed, thinks the wireless vehicle detector had on next second point; Otherwise point does not have node to think next second.
8. wireless sensor network according to claim 3 manages slot approach automatically, it is characterized in that, the wireless vehicle detector whether described inquiry has time slot collision is specially:
041, the index that in buffer memory detector slot table, next second some place is respectively recorded, gets the index ranked the first in the index of buffer memory;
042, to find in detector slot table get the record of index point; The time slot identical with the time slot in the record found in all the other records of sequential query detector slot table, if found, then stops this inquiring about, and has the node of time slot collision in the node thinking on next second point; Fail to inquire the time slot identical with the time slot in the record found, then perform step 043;
043, identical with the time slot in the described record found in sequential query repeater slot table time slot, if found, then stops this inquiring about, and has the node of time slot collision in the node thinking on next second point; Fail to inquire the time slot identical with the time slot in the described record found, then perform step 044;
044, determine whether the index do not taken out in addition, if had, in the index of not taking of buffer memory, get the index ranked the first, return step 042; If do not have the node of time slot collision in the node no, then thinking on next second point.
9. wireless sensor network according to claim 3 manages slot approach automatically, it is characterized in that, the method also comprises: on gateway node, store the first time slot sets and the second time slot sets; Accordingly,
Described judge permit described in have the wireless vehicle detector of time slot collision to use time slot in whether available free time slot is specially:
051, inquire about the access way mark in the detector slot table record having the wireless vehicle detector of time slot collision corresponding on next second point, if direct-connected mark, perform step 052; If switching mark, perform step 053;
052, search and whether there is the first time slot sets and have but the time slot all do not had in detector slot table and in cache table, if existed, think have the node of time slot collision to use described in license time slot in available free time slot; Otherwise, perform step 053;
053, search and whether there is the second time slot sets and have but the time slot all do not had in detector slot table, repeater slot table and cache table, if existed, think have the node of time slot collision to use described in license time slot in available free time slot; Otherwise, think license described in have the node of time slot collision to use time slot in there is no free timeslot.
CN201510068509.4A 2015-02-10 2015-02-10 Wireless sensor network manages slot approach automatically Active CN104684094B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510068509.4A CN104684094B (en) 2015-02-10 2015-02-10 Wireless sensor network manages slot approach automatically

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510068509.4A CN104684094B (en) 2015-02-10 2015-02-10 Wireless sensor network manages slot approach automatically

Publications (2)

Publication Number Publication Date
CN104684094A true CN104684094A (en) 2015-06-03
CN104684094B CN104684094B (en) 2018-03-23

Family

ID=53318518

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510068509.4A Active CN104684094B (en) 2015-02-10 2015-02-10 Wireless sensor network manages slot approach automatically

Country Status (1)

Country Link
CN (1) CN104684094B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101977414A (en) * 2010-11-11 2011-02-16 聂菊根 Simultaneous transmission slot time distribution method of wireless sensor network
CN102281640A (en) * 2011-08-09 2011-12-14 北京邮电大学 Channel resource allocation method based on time division multiplexing
CN102413581A (en) * 2011-12-02 2012-04-11 电信科学技术研究院 Method and system for reserving channel time slot by using initial access node
CN103378919A (en) * 2012-04-12 2013-10-30 电信科学技术研究院 Frame information (FI) message transmission method and apparatus
CN103841562A (en) * 2012-11-21 2014-06-04 电信科学技术研究院 Time slot resource occupation processing method and time slot resource occupation processing device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101977414A (en) * 2010-11-11 2011-02-16 聂菊根 Simultaneous transmission slot time distribution method of wireless sensor network
CN102281640A (en) * 2011-08-09 2011-12-14 北京邮电大学 Channel resource allocation method based on time division multiplexing
CN102413581A (en) * 2011-12-02 2012-04-11 电信科学技术研究院 Method and system for reserving channel time slot by using initial access node
CN103378919A (en) * 2012-04-12 2013-10-30 电信科学技术研究院 Frame information (FI) message transmission method and apparatus
CN103841562A (en) * 2012-11-21 2014-06-04 电信科学技术研究院 Time slot resource occupation processing method and time slot resource occupation processing device

Also Published As

Publication number Publication date
CN104684094B (en) 2018-03-23

Similar Documents

Publication Publication Date Title
CN105991459B (en) CDN node returns source route distribution method, device and system
CN108737590B (en) Automatic address allocation method and system, Modbus master station and Modbus slave station
RU2015120595A (en) DYNAMIC CHOICE OF STORAGE LEVELS
CN106844397B (en) Task transmission method, device and system based on sub-base and sub-table
CN102970328B (en) Data on-line migration method of typical production system in power industry
CN103684645A (en) Time slot collision processing method and device
CN103236989A (en) Cache control method, devices and system in content delivery network
CN101631075A (en) Method for processing message and device thereof
CN104519148A (en) Method and system for detecting accessibility of addresses of application servers
CN104615684A (en) Mass data communication concurrent processing method and system
CN102253948B (en) Method and device for searching information in multi-source information system
CN103841562A (en) Time slot resource occupation processing method and time slot resource occupation processing device
CN109510850A (en) The processing method of browse request, apparatus and system
CN107172193A (en) A kind of load-balancing method and its device based on cluster
CN104684094A (en) Automatic time slot management method of wireless sensor network
CN104519145A (en) An address resource managing method, system and DHCP server
CN109714223B (en) System and method for realizing network service access dynamic load sharing function under NFV architecture
CN105450679A (en) Method and system for performing data cloud storage
CN103078926B (en) The file access method of distributed memory system and device and system
CN106301889B (en) A kind of port numbers rapid-setting method and system
CN111131083B (en) Method, device and equipment for data transmission between nodes and computer readable storage medium
AU2018290375B2 (en) Resource allocation method and system
CN102984296B (en) The method that the configuration of a kind of network address and network merge
CN103955350B (en) Backup node determination method, device and display wall system
US9112751B1 (en) Distributed bandwidth control in a communication network

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant