Define a model for own hexacopter

#1

Hi all,
I am a newby, and I’d like to design my own hexacopter (mounting a Pixhawk 3 PRO). Hence, I want to define my own model for hexacopter for SITL simulation (using Gazebo). I know that I have to define my own sdf model for my hexacopter.
I saw, that in the .sdf file I have to define the mass of the Whole object; in such a way I am assuming that weight is uniformly distributed? What happen if, for example I am mounting a gimbal? Is there a way to define the mass of each part? I am sure that I am wrong something…Could you please help me? Where could I find useful information about this issue? Lastly, I think that best solution could be sitl simulation using gazebo; could be useful tha usage of ROS in such case?

Thank you, and sorry for the certainly stupid questions :slight_smile:

1 Like
#2

@valem To answer your questions,

  1. The weight is not assumed to be uniformly distributed, but we define a interita property in the .sdf file.

  2. For the gimbal, you can add the gimbal as an additional object attacthed to the vehicle.
    For reference, you can look at the Yuneec Typhoon H480 sdf file which also has a gimbal

  3. [quote=“valem, post:1, topic:7980”]
    Lastly, I think that best solution could be sitl simulation using gazebo; could be useful tha usage of ROS in such case?
    [/quote]

I am not sure what the question is here, surely if you could run the simulation on gazebo, it will be useful on ROS

#3

@Jaeyoung-Lim Thank you for the quick reply. I’ll go in the depth in the file.
Now, let’s suppose that I’ll define my own sdf
file and I’ll start the simulation in Gazebo for my own hexacopter I’ve designed.
I suppose to use Gazebo, QGroundControl and PX4.
If simulation were to highlight errors, how could I know where design errors were made?
Sorry for the question, but I would know if such steps would be enough to design my own hexacopter
(or any other drone…)
Thank you in advance.

#4

@valem If you are simply talking about designing a simple hexacopter, it is not necessary to evaluate your design in gazebo.

Gazebo models are not used for evaluating a design of an airframe, but rather if you model the airframe dynamics into gazebo, we can prototype on the software faster. That means, when you model the airframe into gazebo, you need to throughly evaluate whether if the real model is similar to the sdf defined.

Multirotors in general have simple dynamics. This means you can be a little naive on envaulating your design and just try and fly it.

Or am I missing something here that you have a special reason you need to evaluate your design?

#5

Hi @Jaeyoung-Lim , thank you for the quick response and clarification. So I’ll use such kind of simulation (ros+gazebo+px4) in order to just evaluate some firmware modification?
Moreover, if I would like design a custom airframe, what tool do you suggest to use? I try to explain my need: I would like to design my own frame - using Pixhawk/PX4 flight controller, and homogenous distribution of weight is important to evalutate efficiency in the airframe in order to have best performance. What do you suggest to use?
Sorry for the extremely stupid question…but finally, combination of gazebo/pixhawk/px4 is used to evaluate how changes in firmware parameter will affect dynamic? Sorry to be a lot confusing.