|
|
|
@ -4,25 +4,25 @@
@@ -4,25 +4,25 @@
|
|
|
|
|
# |
|
|
|
|
|
|
|
|
|
set SDCARD_MIXERS_PATH /fs/microsd/etc/mixers |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ $MIXER != none -a $MIXER != skip ] |
|
|
|
|
then |
|
|
|
|
# |
|
|
|
|
# Load main mixer |
|
|
|
|
# |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ $MIXER_AUX == none ] |
|
|
|
|
then |
|
|
|
|
set MIXER_AUX $MIXER.aux |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# Use the mixer file from the SD-card if it exists |
|
|
|
|
if [ -f $SDCARD_MIXERS_PATH/$MIXER.main.mix ] |
|
|
|
|
then |
|
|
|
|
set MIXER_FILE $SDCARD_MIXERS_PATH/$MIXER.main.mix |
|
|
|
|
# Try out the old convention, for backward compatibility |
|
|
|
|
else |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ -f $SDCARD_MIXERS_PATH/$MIXER.mix ] |
|
|
|
|
then |
|
|
|
|
set MIXER_FILE $SDCARD_MIXERS_PATH/$MIXER.mix |
|
|
|
@ -30,19 +30,19 @@ then
@@ -30,19 +30,19 @@ then
|
|
|
|
|
set MIXER_FILE /etc/mixers/$MIXER.main.mix |
|
|
|
|
fi |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ $OUTPUT_MODE == mkblctrl ] |
|
|
|
|
then |
|
|
|
|
set OUTPUT_DEV /dev/mkblctrl |
|
|
|
|
else |
|
|
|
|
set OUTPUT_DEV /dev/pwm_output |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ $OUTPUT_MODE == uavcan_esc ] |
|
|
|
|
then |
|
|
|
|
set OUTPUT_DEV /dev/uavcan/esc |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if mixer load $OUTPUT_DEV $MIXER_FILE |
|
|
|
|
then |
|
|
|
|
echo "[i] Mixer: $MIXER_FILE" |
|
|
|
@ -71,7 +71,7 @@ then
@@ -71,7 +71,7 @@ then
|
|
|
|
|
then |
|
|
|
|
pwm rate -c $PWM_OUT -r $PWM_RATE |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# |
|
|
|
|
# Set disarmed, min and max PWM values |
|
|
|
|
# |
|
|
|
@ -101,20 +101,20 @@ then
@@ -101,20 +101,20 @@ then
|
|
|
|
|
# |
|
|
|
|
# Load aux mixer |
|
|
|
|
# |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
set MIXER_AUX_FILE none |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ -f $SDCARD_MIXERS_PATH/$MIXER_AUX.mix ] |
|
|
|
|
then |
|
|
|
|
set MIXER_AUX_FILE $SDCARD_MIXERS_PATH/$MIXER_AUX.mix |
|
|
|
|
else |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ -f /etc/mixers/$MIXER_AUX.mix ] |
|
|
|
|
then |
|
|
|
|
set MIXER_AUX_FILE /etc/mixers/$MIXER_AUX.mix |
|
|
|
|
fi |
|
|
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ $MIXER_AUX_FILE != none -a $FMU_MODE == pwm ] |
|
|
|
|
then |
|
|
|
|
if fmu mode_pwm |
|
|
|
@ -124,4 +124,4 @@ then
@@ -124,4 +124,4 @@ then
|
|
|
|
|
tone_alarm $TUNE_ERR |
|
|
|
|
fi |
|
|
|
|
fi |
|
|
|
|
fi |
|
|
|
|
fi |
|
|
|
|