Alsa - how to do the similar query with alsa tools when Pulseaudio server
crash and does not work
Pulseaudio server sometimes does not work because the service crash
automatically, because my application depending on PA it fail to execute
following:
pactl list | sed -n '/^Sink/,/^$/p' | grep 'HDA Intel PCH' -B 5 | grep
'Volume:' | head -n1 | cut -d' ' -f2- | tr -d ' '
pactl list sources | grep -A 6 "Name: HDA Intel PCH" | tail -n 1 | perl -p
-i -e 's/.+\\s(yes|no)$/$1/'
pactl set-source-mute STRING 1
How can i do this three commands with Alsa tools (not using Pulseaudio)?
EDIT:
pactl alternative is amixer
$ cat /proc/asound/cards | grep 'HDA Intel PCH' | head -1 | awk '{print
$1}' | sed 's/ //g'
$ amixer -D hw:2
Simple mixer control 'Mic',0
Capabilities: cvolume cvolume-joined cswitch cswitch-joined penum
Capture channels: Mono
Limits: Capture 0 - 6144
Mono: Capture 4608 [75%] [24.00dB] [on]
No comments:
Post a Comment