Servo setup & Servo mixing - heliflight3d/heliflight GitHub Wiki
Heliflight uses an internal mixer to combine various inputs to drive the motor(s) and servos on your helicopter. It can be called by typing "mixer" in the Configurator's Command Line Interface (CLI).
The inputs to the mixer can be direct radio control (RC) commands, stabilized inputs from our PID controller, or the motor governor code. Those inputs will then be scaled and directed to various outputs like servos and motors. We will discuss the servo mixing first, and later the motor mixing.
It is important to note that the mixer uses custom rules that have a rule number associated with them, and that there are a maximum of 32 mixer rules. The mixer rules are evaluated in numerical order, but since the basic mixer rules we use just add values together the order of the rules is not really important. In this case the rule number is just there so you can remove or overwrite an existing rule by referencing it with it's rule number.
The code that drives the servos occurs in two parts. The first part of the code is the Mixer that we just discussed. The mixer applies each mixing rule in order, and any rule can apply any input value to a servo or motor output with a weighting factor. The mixer then takes the final servo position calculation after all the rules have been executed and sends that value to the output for each servo or motor. This second part of the code is the Servo output. Servo outputs are the PWM outputs (driven by timers) that are assigned to a pin on the STM32 microcontroller. They allow us to reverse servos, trim their center positions, and set min/max limits for the end position of each servo. Servo outputs are numbered starting with the first servo as Servo 1.
For typical Heliflight use, the servo outputs start with "1" and go up to "4", with the outputs typically being elevator, left aileron, right aileron, and tail. The mixer can be configured to output any set of inputs to any servo number, but for easier analysis of blackbox logs it is recommended to retain the servo numbering described above: 1=Elevator, 2=Left Aileron, 3=Right Aileron, 4=Tail (if a tail servo is used)
- It is important that you setup the initial servo min/max/center parameters before connecting your servos to Heliflight and powering them on, as improper output commands for an extended period of time could cause some servos to be damaged.
- Rebooting the flight controller via USB can lead to some pins being left with unknown output states. If the servos are powered up while rebooting the flight controller via USB, sometimes this can result in the servos being driven to their maximum or minimum positions and binding there. If you know why this happens and have an idea to fix it, then please submit a Pull Request with the fix! Try to avoid this if possible by removing power from the servo bus while rebooting the flight controller via USB. In general it is also a bad idea to have the ESC powered up while in the Command Line Interface, as certain CLI commands can send PWM outputs to the ESC as well. At least disconnect two motor wires or remove the blades if you must change or test something in the CLI with the ESC powered up.
The servo outputs for Heliflight are defined using the resource SERVO <servo #> <pin>
command. This tells Heliflight what servos are assigned to which pins on the STM32 microcontroller. Each servo output pin must have a timer channel associated with it. Please see the Wiki page on Resource Assignments for more guidance on assigning servo pins and timers.
Servo output resources are assigned using numbers starting with 1. This means that "SERVO 1" is the first servo, "SERVO 2" is the second servo, and so on. For a 3-servo swashplate, the "SERVO 1" output pin should be connected to the Elevator servo. The "SERVO 2" output should be connected to the Aileron servo on the Left side, and the "SERVO 3" output should be connected to the Aileron servo on the Right side of the helicopter (looking at the helicopter from behind).
The "SERVO 4" output pin should be connected to the tail servo for helicopters with a variable pitch tail. Helicopters with fixed-pitch direct motor-driven tails will not use Servo 4. Set the servo 4 resource to "none" with: resource SERVO 4 none
Servo update frequency is set with the servo_pwm_rate
command. At this time all servos share the same update frequency (including the tail servo), so most likely you will need to set the servo update frequency to the upper limit of your cyclic servos. Typically this is in the 200-333Hz range for modern digital cyclic servos.
set servo_pwm_rate = 333
Servo output min/max limits and center position are set with the "servo" CLI command.
The syntax of the servo command is: servo <servo #> <min us> <max us> <center us> <rate> <lpf frequency> <center trim us>
Rate is initially set to 1000 and the next to last parameter (low pass filter frequency) is always 0. The low-pass filter can be used to slow down the servo outputs for twitchy mixer inputs, but it is not a recommended configuration. In the Heliflight code the servo rate setting is divided by two and then multiplied by the output of our mixer (which is in the range of +/- 1.0) to calculate the desired servo output in microseconds. This rate multiplication means that later on we can use negative rates (-1000 for example) to reverse a servo's rotation for a given mixer output.
Example servo settings for 1520us center cyclic servos and 760us center tail servo:
# servo
servo 1 1020 2020 1520 1000 0 0
servo 2 1020 2020 1520 1000 0 0
servo 3 1020 2020 1520 1000 0 0
servo 4 560 960 760 1000 0 0
Make the necessary modifications to these servo commands as appropriate for your cyclic and tail servos, and then enter them into the Configurator's Command Line Interface (CLI).
Initially you should set the servo outputs limits to the maximum range of your servos (center +/- 500uS), similar to how they are set above. Later when the helicopter is nearing final setup we can adjust the servo output limits to prevent binding.
The main process flow for Heliflight is actually pretty simple. The "rc" or "radio control" tasks take the roll, pitch, yaw values from the receiver, convert them into a setpoint value using the RC Rate settings, and then pass those setpoints on to the PID controller task. The PID controller task then compares these RC setpoint rates to the movement sensed by the gyro (called the gyro rate) on the roll, pitch, and yaw axis. The difference between the setpoint rate and the gyro rate becomes the "error rate" that the PID controller uses to calculate the amount of correction needed on the roll, pitch, and yaw axis. The calculated correction is then assigned as the "inputs" to the mixer for the roll, pitch, and yaw inputs. The Collective input to the mixer comes directly from the RC (radio control) code.
The task of the mixer
is then to take these inputs from the PID controller and convert them into the actual servo outputs. This process is called Cyclic-Collective Pitch Mixing (CCPM). The servo layout / servo arrangement around the swashplate results in a geometry that corresponds to different percentage of input that needs to be assigned to each servo from each input channel. In Heliflight these mixing ratios are called "rates". Each mixer rule takes the input from a single input channel and assigns a percentage of that input to a single servo based on the "rate" assigned in that rule. The "rate" can be a positive or negative number that is normally set between -1000 and +1000. The rate value is effectively a percentage of the input that gets mixed into the output servo.
During each internal loop of the flight controller the mixer evaluates each of the mixing commands in sequence, calculates the servo outputs for each command, and then sums up the outputs for each servo at the end. This summed output value for each servo is then added (or subtracted if the rate is negative) to the center position of that servo and sent to the servo output.
As an example of mixer settings, for a 120-degree servo arrangement you will have 100% of the pitch (elevator) channel input assigned to the elevator servo and 50% of the pitch channel input assigned to each of the aileron servos. The Roll channel will be assigned with a "rate" of 87% to each of the aileron servos, and no assignment to the elevator servo. The Collective input channel will be assigned 100% to the elevator servo and 50% to each of the aileron servos.
The mixer rule parameters for Heliflight are: mixer rule <rule #> <action> <source> <destination> <offset> <rate> <min> <max>
Mixer rule actions can be any of the following: set to a fixed value (set), add to any other rules (add), or multiply the result (mul). Note that when using actions other than "add" the order of operations (rule numbers) may impact the final output for that particular mixer input and output pair.
Mixer rule input sources are referred to by short names such as G1, SR, CR, etc. The stabilized inputs are from the PID controller, while the RCCMD inputs are raw radio control values (scaled to +/- 1000 from the original +/- 500uS) straight from the receiver. Valid input sources for a mixer rule are:
[MIXER_IN_GOVERNOR_MAIN] = "G1"
[MIXER_IN_GOVERNOR_TAIL] = "G2"
[MIXER_IN_STABILIZED_ROLL] = "SR"
[MIXER_IN_STABILIZED_PITCH] = "SP
[MIXER_IN_STABILIZED_YAW] = "SY"
[MIXER_IN_STABILIZED_THROTTLE] = "ST"
[MIXER_IN_STABILIZED_COLLECTIVE] = "SC"
[MIXER_IN_RCCMD_ROLL] = "CR"
[MIXER_IN_RCCMD_PITCH] = "CP"
[MIXER_IN_RCCMD_YAW] = "CY"
[MIXER_IN_RCCMD_THROTTLE] = "CT"
[MIXER_IN_RCCMD_COLLECTIVE] = "CC"
[MIXER_IN_RCDATA_0] = "Ch1"
[MIXER_IN_RCDATA_1] = "Ch2"
… etc for the remainder of the channels.
Mixer rule destinations can be any of the servos, or motor 1 or motor 2. Short names are used for each, including "S1", "S2", "S3", "S4", "S5", "S6", "S7", "S8", "M1", or "M2".
Typical mixer settings for 120-degree CCPM and a servo-controlled variable pitch tail would then look like this:
# Rules i OP SRC DST OFF RATE MIN MAX
#-------------------------------------------------
mixer rule 0 add SC S1 0 1000 -1000 1000
mixer rule 1 add SC S2 0 1000 -1000 1000
mixer rule 2 add SC S3 0 1000 -1000 1000
mixer rule 3 add SR S2 0 877 -1000 1000
mixer rule 4 add SR S3 0 -877 -1000 1000
mixer rule 5 add SP S1 0 1000 -1000 1000
mixer rule 6 add SP S2 0 -500 -1000 1000
mixer rule 7 add SP S3 0 -500 -1000 1000
mixer rule 8 set SY S4 0 750 -1000 1000
mixer rule 9 set G1 M1 0 1000 0 1000
You will need to save
any changed smix settings in the CLI before they are used by Heliflight. Do this before continuing setup any further!
Mixer notes:
- Heliflight currently includes a "swash ring" calculation by default. This calculation limits the maximum combined deflection for the roll and pitch axes to the total pidsum_limit. It does this by scaling down the inputs from the PID controller on each axis until the sum of their squares equals the pidsum_limit. There is no swash ring applied to the input RC commands.
- Mixing in Heliflight has changed substantially from Betaflight. The old Betaflight documentation will just make things more confusing, so please do not reference it (or any other old videos/explanations on how to setup mixing on Betaflight).
- Before attempting to go any further with the servo setup you will need to ensure that your receiver is setup correctly. Please search and follow tutorials on how to properly setup your receiver in Betaflight. You must ensure that the limits (1000-2000) are setup correctly and that stick movements on the transmitter reflect properly on the 3D model displayed on the Receiver tab of Configurator. If your stick movements do not rotate the craft correctly, then do not proceed until you have fixed this! Finally, you must ensure that moving the collective stick up INCREASES the RC command value shown on the screen for channel AUX1/Collective. Reverse the collective channel on your transmitter if necessary to ensure that the AUX1/Collective channel operates properly. If your transmitter’s collective stick controls AUX2 instead of AUX1, then the channel mapping in Heliflight can be changed in the Receiver tab of Configurator for JR/Spektrum/etc.
- It is also imperative that you have verified the gyro orientation/rotation settings are correct by observing the model in the main Configurator screen as you rotate the flight controller board (or helicopter if the flight controller is already mounted). The 3D model on the screen MUST rotate exactly as the board is rotating in real life, otherwise the stabilization and rescue functionality will crash the helicopter instead of keeping it stabilized. If you have not yet mounted the FC board in the helicopter, make sure you test this in the same orientation that you intend to mount it in!
As with any helicopter head setup, it is best if each cyclic servo arm is installed properly. Since nearly all newer helicopters have vertically mounted servos, this means that the servo arm should sit at 90 degrees to the servo case with the servo centered. In order to force the servos to remain stationary you will need to override the servo mixer inputs that are driven by the outputs from the PID controller and Collective RC command. Heliflight has a CLI command to facilitate this process. Simply type this into the CLI:
mixer override all 0
The "0" value tells the mixer to set the override values to "0". This will be set force our servos to their "center" or neutral setting value. Now install the arm as close to 90 degrees as possible.
Next you can tweak the center position of the servo to make the arm sit at 90-degrees to the servo case using the servo trim <servo #> <value>
. Trim values can be positive or negative. Adjust the trim value until you achieve the desired arm position. A "perfect" servo setup will be off by no more than one half of a spline on the servo arm (generally around 7.5 degrees of arm rotation), resulting in a servo trim value of no more than +/- 50 or so. If the helicopter has much more collective+cyclic pitch available than you desire to use, then using higher trim values are not a problem.
save
your work when you are done.
In order to get the swashplate responding correctly to the mixer outputs, it will probably be necessary to reverse the direction of some of the servo outputs. This can be done by using a negative servo rate instead of a positive servo rate, but there is a helpful servo reverse command to do this work for you. The best way to figure out which servos need to be reversed is to setup your mixer rules with a default mixing for your servo geometry (e.g. 120-degree as shown earlier) and then power up the servos.
Now we are going to overrride the collective input to the mixer so that we can ensure the swashplate is adding positive pitch to the main blades. Type these commands into the CLI: mixer override all 0
and then mixer override SC 500
. Now, use the CLI command servo reverse <servo #>
until all of the servos are moving the swashplate in the correct direction to add positive main blade pitch. On most helicopters the swashplate should move up for positive pitch, although there are some notable exceptions like the Raptor E700 where the swashplate moves down to add positive pitch.
Now we can remove the mixer override with mixer override all off
Once the collective smix rules have the correct sign you can evaluate the servo movement for roll, pitch, and collective stick inputs. Move the roll axis stick on the transmitter left and right. If you observe the swashplate tilting in the wrong direction, you should first check the notes above and ensure that your radio inputs to Heliflight are moving in the correct direction. If that is all correct, then it is possible that you need to reverse the mixer scaling for this input, but please ask on Discord before proceeding further.
For the yaw axis, you will need to rotate the main shaft in the correct rotation direction for the main blades and observe the direction of rotation of the tail blade grips. You are looking to find the side of the tail blade grips that will be the leading edge. Then, when you give a yaw command the tail servo will turn the tail blade grips to create pitch in the tail blades. Observe the movement of the leading edge of the the tail blade grips. The leading edge will effectively be "pulling" the tail in that direction. If you give right yaw on the stick you should observe the leading edge of the tail blade grip rotating such that the tail will be pulled left and the helicopter will rotate clockwise. If the blade grips rotate in the opposite direction, just type into the CLI: mixscale SY -1000
in order to reverse the stabilized yaw output. It is also worth noting here that Heliflight currently only supports helicopters with clockwise main blade rotation. This should be easily fixable in the source code, but no configuration parameter has been made yet. The main problem is that all of the Yaw feedforward compensations will be in the wrong direction for helicopters with counter-clockwise main blade rotation.
At this point you should have all of your servo directions set correctly. Please do not deviate from the proper setup described above. Your helicopter will either crash instantly, or will crash instantly when the Rescue feature is used. Either one will be bad.
save
your work when you are done.
Since we already verified the servo arms were setup at 90 degrees in an earlier step, now we can level the swashplate. P.I.Engineer has made an excellent video showing easy ways that this can be checked using a zip tie and tools you already have lying around: https://www.youtube.com/watch?v=fGcu8SjIab4It
It is always best to achieve a level swashplate by adjusting the length of the linkage arms connecting the servo to the swashplate. Set the links initially to the distance recommended by the manufacturer, and then adjust each one until you have a level swashplate. If the links are not easily adjustable or if it or if you are feeling exceptionally lazy, you can also adjust the the trim position on each servo up or down to level the swashplate also. This is not ideal because it adds additional non-linearity to cyclic and collective changes, but small amounts are fine to use if needed.
Use the command servo trim <servo #> <trim value>
to adjust the center trim of a servo. Positive trim values will move that corner of the swashplate towards positive pitch (usually up), and negative trim values will move that corner of the swashplate towards negative pitch (usually down).
Reference P.I.Engineer's video again to see how to check the swashplate zero collective pitch position. Adjust the swashplate to blade grip arm linkage length for each blade grip to set zero pitch on each blade grip. Fine adjustments up/down can be done in software by using servo trim cyclic <offset>
where offset can be positive or negative. This will add or subtract trim to all three of the cyclic servos at the same time. Note that this will not work for a 4 servo swash at this time - you would need to add or subtract the trim to each servo using the servo
command.
save
your configuration before you proceed further.
Now that we have the head linkages all setup properly, we should adjust each servo to it's minimum and maximum positions before binding occurs. Binding can be due to any number of reasons, and it is best if we prevent this from occurring by limiting the maximum possible servo travel. To do this we will use the "mixer override" and "servo override" CLI commands to find the maximum limits before binding occurs.
In order to set the servo limits you will need to override the servo mixer inputs that are driven by the outputs from the PID controller and Collective RC command. Heliflight has a CLI command to facilitate this process. Simply type this into the CLI: mixer override all 0
. The "0" value tells the mixer to set the override values to "0". This will be set our servos to the "center" or neutral value.
Now you can adjust the position of each servo using the "servo override" CLI command. Type servo status
to see the current position of each servo. Then type servo override <servo #> <value>
to move the servo to a new position. The value is the raw microsecond output value that the servo output will be set to. First adjust this value up from 1520 until the servo just begins to bind (usually around 2020), and then back it off just a bit. If you reach the original maximum values with binding, then you don't need to adjust the min or max limit for this servo.
You can rapidly change the servo override value by first setting it in the CLI and then using the up-arrow key on your keyboard to bring the previous command back up. Simply backspace 2-3 times and then type in the new setting you want, hit enter, and repeat until you find the position that begins to bind. Note that the servo override
command will not drive a servo past the output limit configured with the servo
command discussed above. That is why you need to be sure that the output limits are initially set to the manufacturer's specified limits for your servos before you begin finding the min/max values appropriate for your particular helicopter.
Once you have found the maximum override value without binding for this servo, note that value. Then do the same, adjusting down from 1520 until you find the lower limit (usually around 1020). Now that you have found the max and min limits without binding, use the servo
command discussed earlier to permanently set the min and max values for each servo output.
After finding the minimum and maximum servo limits, your new servo settings might be something like:
servo 1 1020 2020 1520 1000 0 0
servo 2 1070 1870 1520 1000 0 0
servo 3 1170 1970 1520 1000 0 0
Use servo override all off
when you are finished in order to allow the servos to go back to their center position.
Save your work in the CLI using the "save" command.
Now we need to setup our cyclic pitch reference so that Heliflight knows what amount of input to the mixer will give 8 degrees of cyclic pitch. We will do this by overriding the mixer input for the roll channel to a value of 666 (66.6% of typical maximum) and then adjusting our mixer scaling for that input until we achieve 8 degrees of cyclic pitch. First, override all of the mixer inputs by typing this into the CLI:
mixer override all 0
Now override the stabilized roll input to the mixer and set it to 66.6%:
mixer override SR 666
Measure the amount of cyclic pitch. If it is above 8 degrees, you are going to adjust the mixer scaling for the stabilized roll channel down from the default of 1000. If it is below 8 degrees, you are going to adjust the mixer scaling for the stabilized roll channel up from the default of 1000. Adjust this value until you achieve 8 degrees of cyclic pitch.
mixscale SR <value>
Now do this process for the pitch channel by removing the override on the roll input and then repeating the steps above for the Stabilized Pitch channel (SP):
mixer override SR 0
mixer override SP 666
mixscale SP <value>
Once you have set the cyclic references using mixscale, we will set the maximum cyclic pitch available to Heliflight. Reset the mixer overrides first by typing mixer override all 0
into the CLI.
Do not adjust the mixscale SR
or mixscale SP
values after this point, otherwise your PID controller settings and maximum cyclic pitch will all be affected.
The maximum cyclic pitch will affect the maximum roll and pitch rates your helicopter will be able to achieve. Keep in mind that Heliflight also looks at your RC (radio control) rate settings to determine what amount of roll and pitch you are commanding from the transmitter, so if you have a low maximum RC rate setting then the helicopter will never roll or pitch faster than that (except during a rescue, which will always use up to the maximum cyclic pitch available).
The maximum cyclic pitch is set using the set pidsum_limit = <value>
setting. By default this is set to 500
, which corresponds to a mixer input of 1000. Yes, we are aware that it is confusing that a pidsum of 500 corresponds to a mixer input of 1000, but for now that is just the way it is. So just keep in mind that whatever mixer input override value we use to find the maximum collective pitch, we are going to divide that in half when we set the pidsum_limit.
You can adjust the maximum cyclic pitch using the roll or the pitch channel since pidsum_limit applies to both of them. Go ahead and override either the stabilized roll (SR) or (SP) channels to 1000 like so: mixer override SR 1000
or mixer override SP 1000
Now measure the amount of cyclic pitch at the blades (P.I.Engineer video). Adjust mixer override SR <value>
until you achieve the maximum cyclic pitch that you desire. Usually this is around 12 degrees by default.
Once you have found the value that achieves your desired cyclic pitch, go ahead and set the pidsum limit to half of this value. So if the mixer override value you found was 950, set the pidsum_limit like this: set pidsum_limit 425
You can adjust the pidsum_limit setting later and it will have no impact on the operation of Heliflight other than increasing or decreasing the amount of cyclic pitch available to you.
First do:
mixer override all on
mixscale SC 1000
Next adjust mixer override SC <value>
until you achieve 8 degrees of collective pitch.
Now set collective_reference = <value found above>
in order to set the 8 degree collective reference for Heliflight.
Then we'll override the collective input to the mixer to it's maximum value: mixer override SC 1000
Now adjust mixscale SC <value>
until you get your desired maximum collective pitch you wish to use with the helicopter.
Type save
to save your changes.
Note: If you ever want to increase or decrease the maximum collective pitch in the future, just do the following to find your new mixscale value:
mixer override all on
mixer override SC 1000
- Adjust
mixscale SC <value>
until you achieve your new desired max collective pitch. -
save
to save your changes
Your collective feedforward tail and governor gains and rescue collective setting will be unaffected by this maximum collective change since they all take this scaling factor into account.
NOTES:
- If you have a motor-driven tail, skip this section and configure the tail motor in the motor setup wiki article later on.
- Heliflight currently only supports helicopters with clockwise main blade rotation. This should be easily fixable in the source code, but no configuration parameter has been made yet. The main difference is that all of the Yaw feedforward compensations will be in the wrong direction for helicopters with counter-clockwise main blade rotation.
The first step to setting up the tail servo is to set the center position. Override the mixer so that the stabilized yaw channel will be zero, which will force the tail servo (servo 4) to the center position defined in the initial servo setup we did earlier.
mixer override all 0
Now install the servo horn on the tail servo so that it will make a 90-degree angle with the tail pushrod. Next, adjust the length of the tail pushrod so that the tail pitch linkage is in it's neutral position. On some helicopter designs this may give 0 degrees of pitch, and other others it may give a small amount of default pitch in the tail blades. Either way is fine, but it is best if any default pitch is in the direction that offsets the torque of the main motor. Otherwise the tail may drift a bit during spool-up until the integral term can find the right amount of offset needed to prevent the helicopter from rotating. See the end of this section if you need help identifying which direction of blade pitch will offset the main motor torque.
At this point you want to find the minimum and maximum limits for the tail servo movement before it binds. This will be a similar process to the how we found the limits to the cyclic servos. We will use the servo override <servo #> <value>
command to move the servo off of center and find the point where it begins to bind. Enter a value above center (such as 825 for a 760uS center servo) like so: servo override 4 825
Observe the position of the tail pitch slider and continue adjusting the override up until it is almost binding. If you hear the servo making noises like it is binding as you reach the end of the tail pitch slider travel, back the override value off a bit until it is no longer making noises. Make a note of the final servo override value for the maximum endpoint.
Repeat the process by moving down from center to find the minimum servo output value. Start with something like: servo override 4 680
and continue down in the same manner as before. Make a note of the final servo override value for the minimum endpoint.
Now you can update the servo
entry for servo number four with the new minimum and maximum endpoints. Use the command:
servo 4 <min_value> <max_value> <center_value> 1000 0 0
save
your work so far.
Next we need to determine the proper movement direction of the tail servo. We are going to turn off the mixer and servo overrides and use the yaw stick on our transmitter to test this. Again, it is important to first ensure that the "Receiver" tab in Configurator shows the aircraft rotating in the proper direction when you move the yaw stick on your transmitter. Yawing right on the stick should rotate the nose of the helicopter model to the right (clockwise) when the helicopter is right-side up.
Disable the mixer and servo overrides if they are still on:
mixer override all off
servo override all off
To ensure that the PID controller moves the tail in the correct direction, you will first need to rotate the main shaft by hand in the correct rotation direction for the main blades and observe the direction of rotation of the tail blade grips. You are looking to find the side of the tail blade grips that will be the leading edge of the tail blades. When we move the Yaw stick on the transmitter, we will be observing the movement of the leading edge of the the tail blade grips. The leading edge of the tail blades will effectively be "pulling" the tail in the direction that it moves off of center. If you give right yaw on the stick you should observe the leading edge of the tail blade grip rotating such that the tail will be pulled left and the helicopter will rotate clockwise. If the blade grips rotate in the opposite direction, just type into the CLI: servo reverse 4
in order to reverse the output of the yaw servo.
Next we are going to scale the stabilized yaw input to the mixer so that our yaw axis PID gains will take into account the width of the servo's PWM input range. This allows similar yaw axis gains to be used on helicopters with different tail servo types.
- For 1500 & 1520uS tail servos, use:
mixscale SY 1000
- For 760uS tail servos, use:
mixscale SY 400
save
your changes and continue on to the next section. The tail servo and mixer yaw axis setup is complete!
Next, continue on to the Wiki article about motor setup and motor mixing.