Cascading mixers

Mike Shellim 08 May 2015
Last updated 22 March 2019

Cascading (or chaining) is a great technique for complex models. It avoids unnecessary duplication of mixers, simplifies adjustment, and encourages the use of elegant, hierarchical schemas. It's especially useful for F3X sailplanes.

What is cascading?

Cascading is very simple to describe: it's when the output of a channel is used as the input to another channel. Here's a trivial example:

CH1 is driven by knob S1, and the output of CH1 is cascaded to CH2:-

CH1

src=S1 wt=80

 

CH2

src=CH1, wt=25

The output of CH2 varies, as CH1 varies, as S1 varies.

The weights cascade by multiplication, so
CH2 = CH1 x 25% = S1 x 80% x 25% = S1 x 20%.

So, as S1 is rotated between its end stops:

The MULT operator

Though not strictly part of cascading, another feature we'll use is the MULT operator. The MULT operator is used to multiply mixes within the same channel.

CH1

src=RS, wt=100

src=S1, wt=100, multiplex=MULT

In the example, CH1 = (100% x RS) x (100% x S1) = S1 x S2.

Strictly speaking, the MULT line is multiplied with the result of all the lines above it. For more info on the ADD, MULT and REPL operators, see Key concepts.

Snapflap example

Okay, so let's see how cascading works in practice. We'll use the example of an elevator to flap mix, also known as 'snapflap'. We'll add 35% of the elevator value to the two flap channels.

First, here's the 'brute force' approach without cascading:

CH3 (right flap)

Src=Ele, weight=35

...

 

CH4 (left flap)

Src=Ele, weight=35

...

This works, however there's a drawback: In order to adjust the amount of snapflap, two identical adjustments are needed, one in each channel.

Let's modify the code, isolating the snapflap mix into CH10 and cascading the output to the individual flap servos:

CH10 (snapflap)
Src=Ele, wt=35

 

CH3 (right flap)

Src=CH10, wt=100

 

CH4 (left flap)

Src=CH10, wt=100

Woohoo! CH10 now provides a single point of adjustment for both flaps.

It's good practice to reset the weights in CH3 and CH4 to 100% (remember that weights are multiplied cumulatively as OpenTx progresses through the cascade).

Linkages are never perfect! To achieve equal deflections on the left and right sides, the servos must be calibrated. A calibrated setup is assumed in this article.

Extending snapflap to the ailerons

Let's extend the snapflap to the ailerons:

CH10 (snapflap)
Src=Ele, wt=35

 

CH1 (right aileron)

Src=CH10, wt=100

 

CH2 (left aileron)

Src=CH10, wt=100

 

CH3 (right flap)

Src=CH10, wt=100

 

CH4 (left flap)

Src=CH10, wt=100

This'll work, but there's a limitation: CH10 controls both flaps and ailerons without distinction. In practice, we'll always want separate adjustments, since flap and aileron linkages almost always have different geometry. We do this by allocating a separate high mix for the ailerons:

CH10 (snapflap -> flaps)
Src=Ele, wt=35

 

CH11(snapflap -> ailerons)
Src=Ele, wt=15

 

CH1 (right aileron)

Src=CH11, wt=100

 

CH2 (left aileron)

Src=CH11, wt=100

 

CH3 (right flap)

Src=CH10, wt=100

 

CH4 (left flap)

Src=CH10, wt=100

So now,

Adding a global snapflap adjuster

Say we want to adjust the overall snapflap whilst flying the model. We start by making a volume control based on knob S1:

CH20 (global snapflap adjuster)
Src=S1, wt=50, offset=50

The output of CH20 varies from 0 to 100% as S1 is rotated clockwise - just what we want. To use this as a global adjuster, we cascade the output to CH10 and CH11.

CH20 (global snapflap adjuster)
Src=S1, wt=50, offset=50

 

CH10 (snapflap->flaps)
Src=Ele, wt=35

MULT: Src=CH20

 

CH11 (snapflap->ailerons)

Src=Ele, wt=15

MULT: Src=CH20

 

CH1 (right aileron)

Src=CH11, wt=100

 

CH2 (left aileron)

Src=CH11, wt=100

 

CH3 (right flap)

Src=CH10, wt=100

 

CH4 (left flap)

Src=CH10, wt=100

