CARLA Module
cmain
CARLA Operations Handler
This module manages core CARLA operations, including client initialization, simulation data retrieval, and dynamic weather configuration.
- carla_data_loop(client, sock)[source]
Executes a continuous data retrieval loop.
Fetches the latest simulation state from the CARLA server and broadcasts it via the specified UDP socket.
- Parameters:
client (CarlaClient) – Active instance of the CARLA client.
sock (Socket) – UDP socket instance used for publishing simulation packets.
generate traffic Script
Traffic generation script for asynchronous CARLA simulation.
This module is based on the official CARLA examples and has been specifically adapted to support asynchronous mode for the SoundCARLA project. It handles spawning actors, managing traffic, and ensuring synchronization between the simulator and the audio engine.
Note
This script requires a running CARLA server and should be used with caution regarding performance when spawning a high number of NPCs.
See also
For a detailed technical reference of the classes used here, consult the Python API.
manual control Script
Manual control module with Logitech G29 steering wheel support.
This script is based on the official CARLA manual control examples and has been extensively modified to provide native support for the Logitech G29 Racing Wheel, including pedal mapping and force feedback integration. It manages user input, vehicle physics control, and real-time sensor data visualization.
Note
Ensure that the Logitech G Hub software is installed and the steering wheel is calibrated before starting the simulation to avoid axis mapping issues.
See also
For a detailed technical reference of the classes used here, consult the Pygame for vehicle control.