Model-based Control: Difference between revisions

From STorM32-BGC Wiki
Jump to navigation Jump to search
No edit summary
No edit summary
Line 3: Line 3:
The camera is described by the three principal moments of inertia
The camera is described by the three principal moments of inertia


* I<sub>pitch</sub>, I<sub>roll</sub>, I<sub>yaw</sub>
* <i>I<sub>pitch</sub></i>, <i>I<sub>roll</sub></i>, <i>I<sub>yaw</sub></i>
 
:[[File:Gimbal-model-camera-inertias.jpg|none|280px]]


The roll arm is modeled with these moments of inertia
The roll arm is modeled with these moments of inertia


* I<sup>(2)</sup><sub>roll</sub>, I<sup>(2)</sup><sub>yaw</sub>
* <i>I<sup>(2)</sup><sub>roll</sub></i>, <i>I<sup>(2)</sup><sub>yaw</sub></i>


and the yaw arm with
and the yaw arm with


* I<sup>(3)</sup><sub>yaw</sub>
* <i>I<sup>(3)</sup><sub>yaw</sub></i>


In the GUI they are accessible as the {{PARAMNAME|T}} parameters. The model-based PID controller can also take into account different KV values of the pitch, roll and yaw motors via the {{PARAMNAME|K}} parameters.
In the GUI they are accessible as the {{PARAMNAME|T}} parameters. The model-based PID controller can also take into account different KV values of the pitch, roll and yaw motors via the {{PARAMNAME|K}} parameters.
:[File:Gimbal-model-camera-inertias.jpg]


<div class="toclimit-2">__TOC__</div>
<div class="toclimit-2">__TOC__</div>
Line 23: Line 23:
From the perspective of PID control and gimbal axis coupling, the camera should ideally have these properties:
From the perspective of PID control and gimbal axis coupling, the camera should ideally have these properties:


* I<sub>roll</sub> &asymp; I<sub>yaw</sub>
* <i>I<sub>roll</sub></i> &asymp; <i>I<sub>yaw</sub></i>
* I<sub>pitch</sub> &asymp; I<sub>roll</sub>, I<sub>yaw</sub> or I<sub>pitch</sub> << I<sub>roll</sub>, I<sub>yaw</sub>
* <i>I<sub>pitch</sub></i> &asymp; <i>I<sub>roll</sub></i>, <i>I<sub>yaw</sub></i> or <i>I<sub>pitch</sub></i> << <i>I<sub>roll</sub></i>, <i>I<sub>yaw</sub></i>


The first condition is however more important than the second, and should be approached if possible.
The first condition is however more important than the second, and should be approached if possible.


A similar condition I<sup>(2)</sup><sub>yaw</sub> &asymp; I<sup>(2)</sup><sub>pitch</sub> would ideally be also fulfilled for the roll arm, which is however unrealistic in practical builds.
A similar condition <i>I<sup>(2)</sup><sub>yaw</sub></i> &asymp; <i>I<sup>(2)</sup><sub>pitch</sub></i> would ideally be also fulfilled for the roll arm, which is however unrealistic in practical builds.


= Moments of Inertia =
= Moments of Inertia =
Line 36: Line 36:
For a homogeneous solid cuboid it holds
For a homogeneous solid cuboid it holds


I = 1/12 M ( a<sup>2</sup> + b<sup>2</sup> )
<i>I</i> = 1/12 <i>M</i> ( <i>a</i><sup>2</sup> + <i>b</i><sup>2</sup> )


Links:
* https://en.wikipedia.org/wiki/Moment_of_inertia
* https://en.wikipedia.org/wiki/Moment_of_inertia
* https://en.wikipedia.org/wiki/List_of_moments_of_inertia
* https://en.wikipedia.org/wiki/List_of_moments_of_inertia
Line 56: Line 57:
!relative ratio
!relative ratio
|-  
|-  
| pitch || I &prop; 2.5<sup>2</sup> + 5.5<sup>2</sup> = 36.5 ||  1
| pitch || <i>I</i> &prop; 2.5<sup>2</sup> + 5.5<sup>2</sup> = 36.5 ||  1
|-  
|-  
| roll || I &prop; 5.5<sup>2</sup> + 9<sup>2</sup> = 111.25 ||  3.05
| roll || <i>I</i> &prop; 5.5<sup>2</sup> + 9<sup>2</sup> = 111.25 ||  3.05
|-  
|-  
| yaw || I &prop; 2.5<sup>2</sup> + 9<sup>2</sup> = 87.25 ||  2.39
| yaw || <i>I</i> &prop; 2.5<sup>2</sup> + 9<sup>2</sup> = 87.25 ||  2.39
|}
|}


