I implemented the workaround, but the problem still exists.

When I do a Traci VAR_EDGES request to the vehicle after the set route, I 
receive two edges, Edge1 and Edge2.

I’ve also done some debugging in the code of the TraCIServerAPI_Vehicle. At the 
end of the switch value VAR_ROUTE_ID (+/- line 800) the value of 
v->getRoute().getID() is ‘Edge1_Edge2’, as expected. But the vehicle still 
disappears after Edge 1……..


Wim van Husen
Engineer Productontwikkeling
Sweco Nederland B.V.

Van: Jakob Erdmann [mailto:namdre.s...@googlemail.com]
Verzonden: 05 July 2017 13:20
Aan: Husen, Wim van <wim.vanhu...@sweco.nl>
CC: sumo-user (sumo-user@lists.sourceforge.net) 
<sumo-user@lists.sourceforge.net>
Onderwerp: Re: [sumo-user] TraCI: MOVE_TO_XY

I have to correct myself. When moving backwards, the route is always reset to a 
single edge. So as a workaround you must set the route again after the moveToXY 
command.

2017-07-05 13:17 GMT+02:00 Jakob Erdmann 
<namdre.s...@googlemail.com<mailto:namdre.s...@googlemail.com>>:
Hello,
when a vehicle is moved to an edge that was not previously on it's route, it 
will be given a new route which consists of that new edge only. As long as it 
receives a moveToXY command in the next step it will keep driving but otherwise 
it may reach the end of its route and disappear. As a workaround you can set 
the route of the vehicle (in forward direction) if you know it beforehand.
regards,
Jakob

2017-07-05 12:40 GMT+02:00 Husen, Wim van via sumo-user 
<sumo-user@lists.sourceforge.net<mailto:sumo-user@lists.sourceforge.net>>:
Hi all,

I have a problem with moving a vehicle to an xy position (TraCI: MOVE_TO_XY).
- When I move a vehicle forward, all goes well.
- When I move a vehicle backward on the same edge, all goes well.
- When I move a vehicle backward to the previous link, the vehicle disappears 
at the end of the previous link.

Example:
X------------ > -------------X--------------- > ---------------X
         Edge 1                                 Edge 2
When I move the vehicle from edge 2 to edge 1, the vehicle disappears at the 
end of edge 1.
The parameters in the call: Edge1, 0, x, y, -1001, 2

What's going wrong here?

Wim van Husen
Engineer Productontwikkeling
Sweco Nederland B.V.

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
sumo-user mailing list
sumo-user@lists.sourceforge.net<mailto:sumo-user@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/sumo-user


<<attachment: winmail.dat>>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
sumo-user mailing list
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user

Reply via email to