Jaeyoung-Lim / mavros_controllers

Aggressive trajectory tracking using mavros for PX4 enabled vehicles
BSD 3-Clause "New" or "Revised" License
400 stars 164 forks source link

Tune for PX4 #229

Open Cavalletta98 opened 1 year ago

Cavalletta98 commented 1 year ago

Hi, which are the parameters for a drone with PX4 fw onboard? I'm using version 1.13.1 of the fw Thanks

Jaeyoung-Lim commented 1 year ago

@Cavalletta98 Not sure if I follow your question.

You need to tune your vehicle and the guidelines can be found in https://docs.px4.io/main/en/config_mc/pid_tuning_guide_multicopter.html

Cavalletta98 commented 1 year ago

I will explain what i'm doing. I'm combining the Fast Planner with PX4 fw in simulation (ROS + gazebo). To do so, i'm using this controller to send the trajectory to the drone. To send the trajectory from Fast Planner to the controller, i'm using this code. The problem is that the drone is jerking at the beginning (before a send a goal). I think the problem could be the parameters of the controller. I'm using this launch file

Jaeyoung-Lim commented 1 year ago

@Cavalletta98 This implementation sends body rate commands to the vehicle. Therefore, you need to tune the rate controller of the vehicle to ensure that the vehicle is capable of tracking the reference before using this package. I have posted the link which explains how to do this in the previous answer

Cavalletta98 commented 1 year ago

Ok,thanks. I Will try to follow it

Jaeyoung-Lim commented 1 year ago

@Cavalletta98 I already posted the link, in my first answer to your question

Cavalletta98 commented 1 year ago

I'm trying to use it but it is not so easy to do it. According to you, do you know a "better" way to use the trajectory of the Fast Planner with px4 fw?