Line 78: Line 79:
!relative ratio
!relative ratio
|-  
|-  
| pitch || I &prop; 2.5<sup>2</sup> + 4.5<sup>2</sup> = 26.5 ||  1
| pitch || <i>I</i> &prop; 2.5<sup>2</sup> + 4.5<sup>2</sup> = 26.5 ||  1
|-  
|-  
| roll || I &prop; 4.5<sup>2</sup> + 6.3<sup>2</sup> = 59.94 || 2.26
| roll || <i>I</i> &prop; 4.5<sup>2</sup> + 6.3<sup>2</sup> = 59.94 || 2.26
|-  
|-  
| yaw || I &prop; 2.5<sup>2</sup> + 6.3<sup>2</sup> = 45.94 ||  1.73
| yaw || <i>I</i> &prop; 2.5<sup>2</sup> + 6.3<sup>2</sup> = 45.94 ||  1.73
|}
|}


Line 100: Line 101:
!relative ratio
!relative ratio
|-  
|-  
| pitch || I &prop; 6<sup>2</sup> + 2<sup>2</sup> = 40 || 1
| pitch || <i>I</i> &prop; 6<sup>2</sup> + 2<sup>2</sup> = 40 || 1
|-  
|-  
| roll || I &prop; 2<sup>2</sup> + 3<sup>2</sup> = 13 ||  0.325
| roll || <i>I</i> &prop; 2<sup>2</sup> + 3<sup>2</sup> = 13 ||  0.325
|-  
|-  
| yaw || I &prop; 6<sup>2</sup> + 3<sup>2</sup> = 45 || 1.125
| yaw || <i>I</i> &prop; 6<sup>2</sup> + 3<sup>2</sup> = 45 || 1.125
|}
|}


As evidenced by these estimates, the shape of the Mobius camera is not ideal from a gimbal control perspective, and this camera is thus more difficult to stabilize than others.
As evidenced by these estimates, the shape of the Mobius camera is not ideal from a gimbal control perspective, and this camera is thus more difficult to stabilize than others.

Revision as of 10:54, 1 October 2019

The STorM32's model-based gimbal control can take into account, to a certain extend, the moments of inertia of the camera, and those of the roll and yaw arms. For the underlying theory see Camera Gimbals: A Robotics Approach.

The camera is described by the three principal moments of inertia

  • Ipitch, Iroll, Iyaw
Gimbal-model-camera-inertias.jpg

The roll arm is modeled with these moments of inertia

  • I(2)roll, I(2)yaw

and the yaw arm with

  • I(3)yaw

In the GUI they are accessible as the T parameters. The model-based PID controller can also take into account different KV values of the pitch, roll and yaw motors via the K parameters.

Ideal Camera Design

From the perspective of PID control and gimbal axis coupling, the camera should ideally have these properties:

  • IrollIyaw
  • IpitchIroll, Iyaw or Ipitch << Iroll, Iyaw

The first condition is however more important than the second, and should be approached if possible.

A similar condition I(2)yawI(2)pitch would ideally be also fulfilled for the roll arm, which is however unrealistic in practical builds.

Moments of Inertia

Estimates for the relative ratios of the moments of inertia of the camera can be obtained by approximating it by a cuboid.

For a homogeneous solid cuboid it holds

I = 1/12 M ( a2 + b2 )

Links:

Camera Panasonic

width height length
2.5 cm 5.5 cm 9 cm
axis approximate moment of inertia relative ratio
pitch I ∝ 2.52 + 5.52 = 36.5 1
roll I ∝ 5.52 + 92 = 111.25 3.05
yaw I ∝ 2.52 + 92 = 87.25 2.39

Camera GoPro Hero5

width height length
2.5 cm 4.5 cm 6.3 cm
axis approximate moment of inertia relative ratio
pitch I ∝ 2.52 + 4.52 = 26.5 1
roll I ∝ 4.52 + 6.32 = 59.94 2.26
yaw I ∝ 2.52 + 6.32 = 45.94 1.73

Camera Mobius

width height length
6 cm 2 cm 3 cm
axis approximate moment of inertia relative ratio
pitch I ∝ 62 + 22 = 40 1
roll I ∝ 22 + 32 = 13 0.325
yaw I ∝ 62 + 32 = 45 1.125

As evidenced by these estimates, the shape of the Mobius camera is not ideal from a gimbal control perspective, and this camera is thus more difficult to stabilize than others.