mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-19 06:15:16 +03:00
Rework Fast PWM protocol configuration and timing
This commit is contained in:
parent
c74c5df73d
commit
9e5c5e88c7
12 changed files with 67 additions and 77 deletions
|
@ -633,7 +633,7 @@ void writeServos(void)
|
|||
}
|
||||
#endif
|
||||
|
||||
void writeMotors(void)
|
||||
void writeMotors(uint8_t unsyncedPwm)
|
||||
{
|
||||
uint8_t i;
|
||||
|
||||
|
@ -641,7 +641,7 @@ void writeMotors(void)
|
|||
pwmWriteMotor(i, motor[i]);
|
||||
|
||||
|
||||
if (feature(FEATURE_ONESHOT125)) {
|
||||
if (feature(FEATURE_ONESHOT125) && !unsyncedPwm) {
|
||||
pwmCompleteOneshotMotorUpdate(motorCount);
|
||||
}
|
||||
}
|
||||
|
@ -653,7 +653,7 @@ void writeAllMotors(int16_t mc)
|
|||
// Sends commands to all motors
|
||||
for (i = 0; i < motorCount; i++)
|
||||
motor[i] = mc;
|
||||
writeMotors();
|
||||
writeMotors(1);
|
||||
}
|
||||
|
||||
void stopMotors(void)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue