Skip to content

Plugins to model the dynamics of autonomous surface vehicles in Gazebo

Notifications You must be signed in to change notification settings

daneshtarapore/gazebo-asv

Repository files navigation

README

What is gazebo-asv?

Gazebo-asv comprises models and plugins to simulate the dynamics of an autonomous surface vehicle in 6-DoF (surge, sway, heave, roll, pitch and yaw).

Downloading gazebo-asv

You can download the sources of gazebo-asv through git:

$ git clone https://github.com/daneshtarapore/gazebo-asv.git gazebo-asv

Compiling gazebo-asv

Requirements and compiling instructions

Gazebo-asv requires the Gazebo simulator. Installation instructions for Gazebo can be found at http://gazebosim.org/tutorials?cat=install. The gazebo-asv has been tested on Gazebo7.

Fast compiling instructions

$ cd gazebo-asv
$ cd plugins/models/asvdynamics
$ mkdir build
$ cd build
$ cmake ..
$ make

Running the gazebo-asv simulator

Before running Gazebo, make sure the GAZEBO_MODEL_PATH environment variable points to gazebo-asv/models. Also the environment variable GAZEBO_PLUGIN_PATH should points to gazebo-asv/plugins/models/asvdynamics/build.

First create the Gazebo world by running create_swarm_world.py script. RNG_SEED is the random number generator seed used to randomly position NUM_ASV robots of the swarm. The template world file used is gazebo-asv/worlds/surface.template.world.

$ cd gazebo-asv/worlds
$ ./create_swarm_world.py RNG_SEED NUM_ASV

Now create the ASV model files for each of the NUM_ASV robots of the swarm by running the create_swarm_asv_models.sh script. The template ASV model files are in gazebo-asv/models/asv_model.

$ cd gazebo-asv/models
$ ./create_swarm_asv_models.sh NUM_ASV

The simulation can now be run as follows:

$ cd gazebo-asv
$ gazebo -e ode --verbose worlds/surface.world -u --profile ode

In the simulation example, gazebo-asv/worlds/surface.world describes a scenario with NUM_ASV monohull dual-propeller ASVs. The thrust forces applied on the two propellers of robot X are specified in models/surfacevehicle_X/model.sdf (xml tags: left_propeller_thrust and right_propeller_thrust).

Note that the gazebo-asv simulator has only been tested with the ODE physics engine (specified with the -e switch). The -u switch pauses the simulation after surface.world has been loaded. A profile detailing the physics parameters for Gazebo is specified in gazebo-asv/worlds/surface.world and selected with the --profile switch.

About

Plugins to model the dynamics of autonomous surface vehicles in Gazebo

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published