Closed garglkarg closed 3 years ago
Ok seems directly related to Ticket #628 but snapclient keeps running with dropouts. I can clearify that this issue is related to the package _snapclient_0.24.0-1_without-pulsearmhf.deb from release page - tried raspian repo package version 15 which has no error in logs or maybe older versions just did not log the error?
is there a reason to not provide a debug log? Did you try a cable connection?
is there a reason to not provide a debug log? Did you try a cable connection?
it's a cabled connection. do you think it's a problem with the LAN? I can try to isolate this error by putting both on behind the same switch... that above is the debug log - or not? it's the output I get when using "--logfilter *:debug"
interestingly the dropout occurs exactly every 5 secs / on different servers and devices (after I upgraded all to 0.24.0-1)
Apr 16 15:10:31 ratzefatz snapclient[15068]: ServerSettings - buffer: 1000, latency: 500, volume: 55, muted: 0
Apr 16 15:10:31 ratzefatz snapclient[15068]: PCM name: default:CARD=Headphones, sample rate: 48000 Hz, channels: 2, buff
Apr 16 15:10:32 ratzefatz snapclient[15068]: pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50): -181972
Apr 16 15:10:37 ratzefatz snapclient[15068]: pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50): -164972
Apr 16 15:10:42 ratzefatz snapclient[15068]: pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50): -190815
Apr 16 15:10:47 ratzefatz snapclient[15068]: pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50): -209219
Apr 16 15:04:47 sundance snapclient[8082]: Sampleformat: 48000:16:2, stream: 48000:16:2
Apr 16 15:04:47 sundance snapclient[8082]: Using default buffer_time: 80 ms, default fragments: 4
Apr 16 15:04:47 sundance snapclient[8082]: PCM name: default:CARD=sndrpihifiberry, sample rate: 48000 Hz, channels: 2, buffer time: 80000 us, periods: 4, period time: 20000 us, period frames: 960
Apr 16 15:04:47 sundance snapclient[8082]: No chunks available
Apr 16 15:04:47 sundance snapclient[8082]: Failed to get chunk
Apr 16 15:04:52 sundance snapclient[8082]: pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50): -212020
Apr 16 15:04:57 sundance snapclient[8082]: pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50): -181919
Apr 16 15:05:02 sundance snapclient[8082]: pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50): -180865
Apr 16 15:05:07 sundance snapclient[8082]: pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50): -164307
Apr 16 15:05:12 sundance snapclient[8082]: pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50): -179031
Apr 16 15:05:17 sundance snapclient[8082]: pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50): -192176
Apr 16 15:05:22 sundance snapclient[8082]: pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50): -185033
found out it's resync time on the server:
Apr 16 15:16:42 asterix snapserver[1555]: onResync (Wohnzimmer): 106.642 ms
Apr 16 15:16:47 asterix snapserver[1555]: onResync (Wohnzimmer): 102.478 ms
Apr 16 15:16:52 asterix snapserver[1555]: onResync (Wohnzimmer): 120.415 ms
Apr 16 15:16:57 asterix snapserver[1555]: onResync (Wohnzimmer): 112.148 ms
Apr 16 15:17:02 asterix snapserver[1555]: onResync (Wohnzimmer): 102.488 ms
Apr 16 15:17:07 asterix snapserver[1555]: onResync (Wohnzimmer): 121.031 ms
Server Environment details
using bluealsa and mpd for streaming to different fifo pcm both with the same problem server load is low
snapserver.conf
[stream]
source = pipe:///tmp/snapparent?name=Wohnzimmer
source = pipe:///tmp/snapchilds?name=Kinder
source = pipe:///tmp/snapblue?name=Mobile
it's all about the PCM. I switched all snapserver stream inputs to alsaloop device and it works without any hickups!
Any idea why using PCM via pipes is causing the issue? I am experiencing something similar (documented here: https://github.com/badaix/snapcast/discussions/924#discussioncomment-2473737). Essentially, whenever sending audio via pipes, snapserver experiences regular resyncs, causing dropouts.
snapclients errors with pMiniBuffer->full() && (abs(pMiniBuffer->mean()) > 50)
I have a snapserver supplying direct mpd and bluealsa PCMs as flac stream. This works fine on the raspberry on board audio and raspberry with HifiBerry Amp2. But I have dropouts on the environment below (I have dropouts on my raspberry with miniamp too but maybe this is related). I have read this #774 Ticket but playing with the buffer_time and fragments did not fix my issue. I tried to play around with my /etc/asound.conf but it seems to make no difference so I wiped it out again.
Environment details
logfile without /etc/asound and clean /etc/default/snapclient (except debug log output)
Suggestions? Additional Infos needed?
Many thanks for this wonderfull project!! in combination with bluealsa it gives me the full control for my hifi system / real great work!