TraCI/Vehicle Signalling

generated on 2019-05-23 00:18:59.279798 from the wiki page for TraCI/Vehicle_Signalling for SUMO git

A vehicle's signals are encoded in an integer, each by one bit, encoding whether the according signal/... is on or off. Most signals are rather meant to be used by an external application. The following signals are special:

  • "VEH_SIGNAL_BRAKELIGHT": computed each time step, used by the vehicles when trying to avoid jamming on an intersection. The value set via TraCI is only retained for the current time step
  • "VEH_SIGNAL_BLINKER_RIGHT" and "VEH_SIGNAL_BLINKER_LEFT": computed each time step, The value set via TraCI is only retained for the current time step
  • "VEH_SIGNAL_EMERGENCY_BLUE: when switched on, a blinking blue light is shown in the GUI for vehicles with vClass="emergency" and shapeClass="emergency"

The following table shows the defined signals.

Name Bit
VEH_SIGNAL_BLINKER_RIGHT 0
VEH_SIGNAL_BLINKER_LEFT 1
VEH_SIGNAL_BLINKER_EMERGENCY 2
VEH_SIGNAL_BRAKELIGHT 3
VEH_SIGNAL_FRONTLIGHT 4
VEH_SIGNAL_FOGLIGHT 5
VEH_SIGNAL_HIGHBEAM 6
VEH_SIGNAL_BACKDRIVE 7
VEH_SIGNAL_WIPER 8
VEH_SIGNAL_DOOR_OPEN_LEFT 9
VEH_SIGNAL_DOOR_OPEN_RIGHT 10
VEH_SIGNAL_EMERGENCY_BLUE 11
VEH_SIGNAL_EMERGENCY_RED 12
VEH_SIGNAL_EMERGENCY_YELLOW 13
Note:
Sending a negative signal value immediately resets all signals to their computed values

See also: