# Issue with Stabilize and Depth Hold flight modes

**URL:** <https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861>\
**Category:** QGroundControl\
**Created:** [March 20, 2017, 8:32pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861 "2017-03-20T20:32:43Z")\
**Posts on this page:** 20\
**Page:** 2

<div class="post-metadata">

**Author:** ![tciii](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/tciii/32/673_2.png) [@tciii](https://discuss.bluerobotics.com/u/tciii)\
**Post date:** [December 7, 2018, 3:04pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/21 "2018-12-07T15:04:23Z")

</div>

@geraldof1975,

It is interesting that you began to experience problems with the Depth Hold mode since you calibrated your accel/compass sensors.

I believe that Depth Hold is controlled by the Bar30 High Resolution 300m Depth/Pressure Sensor and should not be affected by the accel/compass sensor calibration.

You might want to try and recalibrate the Depth/Pressure Sensor to see if that will cure you Depth Hold mode issue.

Regards,  
TCIII AVD

---

<div class="post-metadata">

**Author:** ![geraldof1975](https://avatars.discourse-cdn.com/v4/letter/g/bc8723/32.png) [@geraldof1975](https://discuss.bluerobotics.com/u/geraldof1975)\
**Post date:** [December 7, 2018, 4:52pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/23 "2018-12-07T16:52:23Z")

</div>

Hi TCIII,

We bought two BlueRov2 and we already changed the pixhawk and the depth sensor and it continues with the same problem.

When I trigger the depth mode, it speeds the vertical thrusters down, but if I tilt the rov nose at 45 degrees down, the vertical thrusters stop.

I can not understand, since I did all the calibration procedures.

Regards,

Geraldo

---

<div class="post-metadata">

**Author:** ![tciii](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/tciii/32/673_2.png) [@tciii](https://discuss.bluerobotics.com/u/tciii)\
**Post date:** [December 7, 2018, 8:00pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/24 "2018-12-07T20:00:38Z")

</div>

@geraldof1975,

What is your depth reading on the surface?

Regards,  
TCIII AVD

---

<div class="post-metadata">

**Author:** ![geraldof1975](https://avatars.discourse-cdn.com/v4/letter/g/bc8723/32.png) [@geraldof1975](https://discuss.bluerobotics.com/u/geraldof1975)\
**Post date:** [December 7, 2018, 8:11pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/25 "2018-12-07T20:11:38Z")

</div>

zero meters.

Regards,  
Geraldo

---

<div class="post-metadata">

**Author:** ![jwalser](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/jwalser/32/2234_2.png) [@jwalser](https://discuss.bluerobotics.com/u/jwalser)\
**Post date:** [December 7, 2018, 11:19pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/26 "2018-12-07T23:19:04Z")

</div>

@geraldof1975 Please review the software setup [instructions](http://docs.bluerobotics.com/brov2/software-setup/), in particular the configure motor directions step.

---

<div class="post-metadata">

**Author:** ![geraldof1975](https://avatars.discourse-cdn.com/v4/letter/g/bc8723/32.png) [@geraldof1975](https://discuss.bluerobotics.com/u/geraldof1975)\
**Post date:** [December 10, 2018, 12:09pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/27 "2018-12-10T12:09:25Z")

</div>

Good morning, Jacob.

Regardless of the direction of the vertical thrusters, when triggering the automatic depth out of water with the depth sensor zeroed, vertical thrusters should not operate.

Am I forgetting something?

 ![IMG_20181210_095713476~2%5B1%5D](https://us1.discourse-cdn.com/flex019/uploads/bluerobotics/original/2X/9/9b9690ad719702c50aced4708422db71a73d93a7.jpeg)

Regards,

Geraldo

---

<div class="post-metadata">

**Author:** ![jwalser](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/jwalser/32/2234_2.png) [@jwalser](https://discuss.bluerobotics.com/u/jwalser)\
**Post date:** [December 10, 2018, 5:25pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/28 "2018-12-10T17:25:30Z")

</div>

> [@geraldof1975](#):
>
> Regardless of the direction of the vertical thrusters, when triggering the automatic depth out of water with the depth sensor zeroed, vertical thrusters should not operate.

This is incorrect. The expected behavior when operating a stabilized mode in air is for the motors to spin.

---

<div class="post-metadata">

**Author:** ![geraldof1975](https://avatars.discourse-cdn.com/v4/letter/g/bc8723/32.png) [@geraldof1975](https://discuss.bluerobotics.com/u/geraldof1975)\
**Post date:** [December 10, 2018, 5:46pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/29 "2018-12-10T17:46:41Z")

</div>

Jacob,

My problem is not with the stabilization but with the automatic depth.  
Stabilization is working properly.

Regards

Geraldo

---

<div class="post-metadata">

**Author:** ![jwalser](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/jwalser/32/2234_2.png) [@jwalser](https://discuss.bluerobotics.com/u/jwalser)\
**Post date:** [December 10, 2018, 5:48pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/30 "2018-12-10T17:48:21Z")

</div>

I replied to your (incorrect) point about testing ‘out of water’.  
Have you tested this in water?

---

<div class="post-metadata">

**Author:** ![geraldof1975](https://avatars.discourse-cdn.com/v4/letter/g/bc8723/32.png) [@geraldof1975](https://discuss.bluerobotics.com/u/geraldof1975)\
**Post date:** [December 10, 2018, 5:52pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/31 "2018-12-10T17:52:31Z")

</div>

Yes, I already tested it inside the pool and the problem is in the automatic depth that, when triggered, is triggering the vertical thrusters to the bottom of the pool.

An interesting detail, when I turn on the automatic depth and the verticals begin to rotate, I tilt the rov 45 degrees with the nose down and the verticals stop turning.

What can it be?

Geraldo

---

<div class="post-metadata">

**Author:** ![jwalser](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/jwalser/32/2234_2.png) [@jwalser](https://discuss.bluerobotics.com/u/jwalser)\
**Post date:** [December 10, 2018, 5:56pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/32 "2018-12-10T17:56:58Z")

</div>

> [@geraldof1975](#):
>
> An interesting detail, when I turn on the automatic depth and the verticals begin to rotate, I tilt the rov 45 degrees with the nose down and the verticals stop turning.

Is this on the bench out of water, or in water?

> [@geraldof1975](#):
>
> What can it be?

It is most likely the software setup for the direction of the thrusters is incorrect. Please try to reverse the direction of motors 5 and 6.

---

<div class="post-metadata">

**Author:** ![geraldof1975](https://avatars.discourse-cdn.com/v4/letter/g/bc8723/32.png) [@geraldof1975](https://discuss.bluerobotics.com/u/geraldof1975)\
**Post date:** [December 10, 2018, 6:02pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/33 "2018-12-10T18:02:15Z")

</div>

> [@jwalser](#):
>
> Is this on the bench out of water, or in water?

The tests are now being made out of water. In the lab.

> [@jwalser](#):
>
> It is most likely the software setup for the direction of the thrusters is incorrect. Please try to reverse the direction of motors 5 and 6.

Without the use of automatic depth, thrusters 5 and 6 work correctly.

---

<div class="post-metadata">

**Author:** ![geraldof1975](https://avatars.discourse-cdn.com/v4/letter/g/bc8723/32.png) [@geraldof1975](https://discuss.bluerobotics.com/u/geraldof1975)\
**Post date:** [December 10, 2018, 6:17pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/34 "2018-12-10T18:17:18Z")

</div>

We reverse the propellers of thrusters 2 and 4 to avoid there being a twist in the frame or until the rov drifts when it goes forward.  
The thruster 5 was reversed because the rotation was to the same side of the thruster 6.

Regards,

Geraldo

---

<div class="post-metadata">

**Author:** ![jwalser](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/jwalser/32/2234_2.png) [@jwalser](https://discuss.bluerobotics.com/u/jwalser)\
**Post date:** [December 11, 2018, 8:39pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/35 "2018-12-11T20:39:08Z")

</div>

Geraldo, You should not try to test the STABILIZE mode or the DEPTH HOLD mode when the ROV is sitting in the air. The motors will always turn if this is the case. To use or test these modes, the ROV must be in the water.

When the ROV is in the water, if DEPTH HOLD makes the rov go up or down quickly, it means that the motor direction is incorrect. Then you should change the direction of motors 5 and 6, and try to use depth hold again while the ROV is **in the water**.

Please follow the instructions on the motor setup page carefully. If you believe there is some other problem, please make a video demonstrating that it does not work with the motors 5 and 6 in either configuration.

---

<div class="post-metadata">

**Author:** ![geraldof1975](https://avatars.discourse-cdn.com/v4/letter/g/bc8723/32.png) [@geraldof1975](https://discuss.bluerobotics.com/u/geraldof1975)\
**Post date:** [December 11, 2018, 9:03pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/36 "2018-12-11T21:03:04Z")

</div>

All right, Jacob. I understood what you meant

But do not you agree that vertical thrusters, even in the air, when triggered the automatic depth, should they not stand still, whether they are inverted or not?  
There is no variation of the depth sensor!  
Are there other sensors that work with Depth Hold?

What I find strange now is to put the ROV at 45 degrees and the vertical thrusters stop and when I change the value of the depth sensor in that position, it works normally.

Regards,

Geraldo

---

<div class="post-metadata">

**Author:** ![jwalser](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/jwalser/32/2234_2.png) [@jwalser](https://discuss.bluerobotics.com/u/jwalser)\
**Post date:** [December 11, 2018, 9:05pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/37 "2018-12-11T21:05:39Z")

</div>

> [@geraldof1975](#):
>
> There is no variation of the depth sensor!

There is variation of the depth sensor (maybe a smaller decimal place than the display in QGC), as well as the IMU sensors, which the ROV combines all this information to find “how deep am I”. The ROV will try to correct for even a fraction of a centimeter. Not only do the verticals run for depth, but they also run to correct the roll angle. And this will try to correct for even a fraction of a degree out of ‘perfectly level’. This is why the motors spin in air, and this is why they are expected to spin (because the output does not help to correct the error), and that’s ok.

---

<div class="post-metadata">

**Author:** ![geraldof1975](https://avatars.discourse-cdn.com/v4/letter/g/bc8723/32.png) [@geraldof1975](https://discuss.bluerobotics.com/u/geraldof1975)\
**Post date:** [December 12, 2018, 2:39pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/38 "2018-12-12T14:39:25Z")

</div>

But what about the fact that the vertical ones stop working when the rov is tilted to 45 degrees?

Could it be due to being out of water too?

Geraldo

---

<div class="post-metadata">

**Author:** ![jwalser](https://sea1.discourse-cdn.com/flex019/user_avatar/discuss.bluerobotics.com/jwalser/32/2234_2.png) [@jwalser](https://discuss.bluerobotics.com/u/jwalser)\
**Post date:** [December 12, 2018, 2:53pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/39 "2018-12-12T14:53:16Z")

</div>

It is a result of the closed loop control algorithm and the feedback that the ROV received from the sensors. When you tilted it forward, you probably leveled it on the roll axis.

---

<div class="post-metadata">

**Author:** ![geraldof1975](https://avatars.discourse-cdn.com/v4/letter/g/bc8723/32.png) [@geraldof1975](https://discuss.bluerobotics.com/u/geraldof1975)\
**Post date:** [December 12, 2018, 5:57pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/40 "2018-12-12T17:57:29Z")

</div>

Got it, Jacob!

When I turn the vertical, it works, but when I put my finger on the depth sensor, it stops.

I think this solves the problem.

Thanks for the patience with me. hehe

Geraldo

---

<div class="post-metadata">

**Author:** ![geraldof1975](https://avatars.discourse-cdn.com/v4/letter/g/bc8723/32.png) [@geraldof1975](https://discuss.bluerobotics.com/u/geraldof1975)\
**Post date:** [December 13, 2018, 1:15pm UTC](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861/41 "2018-12-13T13:15:00Z")

</div>

Jacob,

I will leave some suggestions for future implementation in the software.

1 - Possibility to use only the depth sensor in the Depth Hold (Since that ROVs are naturally roll and pitch stable in water it does not need to use accelerometers readings to compute Depth Hold, just the pressure and sonar altimeter if installed);

2 - Possibility to use Depth Hold and Stabilize together, with specific buttons to disable them.

Best Regards,

Geraldo

[Previous page](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861.md?page=1)

[Next page](https://discuss.bluerobotics.com/t/issue-with-stabilize-and-depth-hold-flight-modes/861.md?page=3)
