-
Notifications
You must be signed in to change notification settings - Fork 11
ERA and CARLA Detailed
ERA and CARLA use ROS to communicate each other. Standalone ERA currently does not have a way to read from or write to CARLA however it is not a complicated task to add that functionality.
CARLA is a driving simulator using unreal engine to simulate environments, vehicles, pedestrians, and sensors. It has a server-client architecture which means that you need to run Carla as a standalone application and interact with it through its API. CARLA's API is written in Python.
CARLA also has a ROS interface to easily interact with the ROS world. It is called ros-bridge. It basically uses CARLA's API and translate the sensor and position data to ROS topics. It also allows ROS nodes to control vehicles in CARLA using velocity commands.
ERA (master branch) uses ros-bridge (not to be confused with ros-bridge) to communicate with CARLA. CARLA runs, in a ROS independent fashion, separately in a single process. ros-bridge communicates with CARLA through sockets and exposes sensor data as ROS topics.
Current version of ERA only reads lidar data, camera data, and vehicle position data.
Follow this wiki page.
As a summary, you need to install CARLA (apt-get), ros-bridge, and ERA ROS version.
Running the system is straight forward:
- First run CARLA in a separate terminal:
/opt/carla-simulator/bin/CarlaUE4.sh
- Run ERA in another terminal:
roslaunch era_gazebo carla_two_cars.launch
- Finally you may want to run
rviz
in a third terminal for visualization.
roslaunch era_gazebo carla_two_cars.launch
does many things and launches a bunch of ros nodes in parallel.