~mil/sxmo-utils

ref: dbc3b1ab509aab5f1db72c5cece2ee2a6eb521e8 sxmo-utils/scripts/core/sxmo_audioout.sh -rwxr-xr-x 513 bytes
dbc3b1abStacy Harper Allow the sendnewtextmenu to be used with a number as arg 1 year, 4 months ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#!/usr/bin/env sh
ARG="$1"

# include common definitions
# shellcheck source=scripts/core/sxmo_common.sh
. "$(dirname "$0")/sxmo_common.sh"

SPEAKER="Line Out"
HEADPHONE="Headphone"
EARPIECE="Earpiece"

amixer set "$SPEAKER" mute
amixer set "$HEADPHONE" mute
amixer set "$EARPIECE" mute

if [ "$ARG" = "Speaker" ]; then
	amixer set "$SPEAKER" unmute
elif [ "$ARG" = "Headphones" ]; then
	amixer set "$HEADPHONE" unmute
elif [ "$ARG" = "Earpiece" ]; then
	amixer set "$EARPIECE" unmute
fi

sxmo_statusbarupdate.sh