mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-19 22:35:23 +03:00
maybe more efficient?
This commit is contained in:
parent
73663f7fae
commit
0833aab886
1 changed files with 14 additions and 12 deletions
|
@ -102,6 +102,7 @@ FAST_CODE_NOINLINE float interpolatedSpApply(int axis, bool newRcFrame, ffInterp
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
// we have movement; let's consider what happened on previous packets, using ffStatus
|
// we have movement; let's consider what happened on previous packets, using ffStatus
|
||||||
|
if (ffStatus[axis] != 0) {
|
||||||
if (ffStatus[axis] == 1) {
|
if (ffStatus[axis] == 1) {
|
||||||
// was interpolated forward after previous dropped packet after small step
|
// was interpolated forward after previous dropped packet after small step
|
||||||
// this step is likely twice as tall as it should be
|
// this step is likely twice as tall as it should be
|
||||||
|
@ -116,6 +117,7 @@ FAST_CODE_NOINLINE float interpolatedSpApply(int axis, bool newRcFrame, ffInterp
|
||||||
ffStatus[axis] = 0;
|
ffStatus[axis] = 0;
|
||||||
// all is normal
|
// all is normal
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
float setpointAcceleration = setpointSpeed - prevSetpointSpeed[axis];
|
float setpointAcceleration = setpointSpeed - prevSetpointSpeed[axis];
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue