From 3074de1f86baeb976ed3819778188c2836a435f1 Mon Sep 17 00:00:00 2001 From: jerryyip <563355085@qq.com> Date: Wed, 30 May 2018 10:36:10 +0800 Subject: [PATCH] init --- pulseaudio/README.md | 16 +++++++++++----- pulseaudio/pulse_config_4mic/daemon.conf | 2 +- pulseaudio/pulse_config_4mic/default.pa | 2 ++ .../pulse_config_4mic/seeed-voicecard.conf | 2 +- pulseaudio/pulse_config_6mic/daemon.conf | 2 +- 5 files changed, 16 insertions(+), 8 deletions(-) diff --git a/pulseaudio/README.md b/pulseaudio/README.md index 160987c..24bb5f0 100644 --- a/pulseaudio/README.md +++ b/pulseaudio/README.md @@ -8,7 +8,6 @@ Following this guide if you want to use your seeed-voicecard as a default source 1. Download pulseaudio ``` sudo apt install pulseaudio -pulseaudio --k ``` 2. First, you need to write [a profile for pulse](https://www.freedesktop.org/wiki/Software/PulseAudio/Backends/ALSA/Profiles/) @@ -97,7 +96,7 @@ User Name: pi Host Name: raspberrypi Server Name: pulseaudio Server Version: 10.0 -Default Sample Specification: s16le 4ch 16000Hz +Default Sample Specification: s16le 4ch 96000Hz Default Channel Map: front-left,front-center,front-right,rear-center Default Sink: alsa_output.platform-soc_audio.analog-stereo Default Source: alsa_input.platform-soc_sound.seeed-source @@ -110,7 +109,6 @@ Cookie: 3b12:70b3 1. Download pulseaudio ``` sudo apt install pulseaudio -pulseaudio --k ``` 2. First, you need to write [a profile for pulse](https://www.freedesktop.org/wiki/Software/PulseAudio/Backends/ALSA/Profiles/) @@ -202,7 +200,7 @@ User Name: pi Host Name: raspberrypi Server Name: pulseaudio Server Version: 10.0 -Default Sample Specification: s32le 8ch 48000Hz +Default Sample Specification: s32le 8ch 96000Hz Default Channel Map: front-left,front-left-of-center,front-center,front-right,front-right-of-center,rear-center,aux0,aux1 Default Sink: alsa_output.platform-soc_sound.seeed-2ch Default Source: alsa_input.platform-soc_sound.seeed-8ch @@ -220,4 +218,12 @@ Cookie: 3523:e5af 2. Can't start PulseAudio Check `default.pa` and `daemon.conf` - \ No newline at end of file + +3. How to get PulseAudio started automatically + + Normally the PulseAudio server is started automatically. If you want to disable it, you can set `autospawn = no` in `~/.config/pulse/client.conf` or `/etc/pulse/client.conf`. + [Click this for more details](https://www.freedesktop.org/wiki/Software/PulseAudio/Documentation/User/Running/). + +4. Why the default sample rate is 96000? What if my audio's sample rate is not the same as the default? + + For the other sample rate audio, PulseAudio will resample it into 96K, which means that if your audio's sample rate is lower than 96K, it will get smoothing. \ No newline at end of file diff --git a/pulseaudio/pulse_config_4mic/daemon.conf b/pulseaudio/pulse_config_4mic/daemon.conf index 1fdec4c..d9c5b93 100644 --- a/pulseaudio/pulse_config_4mic/daemon.conf +++ b/pulseaudio/pulse_config_4mic/daemon.conf @@ -74,7 +74,7 @@ ; rlimit-rttime = 200000 default-sample-format = s16le -default-sample-rate = 16000 +default-sample-rate = 96000 ; alternate-sample-rate = 48000 default-sample-channels = 4 ; default-channel-map = front-left,front-right diff --git a/pulseaudio/pulse_config_4mic/default.pa b/pulseaudio/pulse_config_4mic/default.pa index e2a355d..12915f5 100644 --- a/pulseaudio/pulse_config_4mic/default.pa +++ b/pulseaudio/pulse_config_4mic/default.pa @@ -140,3 +140,5 @@ load-module module-filter-apply #set-default-sink output #set-default-source input set-default-source alsa_input.platform-soc_sound.seeed-source +set-default-sink alsa_output.platform-soc_sound.seeed-sink + diff --git a/pulseaudio/pulse_config_4mic/seeed-voicecard.conf b/pulseaudio/pulse_config_4mic/seeed-voicecard.conf index aaca00b..61b7ff0 100644 --- a/pulseaudio/pulse_config_4mic/seeed-voicecard.conf +++ b/pulseaudio/pulse_config_4mic/seeed-voicecard.conf @@ -12,7 +12,7 @@ priority = 3 direction = input [Mapping seeed-sink] device-strings = playback -channel-map = front-left,front-right,rear-left,rear-right +channel-map = front-left,front-right exact-channels = false fallback = yes paths-output = seeed-sink diff --git a/pulseaudio/pulse_config_6mic/daemon.conf b/pulseaudio/pulse_config_6mic/daemon.conf index 9d87aba..89a7c9f 100644 --- a/pulseaudio/pulse_config_6mic/daemon.conf +++ b/pulseaudio/pulse_config_6mic/daemon.conf @@ -74,7 +74,7 @@ ; rlimit-rttime = 200000 default-sample-format = s32le -default-sample-rate = 48000 +default-sample-rate = 96000 ; alternate-sample-rate = 48000 default-sample-channels = 8 ; default-channel-map = front-left,front-right