Summary of the invention
Goal of the invention: technical problem to be solved by this invention is for the deficiencies in the prior art, provides the method for routing of the vehicle-mounted net in a kind of city.
Technical scheme: the method for routing that the invention discloses the vehicle-mounted net in a kind of city, the vehicle node that the vehicle-mounted net in described city comprises couple in router, access node and is positioned on road; Couple in router is connected with the backbone network of the Internet, and access node is connected with more than one couple in router; The all access nodes be connected with a couple in router are surrounded a closed area as car territory;
Vehicle node is divided into backbone node and ordinary node two class: backbone node performs route forwarding function, it preserves the routing iinformation arriving the nearest access node in car territory, place, and realizes the communication with the Internet by nearest access node; Ordinary node does not perform route forwarding function, and it realizes the communication with the Internet by the backbone node within the scope of a jumping;
The IPv6 address of vehicle node comprises three parts: Part I is car territory ID, it is overall route prefix, unique identification car territory, in a car territory, the car territory ID of all access nodes is identical, the car territory ID of the IPv6 address obtained in a car territory is identical, and its value equals the car territory ID of couple in router in identical car territory; Part II is access node ID, an access node in its unique identification car territory, and all identical from the access node ID of the address that an access node obtains, its value equals the access node ID of this access node; Part III is vehicle ID, the vehicle in its unique identification car territory; The IPv6 address of couple in router and access node pre-sets, and the access node ID of couple in router and vehicle ID is 0, and the vehicle ID of access node is 0.Such as, the IPv6 address of couple in router is 3E01:1:1:1::0, and the IPv6 address of access node is 3E01:1:1:1:1::0.
In above-mentioned vehicle-mounted net, only have backbone node to have routing function, therefore routed backbone number of nodes is little, thus reduces routing cost and routing delay.
In the method for the invention, when vehicle node adds the vehicle-mounted net in city, it drives to access node one and jumps after in scope, obtains home address from this access node; After obtaining home address, when vehicle node travels in car territory, its home address and Care-of Address remain unchanged; When vehicle node enters a new car territory, it obtains Care-of Address from the access node belonging to new car territory and original car territory simultaneously;
Access node belongs to one respectively with territory of setting out on a journey, and before for vehicle node configuration address, first access node judges the next car territory that vehicle node enters, then for vehicle node distributes in next car territory the IPv6 address with global uniqueness; For each affiliated car territory, access node is preserved a vehicle ID and is shown, for recording the vehicle ID distributed;
The process that vehicle node obtains IPv6 address from access node is as follows:
Step 201: start;
Step 202: vehicle node sends address request to access node;
Step 203: after access node receives address request, sends refresh message to vehicle node;
Step 204: after vehicle node receives refresh message, regularly sends refresh response message to access node;
Step 205: access node carrys out the relative position of positioned vehicle node by measuring refresh response message, and judges the territory, next road that vehicle node enters;
Step 206: access node adopts random function to produce a vehicle ID at random;
Step 207: the vehicle ID table that access node inquires about territory, next road corresponding judges whether the vehicle ID generated distributes, and if so, returns step 206, otherwise carry out step 208;
Step 208: oneself car territory ID, access node ID are combined with the vehicle ID of generation and produce new Care-of Address by access node, and be encapsulated in address response message and send to vehicle node;
Step 209: whether vehicle node configures home address, if so, carry out step 211, otherwise carry out step 210;
Step 210: after vehicle node receives address response message, using the home address of the address in message as oneself, carry out step 212;
Step 211: after vehicle node receives address response message, using the Care-of Address of the address in message as oneself;
Step 212: terminate;
If access node belongs to K car territory and the angle closed interval that kth car territory defines is [α
k, α
k+1], K>=k>=1.Such as access node belongs to 3 car territories, and each car territory is respectively by angle closed interval [1,120], and [121,240] and [241,360] define.At moment T1, vehicle node enters in the communication range of access node, and the intensity of the refresh response message that access node is sent by measuring vehicle node judges the distance with vehicle node; When distance is less than road width, vehicle node is about to enter territory, next road, the access node refresh response message that location algorithm (such as Received signal strengthindicator and Angle ofarrival location algorithm) measuring vehicle node sends judges the relative angle with vehicle node, access node passes through the angle closed interval at relative angle and place, each car territory, judges the territory, next road that vehicle node enters.
By above-mentioned algorithm, when vehicle node enters a new car territory, new Care-of Address can be obtained, thus ensure the continuity of communication and the correctness of route.
In the method for the invention, each vehicle node is furnished with global positioning system, for obtaining the address coordinate of oneself, and clock synchronous all in the vehicle-mounted net in city; Make vehicle node V
igeographical coordinate be (x
i, y
i), vehicle node V
jgeographical coordinate be (x
j, y
j), vehicle node V
ispeed v
i, vehicle node V
jspeed be v
j, vehicle node V
imove angle be θ
i, vehicle node V
jmove angle be θ
j, the transmission radius of vehicle node is r, so, and vehicle node V
iand V
jlink connect hours T
ijfor:
Wherein,
a=v
icosθ
i-v
jcosθ
j,
b=x
i-x
j,
c=v
isinθ
i-v
jsinθ
j,
d=y
i-y
j,
Access node belongs to K car territory, when the jth bar road for kth car territory sets up route, and 1≤k≤K, the move angle θ of the down hop neighbours vehicle node that access node is selected meets following condition:
α
k≤β
j≤θ≤β
j+1≤α
k+1’
Wherein, the angular range in kth car territory is [α
k, α
k+1],
The angular range of the jth bar road in kth car territory is [β
j, β
j+1].
In the method for the invention, vehicle node regularly sends broadcast, and Message Payload comprises address location coordinate, translational speed and move angle; Vehicle node obtains the link connect hours with neighbours' vehicle node by the message receiving the broadcast of neighbours' vehicle node;
In car territory, it is as follows that vehicle node sets up the routing procedure arriving nearest access node AP1:
Step 301: start;
Step 302: access node AP1 selects neighbours' ordinary node with the maximum link connect hours, and sends Route establishment message to it, and Message Payload is the address of access node AP1, and value is the jumping figure parameter of 0, and is set to the link connect hours of maximum;
Step 303: after neighbours' ordinary node receives Route establishment message, judges whether have backbone node within the scope of one jumping, if so, carry out step 305, otherwise carry out step 304;
Step 304: neighbours' ordinary node using access node AP1 as nearest access node, preserve the address of the jumping figure parameter arriving access node AP1 and the backbone node forwarding Route establishment message, oneself is labeled as backbone node, then the down hop neighbours ordinary node of maximum link connect hours is selected, forward Route establishment message to it, the jumping figure wherein in Message Payload increases progressively 1; The link connect hours is the link connect hours in Route establishment message, and the minimum value between oneself and the link connect hours of down hop neighbours ordinary node, carry out step 303;
Step 305: neighbours' ordinary node abandons Route establishment message and returns route response message to the backbone node forwarding Route establishment message, Message Payload is the link connect hours arriving access node AP1 path;
Step 306: after backbone node receives route response message, record the link connect hours arriving access node AP1 path, then route response message is sent to the down hop backbone node arriving access node AP1, route response message finally reaches access node AP1;
Step 307: after access node AP1 receives route response message, records the routing link connect hours in corresponding car territory;
Step 308: terminate;
After Route establishment completes, access node AP1 re-establishes route to safeguard the validity of route after the link connect hours; Following data are increased: the address of access node AP1, arrive the path of access node AP1 and arrive link connect hours in path of access node AP1 in the broadcast load of backbone node.
Above-mentioned algorithm adopts the link connect hours to set up route as metric algorithm, thus obtain the routed path that the link connect hours relatively grows, enhance routing stability, it also avoid and interrupt due to route and the rerouting that causes, because this reducing packet loss, ensure that communication quality.
In the method for the invention, time backbone node communicates with internet node, according to set up routed path by Packet Generation to nearest access node, then the couple in router in this car territory is sent to by access node, the incidence relation of couple in router record backbone node and nearest access node, and by Packet Generation to internet node;
First the packet that internet node returns arrives the couple in router in car territory, backbone node place, couple in router according to the backbone node of record and the incidence relation of access node by the Packet Generation returned to the access node associated with backbone node, access node according to the routed path in car territory, place, packet rs destination address by Packet Generation to down hop backbone node, final data bag arrives object backbone node;
When ordinary node communicates with internet node, the backbone node B with the maximum link connect hours is selected from neighbours' backbone node, then by Packet Generation to backbone node B, after backbone node B receives packet, record ordinary node and the incidence relation of oneself, send to internet node by packet by the couple in router in nearest access node and car territory, place simultaneously;
After the packet that internet node returns arrives nearest access node, nearest access node is according to the routing iinformation in car territory, place, packet rs destination address, by Packet Generation to down hop backbone node, down hop backbone node detects oneself whether to have incidence relation with ordinary node, if do not had, to continue according to routing iinformation by Packet Generation to down hop backbone node, the backbone node B that final arrival is relevant with ordinary node, then backbone node B by Packet Generation to ordinary node.
By said process, the communication of the route implementing that ordinary node selection stability is the strongest and the Internet, thus ensure that communication quality.
In the method for the invention, ordinary node and backbone node are provided with incidence relation, ordinary node detects the communication range being about to leave backbone node, from neighbours' backbone node, so select the backbone node with the maximum link connect hours as new associated nodes, and send association messages to new associated nodes, Message Payload is the address of the nearest access node of original associated nodes, after new associated nodes receives association messages, increases the incidence relation with ordinary node;
If but the nearest access node of new associated nodes is different from the nearest access node of original associated nodes belong to a car territory, so new associated nodes sends updating message to the couple in router in car territory, place, and Message Payload is the address of the address of ordinary node and the nearest access node of new associated nodes; After couple in router receives updating message, the address of the nearest access node of ordinary node is updated to the address of the nearest access node of the new associated nodes in updating message;
After updating route information, destination address is after the packet of ordinary node arrives the couple in router in car territory, place, couple in router is forwarded to the nearest access node of new associated nodes, nearest access node according to car territory, place routing information by Packet Generation to up-to-date backbone node, then by up-to-date backbone node by Packet Generation to ordinary node;
Ordinary node deletes association messages after departing from the communication range of original associated nodes automatically.
The route correctness of ordinary node by above-mentioned algorithm realization in moving process and continuity.
In the method for the invention, when the path link connect hours of access node is 0, re-establish route;
After re-establishing route, ordinary node C1 becomes backbone node C1, if the originally nearest access node AP1 of backbone node C1 is different from now nearest access node AP2 and access node AP1 and access node AP2 belongs to a car territory, so backbone node C1 sends updating message to the couple in router AR1 in car territory, place, and Message Payload is the address of access node AP2; After couple in router AR1 receives updating message, the address of the association access node AP1 of backbone node C1 is updated to the address of access node AP2;
Destination address is that after the packet of backbone node C1 arrives couple in router AR1, couple in router AR1 is forwarded to access node AP2, and data are sent to backbone node C1 according to Che Yu path, place by access node AP2;
After re-establishing route, the backbone node that ordinary node C2 associated originally changes ordinary node into, so ordinary node C2 selects the backbone node B2 with the maximum link connect hours as new associated nodes from neighbours' backbone node, and sending association messages to backbone node B2, Message Payload is the address of the nearest access node AP3 of original associated nodes; After backbone node B2 receives association messages, increase the incidence relation with ordinary node C2; If the nearest access node AP4 of backbone node B2 and access node AP3 belongs to a car territory, so backbone node B2 sends updating message to the couple in router AR2 in car territory, place, and Message Payload is the address of ordinary node C2 and access node AP4; After couple in router AR2 receives updating message, the address of the association access node of ordinary node C2 is updated to the address of access node AP4;
Destination address is after the data of ordinary node C2 arrive couple in router AR2, couple in router AR2 is forwarded to access node AP4, data are sent to backbone node B2 according to Che Yu path, place by access node AP4, backbone node B2 by data retransmission to ordinary node C2;
After re-establishing route, backbone node B3 changes ordinary node B3 into, ordinary node B3 selects the backbone node B4 with the maximum link connect hours as associated nodes from neighbours' backbone node, and sending associated nodes message to backbone node B4, Message Payload is the address of originally nearest access node AP5; After backbone node B4 receives association messages, increase the incidence relation with ordinary node B3; If the nearest access node of backbone node B4 belongs to the ingress AP6 that a car territory connects, so backbone node B4 sends updating message to the couple in router AR3 in car territory, place, and Message Payload is the address of ordinary node B3 and access node AP6; After couple in router AR3 receives updating message, the address of the association access node of ordinary node B3 is updated to the address of access node AP6;
Destination address is after the data of ordinary node B3 arrive couple in router AR3, couple in router AR3 is forwarded to access node AP6, data are sent to backbone node B4 according to Che Yu path, place by access node AP6, last backbone node B4 by data retransmission to ordinary node B3.
Above-mentioned algorithm realization rerouting, thus ensure that validity and the correctness of route.Because rerouting obtains the routed path that the link connect hours relatively grows, therefore also enhance routing stability, it also avoid and interrupt due to route and the rerouting that causes, because this reducing packet loss, ensure that communication quality.
In the method for the invention, vehicle node V enters the process of car territory VD2 by access node AP from car territory VD1, first obtains new Care-of Address from access node AP and carries out the bindings of new address, oneself being labeled as ordinary node simultaneously; Vehicle node V selects to have the backbone node B5 of maximum link connect hours as associated nodes in neighbours' backbone node of car territory VD2, and sends association messages to backbone node B5, and Message Payload is the address of access node AP at car territory VD1; After backbone node B5 receives association messages, increase the incidence relation with vehicle V, judge that vehicle node V is the ordinary node newly entering car territory VD2 by the address value of Message Payload simultaneously, couple in router AR7 to car territory, VD2 place, car territory sends updating message, and Message Payload is that Care-of Address and access node AP that vehicle node V is new are in the address of car territory VD2; After couple in router AR7 receives updating message, record the incidence relation of vehicle node V and access node AP;
After new address binding, destination address is after vehicle node V newly associates the data arrival couple in router AR7 of address, couple in router AR7 is forwarded to access node AP, data are sent to backbone node B5 according to Che Yu path, place by access node AP, last backbone node B5 by data retransmission to vehicle node V;
The incidence relation of the vehicle node V in the couple in router AR8 in the VD1 of car territory is 0 rear deletion automatically in effective time.
Vehicle node ensure that continuity in moving process and route correctness by said process.
Beneficial effect: the method for routing that the invention provides the vehicle-mounted net in a kind of city, described In-vehicle networking is by method for routing provided by the present invention, the communication with the Internet can be realized, the continuity communicated can be guaranteed, shorten communication delay, reduce bursts dropping ratio, thus improve the service quality of vehicle-mounted net, the present invention can be applicable to the fields such as road conditions monitoring, vehicle management, is with a wide range of applications.
Embodiment:
The invention provides a kind of method for routing of vehicle-mounted net, described In-vehicle networking is by method for routing provided by the present invention, the communication with the Internet can be realized, the continuity communicated can be guaranteed, shorten communication delay, reduce bursts dropping ratio, thus improve the service quality of vehicle-mounted net, the present invention can be applicable to the fields such as road conditions monitoring, vehicle management, is with a wide range of applications.
Fig. 1 is couple in router of the present invention, access node and vehicle node structural representation.The vehicle node that the vehicle-mounted net in described city comprises couple in router 1, access node 2 and is positioned on road; Couple in router 1 is connected with the backbone network of the Internet, and access node 2 is connected with more than one couple in router 1; The all access nodes 2 be connected with a couple in router 1 are surrounded a closed area as car territory 3.
Vehicle node is divided into backbone node 4 and ordinary node 5 liang of classes: backbone node 4 performs route forwarding function, it preserves the routing iinformation arriving the nearest access node 2 in car territory, place 3, and realizes the communication with the Internet by nearest access node 2; Ordinary node 5 does not perform route forwarding function, and it realizes the communication with the Internet by the backbone node 4 within the scope of a jumping.
Fig. 2 is node IP v6 address structure schematic diagram of the present invention.The IPv6 address of vehicle node comprises three parts: Part I is car territory ID, it is overall route prefix, unique identification car territory, in a car territory, the car territory ID of all access nodes is identical, the car territory ID of the IPv6 address obtained in a car territory is identical, and its value equals the car territory ID of couple in router in identical car territory; Part II is access node ID, an access node in its unique identification car territory, and all identical from the access node ID of the address that an access node obtains, its value equals the access node ID of this access node; Part III is vehicle ID, the vehicle in its unique identification car territory; The IPv6 address of couple in router and access node pre-sets, and the access node ID of couple in router and vehicle ID is 0, and the vehicle ID of access node is 0.
Fig. 3 is that vehicle node of the present invention obtains IPv6 address schematic flow sheet.When vehicle node adds the vehicle-mounted net in city, it drives to access node one and jumps after in scope, obtains home address from this access node; After obtaining home address, when vehicle node travels in car territory, its home address and Care-of Address remain unchanged; When vehicle node enters a new car territory, it obtains Care-of Address from the access node belonging to new car territory and original car territory simultaneously.
Access node belongs to one respectively with territory of setting out on a journey, and before for vehicle node configuration address, first access node judges the next car territory that vehicle node enters, then for vehicle node distributes in next car territory the IPv6 address with global uniqueness; For each affiliated car territory, access node is preserved a vehicle ID and is shown, for recording the vehicle ID distributed.
The process that vehicle node obtains IPv6 address from access node is as follows.
Step 201: start.
Step 202: vehicle node sends address request to access node.
Step 203: after access node receives address request, sends refresh message to vehicle node.
Step 204: after vehicle node receives refresh message, regularly sends refresh response message to access node.
Step 205: access node carrys out the relative position of positioned vehicle node by measuring refresh response message, and judges the territory, next road that vehicle node enters.
Step 206: access node adopts random function to produce a vehicle ID at random.
Step 207: the vehicle ID table that access node inquires about territory, next road corresponding judges whether the vehicle ID generated distributes, and if so, returns step 206, otherwise carry out step 208.
Step 208: oneself car territory ID, access node ID are combined with the vehicle ID of generation and produce new Care-of Address by access node, and be encapsulated in address response message and send to vehicle node.
Step 209: whether vehicle node configures home address, if so, carry out step 211, otherwise carry out step 210.
Step 210: after vehicle node receives address response message, using the home address of the address in message as oneself, carry out step 212.
Step 211: after vehicle node receives address response message, using the Care-of Address of the address in message as oneself.
Step 212: terminate.
If access node belongs to K car territory and the angle closed interval that kth car territory defines is [α
k, α
k+1], K>=k>=1, at moment T1, vehicle node enters in the communication range of access node, and the intensity of the refresh response message that access node is sent by measuring vehicle node judges the distance with vehicle node.When distance is less than road width, vehicle node is about to enter territory, next road, the access node refresh response message that location algorithm measuring vehicle node sends judges the relative angle with vehicle node, access node passes through the angle closed interval at relative angle and place, each car territory, judges the territory, next road that vehicle node enters.
Fig. 4 is Route establishment schematic flow sheet of the present invention.Vehicle node regularly sends broadcast, and Message Payload comprises address location coordinate, translational speed and move angle.Vehicle node obtains the link connect hours with neighbours' vehicle node by the message receiving the broadcast of neighbours' vehicle node.
In car territory, it is as follows that vehicle node sets up the routing procedure arriving nearest access node AP1.
Step 301: start.
Step 302: access node AP1 selects neighbours' ordinary node with the maximum link connect hours, and sends Route establishment message to it, and Message Payload is the address of access node AP1, and value is the jumping figure parameter of 0, and is set to the link connect hours of maximum.
Step 303: after neighbours' ordinary node receives Route establishment message, judges whether have backbone node within the scope of one jumping, if so, carry out step 305, otherwise carry out step 304.
Step 304: neighbours' ordinary node using access node AP1 as nearest access node, preserve the address of the jumping figure parameter arriving access node AP1 and the backbone node forwarding Route establishment message, oneself is labeled as backbone node, then the down hop neighbours ordinary node of maximum link connect hours is selected, forward Route establishment message to it, the jumping figure wherein in Message Payload increases progressively 1.The link connect hours is the link connect hours in Route establishment message, and the minimum value between oneself and the link connect hours of down hop neighbours ordinary node, carry out step 303.
Step 305: neighbours' ordinary node abandons Route establishment message and returns route response message to the backbone node forwarding Route establishment message, Message Payload is the link connect hours arriving access node AP1 path.
Step 306: after backbone node receives route response message, record the link connect hours arriving access node AP1 path, then route response message is sent to the down hop backbone node arriving access node AP1, route response message finally reaches access node AP1.
Step 307: after access node AP1 receives route response message, records the routing link connect hours in corresponding car territory.
Step 308: terminate.
After Route establishment completes, access node AP1 re-establishes route to safeguard the validity of route after the link connect hours; Following data are increased: the address of access node AP1, arrive the path of access node AP1 and arrive link connect hours in path of access node AP1 in the broadcast load of backbone node.
In the present invention, time backbone node communicates with internet node, according to set up routed path by Packet Generation to nearest access node, then the couple in router in this car territory is sent to by access node, the incidence relation of couple in router record backbone node and nearest access node, and by Packet Generation to internet node.
First the packet that internet node returns arrives the couple in router in car territory, backbone node place, couple in router according to the backbone node of record and the incidence relation of access node by the Packet Generation returned to the access node associated with backbone node, access node according to the routed path in car territory, place, packet rs destination address by Packet Generation to down hop backbone node, final data bag arrives object backbone node.
When ordinary node communicates with internet node, the backbone node B with the maximum link connect hours is selected from neighbours' backbone node, then by Packet Generation to backbone node B, after backbone node B receives packet, record ordinary node and the incidence relation of oneself, send to internet node by packet by the couple in router in nearest access node and car territory, place simultaneously.
After the packet that internet node returns arrives nearest access node, nearest access node is according to the routing iinformation in car territory, place, packet rs destination address, by Packet Generation to down hop backbone node, down hop backbone node detects oneself whether to have incidence relation with ordinary node, if do not had, to continue according to routing iinformation by Packet Generation to down hop backbone node, the backbone node B that final arrival is relevant with ordinary node, then backbone node B by Packet Generation to ordinary node.
In the present invention, ordinary node and backbone node are provided with incidence relation, ordinary node detects the communication range being about to leave backbone node, from neighbours' backbone node, so select the backbone node with the maximum link connect hours as new associated nodes, and send association messages to new associated nodes, Message Payload is the address of the nearest access node of original associated nodes, after new associated nodes receives association messages, increases the incidence relation with ordinary node.
If but the nearest access node of new associated nodes is different from the nearest access node of original associated nodes belong to a car territory, so new associated nodes sends updating message to the couple in router in car territory, place, and Message Payload is the address of the address of ordinary node and the nearest access node of new associated nodes; After couple in router receives updating message, the address of the nearest access node of ordinary node is updated to the address of the nearest access node of the new associated nodes in updating message.
After updating route information, destination address is after the packet of ordinary node arrives the couple in router in car territory, place, couple in router is forwarded to the nearest access node of new associated nodes, nearest access node according to car territory, place routing information by Packet Generation to up-to-date backbone node, then by up-to-date backbone node by Packet Generation to ordinary node.
Ordinary node deletes association messages after departing from the communication range of original associated nodes automatically.
In the present invention, when the path link connect hours of access node is 0, re-establish route.
After re-establishing route, ordinary node C1 becomes backbone node C1, if the originally nearest access node AP1 of backbone node C1 is different from now nearest access node AP2 and access node AP1 and access node AP2 belongs to a car territory, so backbone node C1 sends updating message to the couple in router AR1 in car territory, place, and Message Payload is the address of access node AP2; After couple in router AR1 receives updating message, the address of the association access node AP1 of backbone node C1 is updated to the address of access node AP2.
Destination address is that after the packet of backbone node C1 arrives couple in router AR1, couple in router AR1 is forwarded to access node AP2, and data are sent to backbone node C1 according to Che Yu path, place by access node AP2.
After re-establishing route, the backbone node that ordinary node C2 associated originally changes ordinary node into, so ordinary node C2 selects the backbone node B2 with the maximum link connect hours as new associated nodes from neighbours' backbone node, and sending association messages to backbone node B2, Message Payload is the address of the nearest access node AP3 of original associated nodes; After backbone node B2 receives association messages, increase the incidence relation with ordinary node C2; If the nearest access node AP4 of backbone node B2 and access node AP3 belongs to a car territory, so backbone node B2 sends updating message to the couple in router AR2 in car territory, place, and Message Payload is the address of ordinary node C2 and access node AP4; After couple in router AR2 receives updating message, the address of the association access node of ordinary node C2 is updated to the address of access node AP4.
Destination address is after the data of ordinary node C2 arrive couple in router AR2, couple in router AR2 is forwarded to access node AP4, data are sent to backbone node B2 according to Che Yu path, place by access node AP4, backbone node B2 by data retransmission to ordinary node C2.
After re-establishing route, backbone node B3 changes ordinary node B3 into, ordinary node B3 selects the backbone node B4 with the maximum link connect hours as associated nodes from neighbours' backbone node, and sending associated nodes message to backbone node B4, Message Payload is the address of originally nearest access node AP5; After backbone node B4 receives association messages, increase the incidence relation with ordinary node B3; If the nearest access node of backbone node B4 belongs to the ingress AP6 that a car territory connects, so backbone node B4 sends updating message to the couple in router AR3 in car territory, place, and Message Payload is the address of ordinary node B3 and access node AP6; After couple in router AR3 receives updating message, the address of the association access node of ordinary node B3 is updated to the address of access node AP6.
Destination address is after the data of ordinary node B3 arrive couple in router AR3, couple in router AR3 is forwarded to access node AP6, data are sent to backbone node B4 according to Che Yu path, place by access node AP6, last backbone node B4 by data retransmission to ordinary node B3.
In the present invention, vehicle node V enters the process of car territory VD2 by access node AP from car territory VD1, first obtains new Care-of Address from access node AP and carries out the bindings of new address, oneself being labeled as ordinary node simultaneously; Vehicle node V selects to have the backbone node B5 of maximum link connect hours as associated nodes in neighbours' backbone node of car territory VD2, and sends association messages to backbone node B5, and Message Payload is the address of access node AP at car territory VD1; After backbone node B5 receives association messages, increase the incidence relation with vehicle V, judge that vehicle node V is the ordinary node newly entering car territory VD2 by the address value of Message Payload simultaneously, couple in router AR7 to car territory, VD2 place, car territory sends updating message, and Message Payload is that Care-of Address and access node AP that vehicle node V is new are in the address of car territory VD2; After couple in router AR7 receives updating message, record the incidence relation of vehicle node V and access node AP.
After new address binding, destination address is after vehicle node V newly associates the data arrival couple in router AR7 of address, couple in router AR7 is forwarded to access node AP, data are sent to backbone node B5 according to Che Yu path, place by access node AP, last backbone node B5 by data retransmission to vehicle node V.
The incidence relation of the vehicle node V in the couple in router AR8 in the VD1 of car territory is 0 rear deletion automatically in effective time.
In sum, In-vehicle networking of the present invention is by method for routing provided by the present invention, the communication with the Internet can be realized, the continuity communicated can be guaranteed, shorten communication delay, reduce bursts dropping ratio, thus improve the service quality of vehicle-mounted net, the present invention can be applicable to the fields such as road conditions monitoring, vehicle management, is with a wide range of applications, therefore, this technology has very high promotional value.
The invention provides the thinking of the method for routing of the vehicle-mounted net in a kind of city; the method and access of this technical scheme of specific implementation is a lot; the above is only the preferred embodiment of the present invention; should be understood that; for those skilled in the art; under the premise without departing from the principles of the invention, can also make some improvements and modifications, these improvements and modifications also should be considered as protection scope of the present invention.The all available prior art of each component part not clear and definite in the present embodiment is realized.