mirror of
https://github.com/AquaMorph/dotfiles.git
synced 2025-04-29 09:15:34 +00:00
ES-8 dynamic startup script
This commit is contained in:
parent
01d37f6b90
commit
f28aa3d4d2
18
scripts/start-es-8.sh
Normal file
18
scripts/start-es-8.sh
Normal file
@ -0,0 +1,18 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Script to add another audio interface if available.
|
||||
|
||||
DEVICENAME='ES-8'
|
||||
DEVICENUM="$(cat /proc/asound/cards | grep -m 1 $DEVICENAME | grep -o '[0-9]' | head -1)"
|
||||
|
||||
if test -z "$DEVICENUM"
|
||||
then
|
||||
echo $DEVICENAME not connected
|
||||
exit 1
|
||||
else
|
||||
echo $DEVICENAME found at hw:$DEVICENUM
|
||||
fi
|
||||
|
||||
# Start up audio interface
|
||||
alsa_in -d hw:$DEVICENUM -j "$DEVICENAME In" &
|
||||
alsa_out -d hw:$DEVICENUM -j "$DEVICENAME Out" &
|
Loading…
x
Reference in New Issue
Block a user