Merge branch 'PWM_mapping' of https://github.com/MJ666/cleanflight into MJ666-PWM_mapping
Conflicts: src/main/main.c
This commit is contained in:
commit
abe4fbbaae
|
@ -297,7 +297,7 @@ pwmOutputConfiguration_t *pwmInit(drv_pwm_config_t *init)
|
|||
// this is pretty hacky shit, but it will do for now. array of 4 config maps, [ multiPWM multiPPM airPWM airPPM ]
|
||||
if (init->airplane)
|
||||
i = 2; // switch to air hardware config
|
||||
if (init->usePPM)
|
||||
if (init->usePPM || init->useSerialRx)
|
||||
i++; // next index is for PPM
|
||||
|
||||
setup = hardwareMaps[i];
|
||||
|
|
|
@ -39,6 +39,7 @@
|
|||
typedef struct drv_pwm_config_t {
|
||||
bool useParallelPWM;
|
||||
bool usePPM;
|
||||
bool useSerialRx;
|
||||
bool useRSSIADC;
|
||||
bool useCurrentMeterADC;
|
||||
#ifdef STM32F10X
|
||||
|
|
|
@ -290,6 +290,7 @@ void init(void)
|
|||
pwm_params.useLEDStrip = feature(FEATURE_LED_STRIP);
|
||||
pwm_params.usePPM = feature(FEATURE_RX_PPM);
|
||||
pwm_params.useOneshot = feature(FEATURE_ONESHOT125);
|
||||
pwm_params.useSerialRx = feature(FEATURE_RX_SERIAL);
|
||||
pwm_params.useServos = isMixerUsingServos();
|
||||
pwm_params.extraServos = currentProfile->gimbalConfig.gimbal_flags & GIMBAL_FORWARDAUX;
|
||||
pwm_params.motorPwmRate = masterConfig.motor_pwm_rate;
|
||||
|
|
Loading…
Reference in New Issue