Traffic light sensor
This element is a sensor layout used to detect traffic lights and access their states (red, green...) with relative position on the Scene2D. In Edit mode, the detection field is represented by dotted lines. Unlike the polysensor, this sensor is not generic and is meant for traffic light detection only. However, when detecting traffic lights, you will also be able to access any of the following parameter : traffic light color, distance on the X and Y axis of the car to the traffic light (see detected traffic light parameters).
Is an equipment | ✔️ |
Can have equipment | ❌ |
This element must be used with 2D scene context.
Icon
2D Representations
![]() | ![]() |
Traffic light sensor in Edit Mode | Traffic light sensor in Run Mode |
3D Representation
No reprensation available on 3D.
External parameters
Show/Hide all parameters
parameter | editable via "Parameter" tab | updatable via a mapping | description | unit | type |
---|---|---|---|---|---|
X-axis relative position | ✔️ | ❌ | Relative position of the element, from its attached element, on the X-axis. | meter | Decimal number |
Y-axis relative position | ✔️ | ❌ | Relative position of the element, from its attached element, on the Y-axis. | meter | Decimal number |
Z-axis relative angle | ✔️ | ✔️ | Relative angle of the element, from its attached element. | degree | Decimal number |
field initial angle | ✔️ | ✔️ | Initial angle of the illuminated field on the Z-axis. | degree | Decimal number |
field final angle | ✔️ | ✔️ | Final angle of the illuminated field on the Z-axis. | degree | Decimal number |
field radius | ✔️ | ✔️ | Radius of the illuminated area on the scene in which it is located. | meter | Decimal number |
field color | ✔️ | ✔️ | Color of the illuminated area on the scene in which it is located. This parameter can be edited. | - | Hexadecimal |
iconX | ✔️ | ❌ | Relative position of the icon, from the origin of the illuminated field, on the X-axis. | meter | Decimal number |
iconY | ✔️ | ❌ | Relative position of the icon, from the origin of the illuminated field, on the Y-axis. | meter | Decimal number |
Visibility | ✔️ | ✔️ | This parameter allows you to choose if you want the element to be visible or not on the scene during the execution of the scenario. If the item is part of a group, it can inherit the value of that group. | - | Enumeration (visible, hidden, inherit) |
Threshold zoom out | ✔️ | ❌ | Zoom level from which its representation on the scene is no longer modified. | % | Decimal number |
Targets | ❌ | ❌ | Target parameters that the sensor must detect. Set to trafficLight. | - | Text |
X-axis position | ✔️ | ✔️ | Position of the element on the X-axis. | meter | Decimal number |
Y-axis position | ✔️ | ✔️ | Position of the element on the Y-axis. | meter | Decimal number |
SizeX | ❌ | ❌ | Size of the traffic light sensor on the X-axis. | meter | Decimal number |
SizeY | ❌ | ❌ | Size of the traffic light sensor on the Y-axis. | meter | Decimal number |
Z-axis angle | ❌ | ❌ | Angle of rotation of the element compared to its initial position. | degree | Decimal number |
Z-axis position | ❌ | ❌ | Position of the element on the Z-axis. | meter | Decimal number |
Height | ❌ | ❌ | Height of the element. | meter | Decimal number |
X-axis angle | ❌ | ❌ | Angle of the element on the X-axis. | degree | Decimal number |
Y-axis angle | ❌ | ❌ | Angle of the element on the Y-axis. | degree | Decimal number |
List of detection | ❌ | ❌ | List of the detected traffic lights. See details below. | - | List of Detected Traffic Light |
longitude coordinate | ❌ | ❌ | Automatically calculated longitude value, based on the origin defined for the context and the position of the element. | degree | Decimal number |
latitude coordinate | ❌ | ❌ | Automatically calculated latitude value, based on the origin defined for the context and the position of the element. | degree | Decimal number |
Detected traffic light parameters
Show/Hide parameters
parameter | description | unit | type |
---|---|---|---|
color | Color of the traffic light. | - | Enumeration (red, yellow, green, flashing yellow) |
dx | Relative position of the traffic light on the X-axis. | meter | Decimal number |
dy | Relative position of the traffic light on the Y-axis. | meter | Decimal number |
Triggered behaviours
See Triggered behaviours and events page for more explanation: Triggered behaviours and events.
Show/Hide all triggered behaviours
Destroy
At the reception of the flow, the element is destroy.
No parameters for this triggered behaviour.
Events
See Triggered behaviours and events page for more explanation: Triggered behaviours and events.
Show/Hide all events
event | description |
---|---|
On Parameter Value Changed | The element can send information to the model when the value of the selected parameter has changed |
At initialization | The traffic light sensor can send information to the model once at initialization |
Continually | The traffic light sensor can send information to the model continuously |