Skip to content

Commit

Permalink
Merge pull request #77 from fjanguita/gazebo-guide
Browse files Browse the repository at this point in the history
Add missing step to Create GZ assets guide
  • Loading branch information
pariaspe authored Nov 5, 2024
2 parents a30904c + 35f408b commit 29ee160
Showing 1 changed file with 15 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,21 @@ For the quadrotor, this template assumes your model has 4 links, one for each ro
they are named m1_joint, m2_joint, m3_joint and m4_joint. These names can be changed to match your links names. The '_joint' is, however, necessary (if m1 is changed for YOUR_LINK, then its joint would have to be YOUR_LINK_joint).
In addition to this, the base link of your quadrotor model must be 'base_link'.

With this template, your model can be renderized to match all the expected naming by Aerostack2 and is ready to fly using the Gazebo Simulator.
For your model to be properly loaded by Aerostack2, it has to be added as a valid drone type at ``as2_gazebo_assets/src/as2_gazebo_assets/models/drone.py``. This script declares a class ``DroneTypeEnum`` to which your new drone model must be added.

.. code-block:: python
class DroneTypeEnum(str, Enum):
"""Valid drone model types."""
QUADROTOR = 'quadrotor_base'
HEXROTOR = 'hexrotor_base'
CRAZYFLIE = 'crazyflie'
X500 = 'x500'
PX4 = 'px4vision'
YOUR_MODEL_TYPE = 'your_model_type'
With this and your model added to a directory that has been added to the Gazebo resources path variable (check :ref:`this section <development_tutorials_gazebo_assets_objects>` of the adding Gazebo assets tutorial), your new drone is ready to be loaded by Gazebo and fly using Aerostack2.

.. _development_guide_create_assets_add_sensor:

Expand Down

0 comments on commit 29ee160

Please sign in to comment.