Created
November 8, 2017 02:41
-
-
Save nfedyashev/22462f5125cf86c3984910ff953a9c6a to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#see /proc/asound/cards for card num | |
#cat /etc/asound.conf | |
pcm.!default { | |
type plug | |
slave.pcm "plugequal" | |
} | |
pcm.dmixer { | |
type dmix | |
ipc_key 1024 | |
slave { | |
pcm 'hw:2' | |
format S32_LE | |
rate 44100 | |
period_size 1000 | |
buffer_size 3000 | |
} | |
} | |
ctl.dmixer { | |
type hw | |
card 2 | |
device 0 | |
} | |
pcm.dsp { | |
type plug | |
slave.pcm "dmixer" | |
} | |
ctl.equal { | |
type equal; | |
} | |
pcm.plugequal { | |
type equal; | |
slave.pcm "plug:dmixer"; | |
} | |
pcm.equal { | |
type plug; | |
slave.pcm plugequal; | |
} | |
#cat $HOME/.mpd/mpd.conf | |
####### MPD CONFIG ####### | |
# Required files | |
db_file "~/.config/mpd/database" | |
log_file "~/.config/mpd/log" | |
# Optional | |
music_directory "~/Music" | |
playlist_directory "~/.config/mpd/playlists" | |
pid_file "~/.config/mpd/pid" | |
state_file "~/.config/mpd/state" | |
sticker_file "~/.config/mpd/sticker.sql" | |
max_output_buffer_size "16384" | |
audio_output { | |
type "alsa" | |
name "dmixer" | |
#device "hw:2" | |
#mixer_type "software" | |
#options "dev=dmixer" useless | |
#options "dev=plug:plugequal" useless | |
#Sets the device which should be used. | |
#This can be any valid ALSA device name. | |
#The default value is "default", which makes libasound choose a device. | |
#It is recommended to use a "hw" or "plughw" device, because otherwise, libasound automatically enables "dmix", which has major disadvantages (fixed sample rate, poor resampler, ...). | |
#device "plug:dmixer" | |
device "plug:plugequal" | |
# sets ALSA mixer device name defaults to "default" which lets ALSA pick a value | |
#mixer_device "" | |
# `amixer scontrols` to list default is PCM | |
#mixer_control "" | |
#"ao_driver "alsa09" | |
#"ao_driver_options "dev=plug:dmixs51" | |
} | |
#audio_output { | |
# type "fifo" | |
# name "toggle_visualizer" | |
# path "/tmp/mpd.fifo" | |
# format "44100:16:2" | |
#} | |
####### END MPD CONFIG ####### | |
bind_to_address "127.0.0.1" | |
port "6600" | |
auto_update "yes" | |
auto_update_depth "4" | |
#user "nikita" | |
# How to set volume via amixer | |
1) check device #(2 for example) | |
2) see available commands: | |
➜ ~ amixer -c 2 scontrols | |
Simple mixer control 'PCM',0 | |
Simple mixer control 'PCM Capture Source',0 | |
Simple mixer control 'Line In',0 | |
Simple mixer control 'Mic-In/Mic Array',0 | |
Simple mixer control 'Auto Gain Control',0 | |
3) ➜ ~ amixer sset -c2 PCM 5%+ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment