A simple demo of the traffic management system with Zenoh #6100
kaiii708
started this conversation in
Show and tell
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi, community,
We are working on zenoh_autoware_v2x, a showcase project that demonstrates how a Traffic Management System (TMS) prototype can coordinate traffic light control between Autoware and Carla simulation using Zenoh.
This project simulates how high-priority vehicles (e.g., ambulances) can trigger traffic light changes to gain priority access through intersections.
The system core is developed using Zenoh's Python API, leveraging both Zenoh Pub/Sub and Zenoh Queryable mechanisms for inter-module communication.
We chose Zenoh to deliver V2X messages because it is a lightweight, topic-based protocol designed for scalable and distributed communication. While traditional DDS protocols often perform well over wired networks, they tend to face challenges in wireless environments. In contrast, Zenoh is optimized for resource-constrained, high-mobility scenarios, making it well-suited for V2X applications, where vehicles frequently operate in wireless and dynamic conditions.
🧠 System Architecture
Here’s a brief overview of the key components:
Carla Simulator: Represents the physical environment where traffic lights are actually changed.
Autoware: The autonomous driving software stack that runs in the simulated vehicle environment.
Traffic Manager: Acts as the centralized controller for traffic decisions. It continuously receives vehicle pose data—especially from high-priority vehicles. Based on this data, it determines which vehicle should be granted priority at each intersection.
Intersection Manager: Serves as the interface between Carla and the traffic control system. It handles traffic light state queries from Autoware and also applies updated traffic light commands from the Traffic Manager to Carla.
🎥 Demo
⏱️ Key Timestamps
0:44 – V2X demo begins.
Initially, all intersections operate in normal mode, where traffic lights cycle at fixed intervals.
1:45 – A high-priority vehicle approaches the first intersection, "Intersection A".
1:48 – The Traffic Manager, continuously tracking the high-priority vehicle, decides to grant it priority and sends a command to the Intersection Manager.
1:53 – Upon receiving the command, the Intersection Manager halts normal operation and switches Intersection A to special mode to allow the high-priority vehicle to pass.
2:04 – After the vehicle passes through, Intersection A returns to normal mode.
🔄 System Behavior
On the Autoware side, when a vehicle approaches an intersection, it retrieves the current traffic light state using a Zenoh get request with the corresponding key expression. The Intersection Manager replies with Carla’s latest traffic signal status. See 1:34 for reference.
At the same time, Autoware continuously publishes vehicle pose data via Zenoh pub.
The Traffic Manager subscribes to high-priority vehicle pose data via Zenoh sub. When a vehicle is about to enter an intersection, it evaluates its priority and sends a command to the Intersection Manager to change the traffic light state.
The Intersection Manager updates the traffic light in Carla based on commands received from the Traffic Manager via Zenoh queryable. It also continues to handle traffic light status queries from Autoware using the same queryable interface.
📖 Refer to V2X in Carla for running and config setup.
We would appreciate any feedback and suggestions for future work!
Big thanks to my senior colleague and mentor, CY, the primary designer of autoware_carla_launch, for always providing timely guidance. That guidance really helped me ramp up quickly and played a key role in shaping the direction of the system design.
Beta Was this translation helpful? Give feedback.
All reactions