Hold versus Pan Mode

From STorM32-BGC Wiki V1
Jump to navigation Jump to search

by Yang/wdaehn, with edits by OlliW, descriptions refer to firmware v0.95e and later

Generally speaking, two situations can be distinguished as regards the gimbal behavior: The camera should remain stable in relationship to the ground (hold mode) or in relationship to the gimbal frame (pan mode). The STorM32 controller allows you to choose the mode for each of the three axes independently.

What does stabilization mean?

The term "stabilization" can mean different things depending on the application, and on the axis we talk about.

Imagine you have put your camera on a tripod and are now trying to rotate the camera by 360° for a panorama shot. In pan mode the goal is a stabilization in the sense of removing camera shakes but in overall to follow the turn of tripod. In other words, the yaw axis stabilization acts like a virtual tripod. The other type is called hold mode, meaning no matter what you do, the camera will hold its current position. Here, no matter what direction you point at with the tripod, the camera will compensate this movement and will remain static, i.e. hold its initial position relative to the ground.

The parameters to adjust all this are found in the [Pan] tab in the GUI.

Hold versus Pan

Which mode you want for which axis is defined in the Pan Mode Default Setting parameter.

The standard setting is "hold hold pan" in order to lock the camera in pitch and roll but allow yaw movements. This is, for most situations, the appropriate setting: What should happen if you accidentally tilt the camera forward to the ground? Nothing, i.e., the gimbal should compensate this unwanted movement and keep the horizon in the video at the same level. Same thing with the roll axis. Just because you do not hold the gimbal perfectly level, the horizon should tilt to one side? No, the horizon should be kept level. For yaw movements, however, a different behavior is normally desired. If you would have enabled the hold mode for yaw and would turn the gimbal by 180°, you would film the gimbal frame since the camera would remain stable relative to ground. Doesn't make much sense. Instead the camera should have followed the 180° turn, which is achieved by "pan". So, the "hold hold pan" setting does make sense for most cases.

Now imagine a hand-held gimbal used in the mountains. Since the pitch is set to "hold" as default, you would either film the ground or the mountains on the other side of the valley, but not your target maybe 15° higher. One way to adjust the pitch would be via the joystick, which however would be inconvenient. An alternative is to enable pan on the pitch axis, and use "pan hold pan" for the Pan Mode Default Setting parameter. Then the gimbal would dampen any shakes in the pitch axis but in general you can point the camera up and down by moving the gimbal frame.

A completely different example would be a gimbal mounted in an airplane and to record movies from the pilots point of view. When the plane is pointing downwards the camera should look downwards, when the plane is flying a right turn the horizon should tilt. The only task of the gimbal is to remove shakes and allow the "pilot" to look left/right/up/down. That would ask for a Pan Mode Default Setting of "pan pan pan".

Comment: It is strongly advised against using a brushless gimbal as FPV camera! The purpose of the example was just to explain things.


Fine Tuning the Pan Mode

How does the controller differentiate between unwanted shakes versus true movements? In the [Pan] tab the parameters Pitch Pan, Roll Pan and Yaw Pan are found, with which you determine the follow speeds in pan mode for each axis. A zero means that the follow speed is zero, which effectively corresponds to hold mode. A non-zero value enables the pan mode, whereby a larger pan value means a faster following.

Importantly, whether these settings become active or not depends on the Pan Mode Default Setting parameter: If "hold" is specified for an axis there, then this axis will be in hold mode irrespective of the pan speed value. The Pan Mode Default Setting overrule the pan speed setting.



The STorM32 controller provides sophisticated deadband mechanisms, which are controlled through various settings. Generally, these settings are effective only when the respective axis is in pan mode; they do not affect the behavior in hold mode.

The deadband feature allows you to eliminate any camera movement along the selected axis, when the deviation of the camera from the gimbal center falls within a certain angle range, the deadband. That means that the camera will follow the gimbal frame only when the relative angle between camera and gimbal frame is larger than the given deadband.

The details of the mechanism differ for the pitch&roll axes and the yaw axis, and are thus described separately.

Pitch and Roll Deadbands

For the pitch or roll axis the deadband behavior is determined by the Pan Deadband parameter for the respective axis. Depending on whether the deadband is smaller or larger than 15° the "default" or the "plane" pan mode becomes effective:

  • default pan mode (deadband < 15°): The deadband center follows the gimbal frame. This behavior is e.g. appropriate for hand-held gimbals, to stabilize the video at the current camera position.
  • plane pan mode (deadband > 15°): The deadband center is held fixed at the normal forward orientation. This behavior allows one e.g. to prevent that the camera hits some mechanical limits upon too large pitch or roll movements.


