1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-23 16:25:31 +03:00

Revert "Merge pull request #372 from aughey/betaflight"

This reverts commit a6a5f50ffb, reversing
changes made to 9cc5503851.
This commit is contained in:
borisbstyle 2016-05-04 00:00:04 +02:00
parent a6a5f50ffb
commit 5ffb3b5068
6 changed files with 30 additions and 58 deletions

View file

@ -116,25 +116,3 @@ void arraySubInt32(int32_t *dest, int32_t *array1, int32_t *array2, int count);
int16_t qPercent(fix12_t q);
int16_t qMultiply(fix12_t q, int16_t input);
fix12_t qConstruct(int16_t num, int16_t den);
// Defining constrain and constrainf as inline in the include file
// because these functions are used universally and should be fast.
inline int constrain(int amt, int low, int high)
{
if (amt < low)
return low;
else if (amt > high)
return high;
else
return amt;
}
inline float constrainf(float amt, float low, float high)
{
if (amt < low)
return low;
else if (amt > high)
return high;
else
return amt;
}