I'm using veins 4.4, OMNeT++ 5.0 and SuMO 0.25. I have set vehicle speed to 0 to stop them by traciVehicle->setSpeed(0)
then after certain case i set them to 20 by traciVehicle->setSpeed(20)
to cross the intersection but for no reason it increases slowly till its time finish , so can i make it faster ???

- 1,822
- 3
- 16
- 27

- 55
- 9
-
Can you quantify how slow exactly the speed increases? How does this value compare to what you expected? – Christoph Sommer Mar 27 '17 at 23:00
-
The max acceleration speed of a car is specified by the vehicleType used in SUMO. Maybe it's worth to look on this values and compare them to your speed increasing. – Ventu Mar 28 '17 at 07:47
-
Actually i solved the problem by regenerating my map and after that vehicles crossed in same speed.i think unknown error occurred in my (.net or .rou ) files while i was debugging my code. thanks for your answer – user12345 Jul 15 '17 at 22:21
2 Answers
A vehicle in SuMO has the speedMode
parameter which determines how it should behave for instance in terms of acceleration and deceleration.
By default this parameters is set to consider all checks like keeping a safe gap to other vehicles and the maximum acceleration. When set to 0 the vehicle ignores all checks like the maximum acceleration.
Try setting different values for the speedMode
in Veins to achieve the expected vehicle behavior. You can do so by using the TraCICommandInterface and the TraciVehicle. Have a look at the TraCITestApp for an example. Also you could play around with the maximumSpeed
parameter.

- 1,822
- 3
- 16
- 27
-
Good Point , i will try to use it in controlling speed but how to set speedMode , i saw in TestAPP something like 0x00, didn't get it?? – user12345 Mar 30 '17 at 18:28
-
You can find the values and there meaning in the documentation I linked in my answer. Please see the TraciTestApp for setting such a value in Veins. – Julian Heinovski Mar 30 '17 at 23:58
i solved the problem by regenerating my map and after that vehicles crossed in its expected speed.i think unknown error occurred in my (.net or .rou ) files while i was debugging my code.

- 55
- 9