mirror of
https://github.com/betaflight/betaflight.git
synced 2025-07-23 16:25:31 +03:00
Merge pull request #1584 from atomiclama/master-bf
Fixed a problem when the motor count for motorInit came from custom mixer
This commit is contained in:
commit
25bcaa3a05
5 changed files with 9 additions and 23 deletions
|
@ -263,10 +263,15 @@ void init(void)
|
|||
idlePulse = 0; // brushed motors
|
||||
}
|
||||
|
||||
mixerConfigureOutput();
|
||||
#ifdef USE_SERVOS
|
||||
servoConfigureOutput();
|
||||
#endif
|
||||
|
||||
#ifdef USE_QUAD_MIXER_ONLY
|
||||
motorInit(&masterConfig.motorConfig, idlePulse, QUAD_MOTOR_COUNT);
|
||||
#else
|
||||
motorInit(&masterConfig.motorConfig, idlePulse, mixers[masterConfig.mixerMode].motorCount);
|
||||
motorInit(&masterConfig.motorConfig, idlePulse, motorCount);
|
||||
#endif
|
||||
|
||||
#ifdef USE_SERVOS
|
||||
|
@ -285,10 +290,7 @@ void init(void)
|
|||
pwmRxSetInputFilteringMode(masterConfig.inputFilteringMode);
|
||||
#endif
|
||||
|
||||
mixerConfigureOutput();
|
||||
#ifdef USE_SERVOS
|
||||
servoConfigureOutput();
|
||||
#endif
|
||||
|
||||
systemState |= SYSTEM_STATE_MOTORS_READY;
|
||||
|
||||
#ifdef BEEPER
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue