From 986607b37d4a74e3311e179e022f8f0a0f61b686 Mon Sep 17 00:00:00 2001 From: David Sidrane Date: Sun, 17 Sep 2017 08:53:04 -1000 Subject: [PATCH] PX4_SAME70XPLAINED_V1:Remove unnesasary conditional for FMU mode --- ROMFS/px4fmu_common/init.d/rcS | 36 +++++++++++++++------------------- 1 file changed, 16 insertions(+), 20 deletions(-) diff --git a/ROMFS/px4fmu_common/init.d/rcS b/ROMFS/px4fmu_common/init.d/rcS index c2a6b6850c..4188c0feda 100644 --- a/ROMFS/px4fmu_common/init.d/rcS +++ b/ROMFS/px4fmu_common/init.d/rcS @@ -426,33 +426,29 @@ then set OUTPUT_MODE uavcan_esc fi - if ver hwcmp PX4_SAME70XPLAINED_V1 + # Sensors on the PWM interface bank + if param compare SENS_EN_LL40LS 1 then - else - # Sensors on the PWM interface bank - if param compare SENS_EN_LL40LS 1 + # clear pins 5 and 6 + set FMU_MODE pwm4 + set AUX_MODE pwm4 + fi + if param greater TRIG_MODE 0 + then + # We ONLY support trigger on pins 5 and 6 when simultanously using AUX for actuator output + if param compare TRIG_PINS 56 then # clear pins 5 and 6 set FMU_MODE pwm4 set AUX_MODE pwm4 + else + set FMU_MODE none + set AUX_MODE none fi - if param greater TRIG_MODE 0 - then - # We ONLY support trigger on pins 5 and 6 when simultanously using AUX for actuator output - if param compare TRIG_PINS 56 - then - # clear pins 5 and 6 - set FMU_MODE pwm4 - set AUX_MODE pwm4 - else - set FMU_MODE none - set AUX_MODE none - fi - camera_trigger start + camera_trigger start - param set CAM_FBACK_MODE 1 - camera_feedback start - fi + param set CAM_FBACK_MODE 1 + camera_feedback start fi # If OUTPUT_MODE == none then something is wrong with setup and we shouldn't try to enable output