From e15cbc3a6b246bb7df34a054b5e08b8f26b10974 Mon Sep 17 00:00:00 2001 From: Julian Oes Date: Tue, 12 Oct 2021 13:18:46 +0200 Subject: [PATCH] Mantis: move tap_esc to extras This way we work around an issue where tap_esc got stuck during bootup in a cold boot. --- boards/atl/mantis-edu/init/rc.board_defaults | 17 ----------------- boards/atl/mantis-edu/init/rc.board_extras | 18 ++++++++++++++++++ 2 files changed, 18 insertions(+), 17 deletions(-) create mode 100644 boards/atl/mantis-edu/init/rc.board_extras diff --git a/boards/atl/mantis-edu/init/rc.board_defaults b/boards/atl/mantis-edu/init/rc.board_defaults index 21b2424384..1f8c8c742c 100644 --- a/boards/atl/mantis-edu/init/rc.board_defaults +++ b/boards/atl/mantis-edu/init/rc.board_defaults @@ -29,20 +29,3 @@ set MIXER_FILE "" set MIXER "skip" set OUTPUT_MODE "skip" -# Start ESC already here, so that we have beeps. -tap_esc start -d /dev/ttyS4 -n 4 - -# Transition from previous non open-source flight stack -if param compare SYS_AUTOSTART 4001 -then - param reset_all - tune_control play -t 4 - sleep 2 - if bl_update /etc/extras/bootloader.bin - then - tune_control play -t 3 - else - tune_control play -t 5 - fi - sleep 2 -fi diff --git a/boards/atl/mantis-edu/init/rc.board_extras b/boards/atl/mantis-edu/init/rc.board_extras new file mode 100644 index 0000000000..a64aa796ec --- /dev/null +++ b/boards/atl/mantis-edu/init/rc.board_extras @@ -0,0 +1,18 @@ +#!/bin/sh + +tap_esc start -d /dev/ttyS4 -n 4 + +# Transition from previous non open-source flight stack +if param compare SYS_AUTOSTART 4001 +then + param reset_all + tune_control play -t 4 + sleep 2 + if bl_update /etc/extras/bootloader.bin + then + tune_control play -t 3 + else + tune_control play -t 5 + fi + sleep 2 +fi