mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-08-02 23:47:49 +00:00
NXP: add rdu-audio script
This commit is contained in:
parent
512ebce5e5
commit
d6cdad8e66
26
projects/NXP/devices/iMX6/filesystem/usr/bin/rdu-audio
Executable file
26
projects/NXP/devices/iMX6/filesystem/usr/bin/rdu-audio
Executable file
@ -0,0 +1,26 @@
|
||||
#!/bin/sh
|
||||
|
||||
if [ -z "$1" ]; then
|
||||
echo "usage: rdu-audio <0-100>"
|
||||
echo " The recommended level is 80"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
VOLUME="$1%"
|
||||
|
||||
amixer -q sset 'TPA6130A2 Headphone',0 $VOLUME
|
||||
amixer -q sset 'Speaker',0 on
|
||||
amixer -q sset 'Speaker Analog',0 $VOLUME
|
||||
amixer -q sset 'Speaker Driver',0 $VOLUME
|
||||
amixer -q sset 'Speaker Driver',0 on
|
||||
amixer -q sset 'DAC',0 $VOLUME
|
||||
amixer -q sset 'HP Analog',0 $VOLUME
|
||||
amixer -q sset 'HP Driver',0 $VOLUME
|
||||
amixer -q sset 'HP Driver',0 on
|
||||
amixer -q sset 'HP Left',0 on
|
||||
amixer -q sset 'HP Right',0 on
|
||||
amixer -q sset 'Output Left From AIN1',0 on
|
||||
amixer -q sset 'Output Left From AIN2',0 on
|
||||
amixer -q sset 'Output Left From Left DAC',0 on
|
||||
amixer -q sset 'Output Right From AIN2',0 on
|
||||
amixer -q sset 'Output Right From Right DAC',0 on
|
@ -0,0 +1,12 @@
|
||||
[Unit]
|
||||
Description=RDU audio setup
|
||||
After=sound.target
|
||||
ConditionPathExistsGlob=/flash/imx6*-zii-rdu2.dtb
|
||||
|
||||
[Service]
|
||||
Type=oneshot
|
||||
ExecStart=/usr/bin/rdu-audio 80
|
||||
RemainAfterExit=true
|
||||
|
||||
[Install]
|
||||
WantedBy=multi-user.target
|
Loading…
x
Reference in New Issue
Block a user