Ah, it’s the “Betaflight” rate. I’d need to find the exact formula. =)
There are some calculators here for various rate options available in Betaflight. All of these allow for pseudo-independent adjustments of expo curve around center stick and at the edge.
Constraints:
0 < x < 1 for stick input (if x = 1, there’s a potential for divide by zero)
Super_Rate is < 1 (otherwise formula can go negative)
Rate is <= 2.55
Expo is <= 1 (otherwise formula can go negative)
So bear with me as I’m picking most of this up as I go. I wanted to give an interim update to make sure I’m at least on the right path.
I forked and made a branch of copter4.1 into Copter-4.1_BF_Rate rate in my github, and committed what I believe are all of the changes needed to add betaflight rates. I mostly copied the style of the code around it.
I’m still working on setting up an environment to build this into a binary (so I don’t even know if it’ll compile yet; usually I have typos to iron out). Then either try to figure out the simulator, or just play with this with my quad with props off and a log.
My history was really messy because I was editing in windows and using git to sync the files over to WSL2 to compile. So you got to see all my typos and meandering