mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-19 06:15:16 +03:00
Minor blackbox code tidy
This commit is contained in:
parent
b8a8f6d2d8
commit
50ac13d79b
5 changed files with 48 additions and 65 deletions
|
@ -99,6 +99,15 @@ float acos_approx(float x)
|
|||
}
|
||||
#endif
|
||||
|
||||
int gcd(int num, int denom)
|
||||
{
|
||||
if (denom == 0) {
|
||||
return num;
|
||||
}
|
||||
|
||||
return gcd(denom, num % denom);
|
||||
}
|
||||
|
||||
float powerf(float base, int exp) {
|
||||
float result = base;
|
||||
for (int count = 1; count < exp; count++) result *= base;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue