11,13 → 11,6 |
|
#define INTEGRAL_LIMIT 100000 |
|
/* |
#define DEBUGINTEGRAL 0 |
#define DEBUGDIFFERENTIAL 0 |
#define DEBUGHOVERTHROTTLE 0 |
#define DEBUGHEIGHTSWITCH 0 |
*/ |
|
#define LATCH_TIME 40 |
|
int32_t groundPressure; |
126,7 → 119,7 |
else if (iHeight < 0) { if (DEBUGINTEGRAL) DebugOut.Digital[1] = 1;} |
*/ |
|
int16_t dThrottle = ((heightError * staticParams.heightP) >> 9) |
int16_t dThrottle = ((heightError * staticParams.heightP) >> 10) |
/*+ iHeight / 10000L * staticParams.Height_ACC_Effect */-((dHeight * staticParams.heightD) >> 7); |
|
if (dThrottle > staticParams.heightControlMaxThrottleChange) |