This article explains what Setpoint Weight and Transition are, and how I tune these settings in Betaflight. “Derivative of error and measurement” are closely related to setpoint weight, and they can give you very different flight characteristics.
Take a look at my PID explained tutorial if you haven’t already, where I will also show you how I tune my quadcopter PID.
To understand the setting “Set-point Weight”, it helps to first get a basic understanding of what “Derivative of Error” and “Derivative of Measurement” are. This article is relevant to what “derivative of error” is, where i also explain why excessive D gain causes oscillations.
tltr: What’s the best Setpoint Weight and Transition setting?
If you don’t want to read, just try this values which are what I personally use:
- Setpoint Weight: 0.95-1.00
- Setpoint Transition: 0.1-0.3
But if you have time, try play with different value and see what works for you. Let me know in the comment :) Now if you want to know more, let’s dive into the technical stuff!
Derivative of “Error” vs. “Measurement”
During the development of Betaflight, we were once given an option to either use “Derivative of Error”, or “Derivative of Measurement”.
These are the two methods of deriving D value in the PID controller. They can hugely affect your quad’s handling and flight characteristics, specifically in terms of smoothness and responsiveness.
I will refer to these two methods as “Error” and “Measurement” in the rest of this article.
Main Differences Between Error & Measurement
D term on Error gives you sharper stick response but rougher motors, while Measurement gives you softer stick response and smoother running motors.
You may have seen RC command without interpolation in a blackbox log, it looks like a jagged trace as shown in the image below (it’s completely normal by the way). The “stepped RC command” is what we believe that cause the most noticeable difference between Error and Measurement.
The reason that Error feels so direct and twitchy could be that RC command is stepped.
Because every step is a change in Setpoint and error, and this causes what is called a “D term kick“.
Every D term kick gives the motors a sudden push, and you can get lots of “D term kicks” from moving your sticks because you are basically changing your set-point rapidly and constantly. This makes the control feel very snappy and responsive, but the motors also need to work harder and therefore sound rougher.
D term from measurement avoids “D term kick” as mentioned above, therefore it feels less snappy but smoother.
Which one is better?
You can notice the difference between the two more easily when you are moving your sticks rapidly, e.g. when you are doing acro moves or bank turns. However, there is little to no difference when you are not moving the sticks.
It’s been suggested that racers might prefer Error and freestyle pilots might prefer Measurement, but I am sure everyone has a different preference.
Later on, Betaflight developers introduced “Setpoint Weight” so we can find a balance between the two.
What is Setpoint Weight?
The downside of too much D gain
When you come to a stop after doing an acro move, a high P term can make your quad overshoot and bounce back. Here is where D term comes into play, it damps it and makes it smoother.
But too much D term can make your quad respond slower and gives you that feeling you are less connected to the sticks. The more you increase D gain, the more sluggish your quad becomes between sharp moves.
Setpoint weight can help!
By raising “Setpoint Weight” in Betaflight can counteract the negative effect caused by D term. It’s is basically a sliding scale between the two D term methods mentioned above.
This allows you to have it exactly where you want it between smoothness and responsiveness:
- Setpoint weight of 1 = error
- Setpoint weight of 0 = measurement
You can actually set Setpoint weight much higher than 1, up to 2.55 which will make your stick response ultra fast and movement ultra crispy.
The downside of extremely high Setpoint Weight is every time you move your stick, it produces a sharp movement. It’s often described as “robotic”, “twitchy” and “stiff” which is undesirable in FPV Freestyle and achieving smooth FPV flight footage.
I found Setpoint Weight can slightly affect your Rates and Expo as it goes above 1, so you might want to fine tune those settings too.
Tuning Setpoint Weight
D setpoint weight might be one of the most influential parameters in how the quad flies, and it’s often overlooked. It can also mask badly tuned PID, so my recommendation is to leave Setpoint Weight at default until you have tuned your PID.
Setpoint Weight doesn’t do anything when your sticks are idle, so make sure to do lots of acro moves when tuning Setpoint Weight.
My recommendation is to begin with value 1, and play around between 0.5 to 1.5. Remember there is no wrong value as long as you like it. I personally find a noticeable difference with an increment of 0.05, so take small step at a time :)
Setpoint Transition Explained
Setpoint Transition gives you the best of both worlds: the sharp response as well as the damping at the end of the move. It decreases the influence of Setpoint Weight when the stick is returning back to center. This results in smoother stop of a flip and roll (or any other acrobatic moves).
The Setpoint transition value basically represents a point of stick deflection:
- 0 – stick center
- 1 – stick endpoint
When the stick is above that point, Setpoint Weight is kept constant at its configured value. And when the stick is positioned below that point, Setpoint Weight is reduced proportionally, reaching 0 at the stick center position.
In simple words, transition value of 1 would feel a bit slower and mushier, but it offers the smoothest effect. Transition value of 0 keeps Setpoint Weight value consistent for the entire stick range.
I personally prefer to use a lower value like 0.1 – 0.3.
Support Me On Patreon
I hope you find this article useful. I am now on Patreon, please consider supporting me there :) I also regularly do giveaways there so don’t miss out!