Simulating Multiple Vehicles in PX4 SITL Gazebo

Jaeyoung Lim

Previously, it was only possible to simulate multiple vehicles in SITL by extending ROS launchfiles. However, this is not scalable especially when you are trying simulate large number of vehicles or change the number of vehicles a lot.

Now you can simulate multiple vehicles in PX4 SITL gazebo, without depending on ROS. Simply run the following command. A more detailed instruction can be found in the PX4 Devguide

Tools/gazebo_sitl_multiple_run.sh [-m <model>] [-n <number_of_vehicles>] [-w <world>]

Demos

Tools/gazebo_sitl_multiple_run.sh -m iris -n 20
Tools/gazebo_sitl_multiple_run.sh -m plane -n 10
Tools/gazebo_sitl_multiple_run.sh -m standard_vtol
Tools/gazebo_sitl_multiple_run.sh -w baylands

Screenshot from 2020-04-26 15-21-30

PRs that enabled this feature

Anecdote

When I was starting with PX4 SITL years ago, I did something similar but failed miserably. After 4 years, I ended up fixing it myself. 🙂

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s