From fd0eb1dc88b83cb55c2e93085357c5cff799a7d0 Mon Sep 17 00:00:00 2001 From: Clayton Craft Date: Fri, 23 Apr 2021 10:45:13 -0700 Subject: [PATCH] sxmo_audioout: use existing env vars for audio devices If the env variables in this script are set, use those values. Else it defaults to using the values set before this patch. Signed-off-by: Anjandev Momi --- scripts/core/sxmo_audioout.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/core/sxmo_audioout.sh b/scripts/core/sxmo_audioout.sh index 9311ab7..310f307 100755 --- a/scripts/core/sxmo_audioout.sh +++ b/scripts/core/sxmo_audioout.sh @@ -5,9 +5,9 @@ ARG="$1" # shellcheck source=scripts/core/sxmo_common.sh . "$(dirname "$0")/sxmo_common.sh" -SPEAKER="Line Out" -HEADPHONE="Headphone" -EARPIECE="Earpiece" +${SPEAKER:-"Line Out"} +${HEADPHONE:-"Headphone"} +${EARPIECE:-"Earpiece"} amixer set "$SPEAKER" mute amixer set "$HEADPHONE" mute