-
Notifications
You must be signed in to change notification settings - Fork 138
Configuring PulseAudio server
A typical use case for Pulseaudio playback is to have a Linux desktop PC with a graphical environment (say Gnome or KDE) which uses PA to allow many applications to access sound hardware simultaneously. if this is your case, then:
- It is usually not necessary to start PA server manually, because the PA
library will do it automatically on a first attempt to play any sound. So
play something, then launch a terminal window and type
ps xa|grep pulseaudio
to check if there is a PulseAudio process running. Then typepacmd info
- it should display a lot of information about the current status of the server. - If you are running RTLSDR-Airband on the same desktop PC, then telling it to
use PulseAudio default server shall be enough. So comment out or delete the
server
setting from the pulse output configuration in rtl_airband.conf. It will then attempt to connect to a local PA server over UNIX socket. That's it. - If you are running RTLSDR-Airband on a different machine, then it is necessary to configure PA server to accept audio streams from the network.
First, check if network access is already enabled:
user@localhost:~ $ pacmd list-modules|grep protocol-tcp
user@localhost:~ $
If nothing shows up, then it's disabled. In this case you need to edit the PA
startup script /etc/pulse/default.pa
:
sudo nano /etc/pulse/default.pa
Search for lines containing load-module module-native-protocol-tcp
. Most
probably you won't find any or there will be one, but commented out with a #
at the beginning. If this is the case, add this line (eg. at the end of the
file):
load-module module-native-protocol-tcp auth-ip-acl=127.0.0.1;10.1.1.0/24
The last part (auth-ip-acl=127.0.0.1;10.1.1.0/24
) is an access control list
specifying a list of hosts and networks which should be allowed to connect to
this PA server and play audio through it. In the above example it says that
localhost is allowed (127.0.0.1) and any host with an IP address in the range
10.1.1.0-10.1.1.255 is allowed as well. Replace the 10.1.1.0/24 with the IP
address of the machine where RTLSDR-Airband will be running (you may specify
individual hosts and network prefixes here). Save the file, exit the editor and
kill the PA server:
pulseaudio -k
It will restart automatically on a first attempt to play any sound. Verify this with:
ps xa|grep pulseaudio
and check once again if the module-native-protocol-tcp
is loaded now:
user@localhost:~ $ pacmd list-modules|grep protocol-tcp
name: <module-native-protocol-tcp>
user@localhost:~ $
Now the PA server shall listen on its default TCP port of 4713. Verify if it indeed does:
user@localhost:~ $ netstat -anp|grep 4713
(Not all processes could be identified, non-owned process info
will not be shown, you would have to be root to see it all.)
tcp 0 0 0.0.0.0:4713 0.0.0.0:* LISTEN 4966/pulseaudio
tcp6 0 0 :::4713 :::* LISTEN 4966/pulseaudio
You should see 0.0.0.0:4713
and/or :::4713
in the fourth column, meaning
that PA is indeed listening on an outside interface and connections can be made
from other machines to this port.
Right now your PA server should be ready to accept audio streams from RTLSDR-Airband. Run the program and it should start playing right away (at least you should get per-stream sliders in your desktop mixer app). If it doesn't, check out the log files for possible clues - see Logging section to find out where they are.
- Overview
- Installation
-
Configuration essentials
- Grammar basics
- General configuration file structure
- Configuring devices
- Configuring channels
- Configuring outputs
-
Configuring optional features
- Disabling configuration sections
- Changing PID file location
- Manual squelch setting
- CTCSS
- NFM deemphasis
- Audio filters in MP3 outputs
- Notch filter
- Limiting channel bandwidth
- Icecast metadata updates in scan mode
- Logging activity of scanned frequencies
- Channel usage statistics
- Tweaking sampling rate and FFT size
- Mixers
- Multithreaded operation
- Running
- Troubleshooting
- Configuring auxiliary software to work with RTLSDR-Airband