264,10 → 264,10 |
int32_t tmp; |
uint8_t throttle; |
|
tmp = (int32_t) throttleTerm * mixerMatrix.motor[i][MIX_THROTTLE]; |
tmp += (int32_t) term[PITCH] * mixerMatrix.motor[i][MIX_PITCH]; |
tmp += (int32_t) term[ROLL] * mixerMatrix.motor[i][MIX_ROLL]; |
tmp += (int32_t) yawTerm * mixerMatrix.motor[i][MIX_YAW]; |
tmp = (int32_t) throttleTerm * motorMixer.matrix[i][MIX_THROTTLE]; |
tmp += (int32_t) term[PITCH] * motorMixer.matrix[i][MIX_PITCH]; |
tmp += (int32_t) term[ROLL] * motorMixer.matrix[i][MIX_ROLL]; |
tmp += (int32_t) yawTerm * motorMixer.matrix[i][MIX_YAW]; |
tmp = tmp >> 6; |
motorFilters[i] = motorFilter(tmp, motorFilters[i]); |
// Now we scale back down to a 0..255 range. |
288,7 → 288,7 |
debugOut.analog[10 + i] = throttle; |
*/ |
|
if ((MKFlags & MKFLAG_MOTOR_RUN) && mixerMatrix.motor[i][MIX_THROTTLE] > 0) { |
if ((MKFlags & MKFLAG_MOTOR_RUN) && motorMixer.matrix[i][MIX_THROTTLE] > 0) { |
motor[i].throttle = throttle; |
} else if (motorTestActive) { |
motor[i].throttle = motorTest[i]; |