distribution/packages/hardware/quirks/devices/Anbernic RG351M/003-audio

39 lines
627 B
Text
Raw Normal View History

2023-05-04 18:06:54 +00:00
#!/bin/bash
# SPDX-License-Identifier: Apache-2.0
# Copyright (C) 2021-present Fewtarius (https://github.com/fewtarius)
. /etc/profile
### Set a custom device so we don't clobber it.
set-audio set "CUSTOM (UNMANAGED)"
set-audio esset "Master"
cat <<EOF >/storage/.config/asound.conf
pcm.!default {
type plug
slave.pcm "dmixer"
}
pcm.dmixer {
type dmix
ipc_key 1024
slave {
pcm "hw:0,0"
period_time 0
period_size 1024
buffer_size 4096
rate 44100
}
bindings {
0 0
1 1
}
}
EOF
#if [ ! -e "/storage/.config/asound.state" ]
#then
# cat <<EOF >/storage/.config/asound.state
#EOF
#fi