Good day, I am trying to create a SITL simulation of my own personal drone. I have been able to generate the drone and import the physical parameters of the drone in both the STL file and the airframe configuration file, however, I am still uncertain when it comes to the motor constant .
I know that in both cases: Thrust = CT * u^2
My confusion comes in for what u is in the gazebo STL file and PX4 airframe file respectively. Is it the same in both cases? Currently I have the following ideas of what it can be:
- It could just be the normalized output of PX4, and therefore CT can be approximated as my maximum thrust.
- In Gazebo, it is the actual motor speed in rad/s or rpm
- It is the ESC output, therefore between 0 and 1000
Considering this, I want to also take my question further. I want my simulation to model an actual motor I have. I have the necessary equipment to run test on my motors and obtain their properties. My motor uses DShot600 as the output.
From what I understand DShot has an output between 1000 and 2000, instead of 0 and 1000 as used in the ESC of the gazebo simulation. Can I therefore just shift my DShot control values down by 1000 to obtain an equivalent output as used by the gazebo simulator?