You are not logged in.

#1 2023-08-23 21:17:16

carbolymer
Member
Registered: 2012-04-25
Posts: 44

Pulseaudio and rtp no sound

I'm trying to set up two PCs and send sound using pulseaudio and rtp from one to the other.

First pc setup in ~/.config/pulse/default.pa

.include /etc/pulse/default.pa

load-module module-null-sink sink_name=rtp format=s16be channels=2 rate=44100 sink_properties="device.description='RTP'"
load-module module-rtp-send source=rtp.monitor destination_ip=10.0.0.3
set-default-sink rtp

Second PC setup in  ~/.config/pulse/default.pa:

.include /etc/pulse/default.pa

load-module module-rtp-recv latency_msec=10 sap_address=0.0.0.0

I've selected RTP outputs on the first PC and it's not muted. RTP sink from the first pc from `pactl list sinks`:

Sink #1
	State: RUNNING
	Name: rtp
	Description: RTP
	Driver: module-null-sink.c
	Sample Specification: s16be 2ch 44100Hz
	Channel Map: front-left,front-right
	Owner Module: 24
	Mute: no
	Volume: front-left: 66308 / 101% / 0.31 dB,   front-right: 66308 / 101% / 0.31 dB
	        balance 0.00
	Base Volume: 65536 / 100% / 0.00 dB
	Monitor Source: rtp.monitor
	Latency: 3141 usec, configured 7256 usec
	Flags: DECIBEL_VOLUME LATENCY SET_FORMATS 
	Properties:
		device.description = "RTP"
		device.class = "abstract"
		device.icon_name = "audio-card"
	Formats:
		pcm
		ac3-iec61937
		eac3-iec61937
		mpeg-iec61937
		dts-iec61937
		mpeg2-aac-iec61937
		truehd-iec61937
		dtshd-iec61937

When I start playing on the first and I run `pactl list-sink-inputs` on the second I see the rtp input:

Sink Input #12
        Driver: module-rtp-recv.c
        Owner Module: 22
        Client: n/a
        Sink: 1
        Sample Specification: s16be 2ch 44266Hz
        Channel Map: front-left,front-right
        Format: pcm, format.sample_format = "\"s16be\""  format.rate = "44100"  format.channels = "2"
        Corked: no
        Mute: no
        Volume: front-left: 65536 / 100% / 0.00 dB,   front-right: 65536 / 100% / 0.00 dB
                balance 0.00
        Buffer Latency: 13862 usec
        Sink Latency: 4496 usec
        Resample method: speex-float-1
        Properties:
                media.role = "stream"
                media.name = "RTP Stream (PulseAudio RTP Stream on gravitino.home)"
                rtp.session = "PulseAudio RTP Stream on gravitino.home"
                rtp.origin = "mgalazyn 3901813754 0 IN IP4 10.0.0.220"
                rtp.payload = "10"
                module-stream-restore.id = "sink-input-by-media-role:stream"

So clearly metadata is getting transfered, but somehow there is no sound. I tried to troubleshoot the error by sending to a specified port and listening using vlc.
Updated config from first pc:

.include /etc/pulse/default.pa

load-module module-null-sink sink_name=rtp format=s16be channels=2 rate=44100 sink_properties="device.description='RTP'"
load-module module-rtp-send source=rtp.monitor source_ip=10.0.0.220 destination_ip=10.0.0.3 port=53000 
set-default-sink rtp

Running `vlc rtp://0.0.0.0:53000` on the second pc produces no output. Any ideas?

Last edited by carbolymer (2023-08-23 21:40:06)

Offline

Board footer

Powered by FluxBB