The MULT operator multiplies the global adjustment (from CH20) with the local adjustments of 35% (flaps) and 15% (ailerons). (Without the MULT operator, the local and global adjustments would be ADDed, which is of course not what we want).

Taking CH10, which controls the snapflap mix to the flaps:

CH10 = CH20 x Ele x 35% = Ele x S1(0-100%) x 35%.

Rotating the global adjuster varies the snapflap mix between 0% and 35%. Similarly the range for the ailerons is 0-15%.

So now, we use the local adjustments to set the travel, and the global adjuster to tune the snapflap in flight.

Floating the MULT upwards

A variation is to move the elevator input to the global adjuster line:

CH20 (global snapflap adjuster)
Src=S1, wt=50, offset=50

MULT: Src=Ele, wt=100

 

CH10 (flaps)
Src=CH20, wt=35

 

CH11 (ailerons)

Src=CH20, wt=15

 

CH1 (right aileron)

Src=CH11, wt=100

 

CH2 (left aileron)

Src=CH11, wt=100

 

CH3 (right flap)

Src=CH10, wt=100

 

CH4 (left flap)

Src=CH10, wt=100

The result is exactly the same as before, but isolating the MULT line at the top layer will make it easier when we add extra mixes.

Extending the schema

Suppose we want to add a camber mix, controlled by slider LS. Ailerons and flaps will be affected, and we'll have a global adjuster (S2).

We can do this using similar code to snapflap:

CH21 (global camber adjuster)
Src=S2, wt=50, offset=50

MULT: Src=LS, wt=100

 

CH20 (global snapflap adjuster)
Src=S1, wt=50, offset=50

MULT Src=Ele, wt=100

 

CH10 (flap mixes)

Src=CH21, wt=20 -- camber
Src=CH20, wt=35 -- snapflap

 

CH11 (aileron mixes)

Src=CH21, wt=7 -- camber

Src=CH20, wt=15 -- snapflap

 

CH1 (right aileron)

Src=CH11, wt=100

 

CH2 (left aileron)

Src=CH11, wt=100

 

CH3 (right flap)

Src=CH10, wt=100

 

CH4 (left flap)

Src=CH10, wt=100

So now CH10 aggregates the camber and snapflap mixes. Note the small number of changes needed!

In practice, snapflap and camber will be active in different flight modes. We can achieve this by applying a flight mode filter as follows:

CH21 (global camber adjuster)

Src=S2, wt=50, offset=50, flightmode='thermal'

MULT: Src=LS, wt=100

 

CH20 (global snapflap adjuster)
Src=S1, wt=50, offset=50, flightmode='speed'

MULT: Src=Ele, wt=100

 

...

...

How does this work? Recall that if a mix is not selected then it's ignored, as if it wasn't there (this is not the same as the mix being active and returning zero!).

So if a flight other than 'thermal' is selected, then CH21 is equivalent to:

CH21 (global camber adjuster)

MULT: Src=LS, wt=100

MULT is applied to the result of all the mixers above it. In this case there are no active lines above, so the result of all the lines above is zero. The value of CH21 is therefore zero, so camber will be zero.

Final tweak: using a GVAR

One final tweak is to put the local adjustments (CH10, CH11) into a GVAR.

...

CH10 (flaps)
Src=CH20, wt=GV1

 

CH11 (ailerons)

Src=CH20, wt=GV2

...

This offers a couple of benefits:

 

Limitations of cascading

There are some rules and limitations to observe when cascading.

In CH10 and CH11 above, the camber and snapflap inputs have the same 'directionality': they move control surfaces in a similar way.

Suppose we wanted to combine an aileron function ('flapperon'). Aileron has a different directionality to camber and snapflap, so we cannot simply add it to CH10 and CH11. Instead, we would need to define additional aggregator channels. Another complicating factor is differential - this must be applied at the level of individual servos.

For more insight, I would recommend having a look at my F3X templates, in particular the XLS reference documentation which contains both the schema and annotations.

 

Hierarchical schemas

In the schema which we've developed in this article, you'll note that there three distinct layers:

Cascading can be extended to other mixes such as reflex and crow brakes. The result is a hierarchy of mixers, fed by sources and inputs, with a calibration layer to deal with linkage differences. This type of schema is economical with mixers and is ideal for F3X models.

 

 

Summary

Let's summarise what's been achieved by employing cascading mixers.