I’m trying to test the newest functionality in ArduSub v3.6.0 beta, especially what is related to setting the desired attitude and depth in alt_hold mode with no GPS. I use Sub-3.6 branch with no modifications.
I have limited access to the robot now, so SITL is looking like the best friend of mine. But, It looks, that SITL simulation for stabilize and alt_hold modes is not working properly from the box. I was able to use manual controls to run Bluerov2 in sitl simulation, however.
MANUAL >> rc all 1500
MANUAL >> arm throtle
Doing whatever I want with “rc ch pwm_value”.
MANUAL >> disarm
MANUAL >> rc all 1500
MANUAL >> mode STABILIZE
At that point, even if I do nothing and all rc are set to 1500 - ROV starts drifting and waving.
The same in alt_hold mode. And the same if I switch to stabilize or alt_hold from the beginning of a simulation.
I attach here logs and parameters I use. Parameters are not modified.
I managed to reproduce this behavior here. Our SITL model is a very simple physical model of the ROV. You can see in the logs that the roll value is amplified over time, that is most likely due to the drag in SITL being too low (the frame oscilates and when tilted the vertical thrusters have an horizontal component). I suggest you try increasing it here.
Among other things, right now SITL is also missing support to the heavy frame and the modeling of the static stability.
Thanks for the answer. I’ll try to increase damping as you have suggested. BTW, have you done any validation study for the model or at least comparison against experimental data? I’d like to know the scenarios in which it actually can be used. This info can save time for me and other users of Bluerov2.
As far as I remember it has to be in rad/s2 units, but this formula suggests that it is N/kg, looks more like linear acceleration to me.
Shall it be somehow connected to the robot’s rotational inertia tensor and connected (water) mass?
You are right, this looks wrong. It was quick and dirty way to add some angular dampening. The SITL overall needs some work and improvements. to do some work on it it during the next few months.
If you have the knowledge and could send a Pull Request to improve this, that would be very welcome!
My mistake. In Depth Hold or Stabilize modes, some drift will likely happen. To keep position in SITL you should try using Position Hold.
If you have the knowledge and could send a Pull Request to improve this, that would be very welcome!
I’d like to, but we do not have localisation system yet, so my update can only address rotational dynamics. If you have datasets recorded for the translation and rotation - please, share. It can helps me a lot to improve current sitl model.