Yaw Deadband

The deadband behavior for the yaw axis is determined by the three parameters Yaw Pan Deadband, Yaw Pan Deadband LPF, and Yaw Pan Deadband Hysteresis. In general, the deadband for yaw works like the default pan mode for the pitch/roll axis, but provides for more adjustments in order to offer greater flexibility, but also to "fight" yaw drift.

In contrast to pitch and roll, the gyro drift for yaw cannot be compensated for by the accelerometers. The STorM32 controller is capable of compensating the gyro yaw drift when in pan mode, but it's impossible when in hold mode. Since the deadband works essentially like an angle-controlled transition from hold to pan mode, and vice versa, the situation arises that when the camera is within the deadband (= hold) it drifts slowly towards one edge of the deadband, where the controller switches to pan, which pulls back the camera to within the deadband (=hold), where it drifts to the deadband edge, is pulled back, and so on. This can in unfortunate situations lead to a wiggle in the yaw axis. The Yaw Pan Deadband LPF and Yaw Pan Deadband Hysteresis parameters provide two means to alleviate the situation.

The Yaw Pan Deadband LPF parameter allows to slow down the transition from pan to hold and vice versa. It leads to smooth behavior, and tends to pull the camera into the deadband region, which both helps with the gyro yaw drift. A typical value could be 1.5 secs.

The Pan Deadband Hysteresis parameter helps to avoid the unwanted effects due to the gyro drift by dynamically increasing the effective deadband whenever an axis is within the deadband. A typical value could be 2°.


Switching Between Pan/Hold

Sometimes it might be desirable to switch during a shot from pan to hold or vice versa. The switch can be made via any of the available inputs, selectable in the Pan Mode Control field. The following discusses the use of buttons, as it might be appropriate for hand held gimbals.

Buttons can be connected to the AUX-0, AUX-1, and AUX-2 pins (see Pins and Connectors), which allows you to switch through up to four preset pan modes specified in the parameters Pan Mode Default Setting to Pan Mode Setting #3. Let's consider as example two buttons connected to AUX-0 and AUX-1, respectively, and these settings:

  • Pan Mode Control = "Aux-01 switch" (meaning that buttons are connected to Aux-0 and Aux-1)
  • Pan Mode Default Setting = "hold hold pan"
  • Pan Mode Setting #1 = "hold hold hold"
  • Pan Mode Setting #2 = "pan pan pan"
  • Pan Mode Setting #3 = "pan hold pan"

If none of the two buttons are pressed or switched on, then Pan Mode Default Setting is active, which in our example is "hold hold pan". This means that the pitch and roll axes will be in hold mode, and yaw in pan mode.

If only the button connected to AUX-0 is pressed/switched on, then the Pan Mode Setting #1 becomes active. In our example all three axes are then in hold mode.

If only the button connected to AUX-1 is pressed/switched on, then the Pan Mode Setting #2 is selected and "pan pan pan" would be activated.

Finally, if both buttons are pressed/switched on, then the Pan Mode Setting #3 is selected or "pan hold pan" in our example.

Instead of buttons you of course can choose also any other available input, such as e.g. an PWM input or an PPM input, to switch between the four pan mode settings.


Further Tuning the Pan Mode

The STorM32 controller provides further useful options to adjust the pan behavior, namely the Pan Expo parameters. Again, these settings are effective only when the respective axis is in pan mode, and do not affect the hold mode.

Similar to Pan, the Pan Expo parameter also determines the follow speed, but in contrast to Pan increases the follow speed roughly exponentially with the deviation from the center position. The values can be set from 0% to 100%, where larger values correspond to stronger exponential increase, and 0% disables them. In combination with Pan they provide a large flexibility in adjusting the camera follow behavior upon turns.

The Pan Expo can also be used as a sort of "soft-limiter" to prevent camera lags by too large an angle, e.g., to keep landing skids out of the video or to prevent mechanical damage.


Next Step - Advanced Functions

You have learned now all relevant settings which you need to record great shots in various typical situations. The STorM32-BGC provides however some more powerful possibilities, such as scripts, remote camera control or Bluetooth connectivity. Go ahead, and explore the Advanced Functions chapter.