Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Quadrotor keeps jumping when flying in altitude mode #12180

Closed
parakhm95 opened this issue Jun 4, 2019 · 3 comments
Closed

Quadrotor keeps jumping when flying in altitude mode #12180

parakhm95 opened this issue Jun 4, 2019 · 3 comments

Comments

@parakhm95
Copy link

parakhm95 commented Jun 4, 2019

Description

The problem occurs in altitude mode whether I switch in-flight or before takeoff. When the robot is taking off, it keep gaining altitude and doesn't come down. If you lower the stick to zero, it keeps climbing but starts jumping in the air. It falls for a few milliseconds and then gains thrust. It keeps repeating this while continuously gaining altitude. Same thing happens if you are flying in manual and you switch to altitude mode.

Reproduction

  1. Switch to altitude mode.
  2. Arm.
  3. Bring throttle to take-off position.
  4. Robot keeps climbing, so you lower the stick to control but nothing happens.
  5. Lower the stick further down to zero, the robot start to jump.
  6. Retake manual control.

Expected behavior
It should just takeoff and hold altitude.

Log Files and Screenshots
https://logs.px4.io/plot_app?log=5ef531fd-d7db-443b-8d76-c330044f0b29
You will clearly see how even when the throttle is at it's lowest position, there are huge spikes in the thrust of the robot as seen in actuator controls.

Drone
The drone is a 165mm quadrotor with 3750kV motors and 3040 Triblade props. It is using a Pixfalcon(also called Pixhawk Mini). The power is supplied by the PDB-ESC Combo.

Additional context
I have used this same setup with Ardupilot stack and it works fine somehow.

@bresch
Copy link
Member

bresch commented Jun 11, 2019

Hi @parakhm95 ,
It looks that you forgot to adjust the hover throttle. Since your vehicle has a higher thrust/weight ratio than usual, you should reduce the hover throttle to about 0.3 (from what I see in your log). The parameter is MPC_THR_HOVER.
As shown in the picture below, the land detector "thinks" the drone is touching the ground since the throttle is low compared to the defined hover throttle. It switches in and out of that "ground contact" state and this is why the throttle is jumping around.
2019-06-11_14-03-16_01_plot

@parakhm95
Copy link
Author

I tried the fix you suggested and yes it works! Thank you so much. This has been stuck for a very long time now.

Also, how did you plot these flags? Are they available on the log review online and need to be enabled or do I have to manually find them in the log?

But it works for sure.

@bresch
Copy link
Member

bresch commented Jun 12, 2019

@parakhm95 I'm glad it worked out! Those flags are not shown on FlightReview (online tool) since you don't need to check them on a regular basis. To see them, you need to open the file using a program such as PlotJuggler.

@bresch bresch closed this as completed Jun 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants