# CAL Mode - a flight mode for calibrating servos

Mike Shellim 4 Dec 2013
Updated 22 Mar 2020

# Introduction to CAL Mode

## What it does

Servo calibration is the process of adjusting the end points and centres of your servos. The purpose is to map the mixer logic to the linkage geometry. In other words, it handles all the inaccuracies you build in during construction!

In order to calibrate your servo end points and centres, it's necessary to generate mixer values of -100, +100 and zero. This is the purpose of CAL mode. When CAL mode is active, all inputs and mixing are suppressed, so the raw stick values in the range -100 to +100 are passed directly to the output. You can then adjust the actual servo deflections via Min and Max. With the stick relaxed, the servo centre position can be adjusted via Subtrim.

The modification is very simple, consisting of (a) single extra mix in each servo channel and (b) assigning a (logical) switch to activate that line.

To implement CAL mode, we simply add a REPLACE mix to each servo channel. This mix must be the last in the channel. Weight = 100%.

Here's an example:

CH 01

[mix 1] ...

[mix 2] ...

[CAL mix] Src=Ele wt=100 Multiplex=REPL Trim=NO Flightmode=FM1

In this example:

• CH1 is calibrated using the elevator stick
• The mix is activated in FM1

When CAL mode (FM1) is active, the channel value will vary between -100 and +100 according to the position of the elevator stick. The servo limits and centre can be adjusted as follows:

• Ele stick back (-100) => servo at lower limit adjustable via Min
• Ele stick at centre (0) => servo at centre. adjustable via Subtrim
• Ele stick forward (100) => servo at upper limit adjustable via Max

## More about the CAL mix

This section explains how to implement CAL mode in more detail.

### Step 1

For each servo channel, add a mixer-line to the end of the mixer list:

• Mixer name = 'CAL'
• Source = [stick used for calibration, see below ]
• Weight = -100 or +100 (see below)
• Offset = 0
• Diff = 0
• Include Trim = No (bypass trims)
• Include DR/Expo = No (bypass rates)
• Flight mode = FM1 (optional, see below)
• Multiplex = 'REPL' (replaces all prior mixer lines above for that channel)

Source is the stick/pot/lever to drive the servo during calibration. It need not be the same as the control used in flight. Specify the raw control only, for example Ele, Ail (do not select inputs like [I1]Ail as these include rates and expo).

It's a good idea to move related surfaces using a single control, so you can equalise their responses visually. For example, here's a typical scheme for a sailplane:

• Aileron stick -> calibrate left/right aileron servos
• Throttle stick -> calibrate left/right flap servos
• Elevator stick -> calibrate elevator servo (X-tail) or left/right V-tail servos (V-tail)
• Rudder stick -> calibrate rudder servo (X-tail only)

### Step 2 - activate using a switch

The CAL lines may be activated directly via a switch, or indirectly via a dedicated flight mode.

The flight mode method has the advantage that the flight mode is displayed on the screen, but requires that you use FM1 (the highest priority mode), so that it's available on demand. If this is inconvenient (maybe you already have flight modes assigned), then the direct switch approach is fine.

Safety note: whichever method you choose, you must use a virtual switch - the last thing you want is to accidentally activate calibration mode in flight!

### Step 3. Set servo rotation and mixer weights

To make the calibration procedure as intuitive as possible, set the DIRECTION of each servo so that:

• A +ve change in MIN, MAX or SUBTRIM moves the control surface up or to the right.
• A -ve change in MIN, MAX, or SUBTRIM moves the surface down or to the left.

The easiest way is to try it and see: go into the servos menu; for each servo, adjust SUBTRIM back and forth, and see which way the control surface is moving. If you reverse the direction of a channel, remember that effect of any mix will be reversed. To correct this, reverse the sign of the wt parameter of all the mixers affecting that channel.

If you've set the direction of rotation as suggested above, then the weights in the CAL mixes should all be set to +100. This will ensure that all surfaces will move in a consistent direction during calibration - this is particularly useful for surfaces, like ailerons and flaps, which have been paired up for calibration.

## Screenshot

Below is a screenshot from OpenTx Companion, showing two aileron channels and the extra CAL lines. The 'R' at the beginning denotes a REPL directive.

# Demo

For OpenTx 2.0, 2.1, 2.2

# calmode.zip

SF-down to activate CAL mode

## Stick calibration

For correct operation of your radio, remember that your sticks must also be properly calibrated as well! This is achieved via the OpenTx hardware calibration menu (Long press Menu -> Page x 8)