[pulseaudio-discuss] Latency/lag with tcp tunnel
matthew.garman at gmail.com
Tue Jan 26 20:08:57 UTC 2021
On Mon, Jan 25, 2021 at 9:27 PM Matt Feifarek <matt.feifarek at gmail.com> wrote:
> My guess is that it's likely in the amp; did you try hooking up the Topping to the new pi? Or, the converse; hook the amp up to the workstation and see if you see a delay?
I have a bad feeling that might indeed be the problem, but wanted to
eliminate any possible problem with my software config first.
Swapping the RPI 3 and 4 is indeed a perfectly valid suggestion.
Admittedly, I haven't done that because it's a lot of hardware
reworking, was hoping to deduce the program with only config changes
and such (ok, ok, I'm lazy!).
> Does the Pi have a USB soundcard, or a "hat" sort of thing? Some of the hats have buffers in them to reclock the audio signal; this can add a delay too. I'm not familiar with the MA12070P, but as it's I2S, maybe it is adding a buffer.
The ma12070p is a newish digital input (I2S) class D amplifier
(essentially, a "power DAC" or a DAC and amplifier in one chip).
Between the RPI and amp is an Allo Kali I2S reclocker. I don't think
the Kali adds any meaningful latency, as I've used it extensively with
other I2S DACs, and never before noticed lag. I do know that the
various controls of the ma12070p (volume, I2S format, etc etc) are
done via the I2C serial bus, which I don't believe is a
> You can login to the pi over ssh and turn up logging to a very verbose degree and watch it, you'll see messages about measured latency, probably both on the "server" (the Pi) and on the client (your workstation).
Good idea, I will do that and report back.
> Regarding your last question, you could certainly login to the Pi, put a wav file over there, and do "paplay file.wav" and see if the delay after hitting enter "feels" the same as over the network. My guess is that it will.
I did that both directly on the RPI server, and the workstation client
as well. It does seem like there is a lag doing paplay directly on
the server. The lag might be slightly greater on the client, but I
wouldn't swear to it. (It's one of those things that's so simple and
trivial, yet when I do it multiple times in a row, I start
second-guessing myself, kind of like when you say the same word over
and over again, it starts to sound foreign after enough repetitions.)
> If the delay can't be worked around, there might be ways to tell the pulse audio stack to account for it in playback to get for example your YouTube to sync up right. I know that VLC can do this.
It might come to that. I'll continue to investigate, see if I can
conclusively determine if that's the fundamental issue.
More information about the pulseaudio-discuss