PX4 / PX4-SITL_gazebo-classic

Set of plugins, models and worlds to use with OSRF Gazebo Simulator in SITL and HITL.

Home Page:http://dev.px4.io/simulation-gazebo.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Simulating custom airship in Gazebo

lucaperrin opened this issue · comments

commented

Background

Hello, I am relatively new to the PX4 environment and simulation tools on Gazebo. I am trying to simulate a custom airship.
My goal is to duplicate the already available 'cloudship' folder and tweak the model values in the .sdf and airframe file and replace the .stl 3d model in order to control it in Gazebo using QGroundControl.

Procedure

I followed these steps, found on other discussion threads:

  1. Created a folder under Tools/sitl_gazebo/models called 'my_vehicle'.
  2. Created the following files: my_vehicle.sdf and model.config (from 'cloudship').
  3. Added the 'cloudship' .stl files to the folder.
  4. Created an airframe file under ROMFS/px4fmu_common/init.d-posix (from 'cloudship').
  5. Added the new airframe name to the cmakelist file in this folder.

I saw that another required step was to add the airframe/folder name to the platforms/posix/cmake/sitl_target.cmake file but could not locate it in the PX4 directory.

Issues

After rebuilding the environment by entering the 'make px4_sitl_default gazebo' command I try to run the new folder 'my_vehicle' by entering 'make px4_sitl gazebo_my_vehicle' or 'make px4_sitl gazebo-classic_my_vehicle'.
I get the following error : 'unkown target 'gazebo_my_vehicle' and the 'my_vehicle' folder I just created is gone.

Any help would be greatly appreciated,
Thank you,
Luca

Hi @lucaperrin , just perform this steps:

  • Go inside the FW folder
  • Type: make clean
  • Type: make px4_sitl gazebo

Then you are able to do make px4_sitl gazebo_my_vehicle
This works for me