Change VehicleType State

Command 0xc5: Change Vehicle Type State#

ubyte string ubyte <value_type>
Variable Vehicle Type ID Type of the value New Value

Changes a vehicle type. Because it is possible to change different values of a vehicle type, the number of parameter to supply and their types differ between commands. The following values can be changed, the parameter which must be given are also shown in the table. If a vehicle type is changed all vehicles sharing this type get the new value. If a value mentioned below is changed via the vehicle (see TraCI/Change_Vehicle_State), the vehicle gets a new type and won't be affected by further changes to the original type.

Overview Changeable Vehicle Type Variables

Variable ValueType Description Python Method
length (0x44) double Sets the vehicle type's length to the given value setLength
max speed (0x41) double Sets the vehicle type's maximum speed to the given value setMaxSpeed
vehicle class (0x49) string Sets the vehicle type's vehicle class to the given value setVehicleClass
speed factor (0x5e) double Sets the vehicle type's speed factor to the given value setSpeedFactor
speed deviation (0x5f) double Sets the vehicle type's speed deviation to the given value setSpeedDeviation
emission class (0x4a) string Sets the vehicle type's emission class to the given value setEmissionClass
width (0x4d) double Sets the vehicle type's width to the given value setWidth
height(0xbc) double Sets the vehicle type's height to the given value setHeight
min gap (0x4c) double Sets the vehicle type's minimum headway gap to the given value setMinGap
shape class (0x4b) string Sets the vehicle type's shape class to the given value setShapeClass
acceleration (0x46) double Sets the vehicle type's wished maximum acceleration to the given value setAccel
deceleration (0x47) double Sets the vehicle type's wished maximum deceleration to the given value setDecel
imperfection (0x5d) double Sets the vehicle type's driver imperfection (sigma) to the given value setImperfection
tau (0x48) double Sets the vehicle type's wished headway time to the given value setTau
color (0x45) ubyte,ubyte,ubyte,ubyte (RGBA) Sets the vehicle type's color. setColor
max lateral speed (0xba) double Sets the maximum lateral speed in m/s of this type. setMaxSpeedLat
lateral gap (0xbb) double Sets the minimal lateral gap of this type at 50km/h in m. setMinGapLat
lateral alignment (0xb9) string Sets the preferred lateral alignment of the type. setLateralAlignment
copy (0x88) string Creates a new vehicle type with the given ID as a duplicate of the original type. copy
action step length (0x7d) double (new action step length), boolean (reset action offset) Sets the current action step length for the vehicle type in s. If the boolean value resetActionOffset is true, an action step is scheduled immediately for all vehicles of the type. setActionStepLength
scale (0x8e) double Sets the traffic scaling factor for vehicles of this type setScale

The message contents are as following:

length (0x44)#

byte double
value type double New Length

max speed (0x41)#

byte double
value type double New Maximum Speed