More > JRiver Media Center 23 for Linux

Rpi audio micro freeze on USB playback (resolved)

(1/2) > >>

erviv:
I have MC23 ver 93 installed on my RPi 3.  I play music two ways, both initiated by JRemote:

(1) initiate the play command from JRemote on my iPad to the rpi. The rpi sends the audio signal out via usb to a DAC (Bryston BDA2, and then through my pre-amp, amp to speakers) and

(2)  initiate the play command from JRemote on my iPod.  The audio signal travels from the rpi to the iPod via wifi and then out through a DAC (CypherLabs AlgoRhythm Solo -R, and then through a receiver and speakers). 

I would have thought that audio via wifi would experience issues, however the opposite is the case.  I have not noticed any audio micro dropouts/freezes via the iPod.  However I do get random micro freezes (stop/starts) via the usb output.  The playback stops and then in less than a second continues to playback from where it stopped.

I have set my thread priorities as per instructions in this forum, and also have checked the disable audio buffer to disk in the Tools/Options/Media Network/ Advanced.  This seems to have helped reduce the frequency and duration of the micro freezes. However the problem persists.

Has anyone overcome a similar problem?

Zhillsguy:
I can't speak to your exact problem.... but I have been tinkering with a Pi3 now for a few weeks. It is also set up with thread priorities, latest build, etc. In my experience:

1. If the Pi is "busy" such as importing, building thumbnails, etc. it can hiccup. Once it settles in it is fine.

2. Since the Pi's USB bus includes the network adapters, it can get bottlenecked fairly easily, causing buffering/hiccups. I haven't had good luck using its wireless for anything other than maybe MP3 playback. I recommend the ethernet port, not wifi.

3. Playing hi res audio works to an extent, but I recommend using a DAC that natively supports whatever bitrate you are playing. Make sure in MC your DAC is using a hw:, plughw:, or front: ALSA connection with no conversions. Converting bit rates on the fly can cause buffering/stuttering. Use only whatever DSP is necessary. I recently bought a hifiberry and it plays natively very well up to 192 KHz. I really like it.

4.  I haven't found much difference whether playing from the Main Library, a server library, or as a DLNA renderer (if no conversion is used).

Keep an eye on the CPU usage during various routines, maybe you can figure it out. Playing 192KHz files natively uses typically between 10-15%. When that little CPU spikes up it can cause audio problems. It could be you are not experiencing issues playing to the IPod because it is down-converting, and the USB is playing full native format. You didn't mention what files you are playing or what the source is (network, attached drive, etc.). Keep in mind all the data in/out of the pi is on the same USB bus. Keeping the data bandwidth within reason helps.

Hope this helps.

erviv:

Thanks for the feedback. 
I have micro freezes on CD quality playback as well as hi-res audio (192k).  The music source in both cases is the same.  It is a hard wired via network cable to a router which has a hard drive connected to the router.  Since the source is the same in both cases I was thinking that it is not the problem.
I believe  the rpi/MC is down converting when sending over wifi an audio signal to the iPod.  It is interesting though that down converting does not result in micro freezes while sending out natively does. I would think down converting uses more resources than sending out an unconverted signal.  This would lead me to look at the USB as being the issue.  The issue then is how to fix this.   An option, as you have shown, is the use of another audio digital output mechanism, eg hifi berry.  Still I am hoping for a solution within MC settings.  I will try logging the error and see if anything jumps out at me.  I looked previously and nothing was obvious to me.
My Bryston DAC does natively support the bitrates that is being played.  The Bryston is recognized by MC and I have selected the hw: version with no conversions.
I will investigate further and watch the CPU usage.

astropuppy:

--- Quote from: erviv on January 20, 2018, 08:43:19 am ---Thanks for the feedback. 
I have micro freezes on CD quality playback as well as hi-res audio (192k).  The music source in both cases is the same.  It is a hard wired via network cable to a router which has a hard drive connected to the router.  Since the source is the same in both cases I was thinking that it is not the problem.
I believe  the rpi/MC is down converting when sending over wifi an audio signal to the iPod.  It is interesting though that down converting does not result in micro freezes while sending out natively does. I would think down converting uses more resources than sending out an unconverted signal.  This would lead me to look at the USB as being the issue.  The issue then is how to fix this.   An option, as you have shown, is the use of another audio digital output mechanism, eg hifi berry.  Still I am hoping for a solution within MC settings.  I will try logging the error and see if anything jumps out at me.  I looked previously and nothing was obvious to me.
My Bryston DAC does natively support the bitrates that is being played.  The Bryston is recognized by MC and I have selected the hw: version with no conversions.
I will investigate further and watch the CPU usage.

--- End quote ---

I would plug the hard drive plugged into the router directly into the PI as a test. Generally speaking, routers have small cpu's.

Just an idea.

JimH:
And a hard drive plugged into a Pi may not have enough power.

Navigation

[0] Message Index

[#] Next page

Go to full version