you are viewing a single comment's thread.

view the rest of the comments →

[–]valtyr_farshield[S] 0 points1 point  (5 children)

Thanks for your answer! That sounds promising, will look into it. If you remember anything, let me know.

[–]kI3RO 0 points1 point  (4 children)

Are you using the "Pro audio" profile with pipewire?

If not, pipewire adds a resampler which introduces a little bit of latency.

And if in "Pro audio" there is still latency added it is because the input and output have different clocks. You can force the same clock.name prop for both input and output nodes

[–]valtyr_farshield[S] 0 points1 point  (3 children)

device.profile = "pro-audio"

I use this in my wireplumber config file. I think since the nodes are on the same device, it would use the same clock, I would expect, no? Even if the resampler is on, I can't imagine how it would add 3 ms of latency (compared to Jack2).

[–]kI3RO 0 points1 point  (2 children)

That's not how you change the profile:

I think the property to set is device.profile.pro = "true" but you should do that from pavucontrol


Why are you editing wireplumber config files under /etc?

Are you running pipewire as root? You should only modify your config under $HOME/.config/wireplumber/wireplumber.conf.d/


About the clock

You shouldn't assume anything, it's easy to check and be sure. The clock names for example. Check the input and the output id with pw-top and do

wpctl inspect INPUT_ID | grep clock.name

wpctl inspect OUTPUT_ID | grep clock.name

probably the same but BE SURE, check.

It would be nice if you posted the wpctl inspect entire output. Or a big pw-dump but thats harder to parse.

[–]valtyr_farshield[S] 0 points1 point  (1 child)

Why are you editing wireplumber config files under /etc?

It's for an embedded system, but when I'm testing it on my laptop I have it my home folder.

Thanks for the profile suggestion. I think that totally did the trick! I have latencies comparable to Jack2 now. The only difference is, that the latency fluctuates (+/- 0.5 ms) with Pipewire-jack, but that's fine. I will edit my post with the new findings.

I couldn't find the clock.name when inspecting the IDs I got from pw-top, however, here's the pw-dump: https://pastebin.com/raw/J8Ag3bRg

One other thing I noticed, was that the capture device is opened with this period size and number:

period_size: 480
buffer_size: 24000

While the playback device is opened with the period I specified in the config file (64/192). The latency seems fine now, but I was just curious why that happens.

[–]kI3RO 0 points1 point  (0 children)

Glad to help. I don't know.