Author Topic: SOLVED - SPDIF Passthrough sound skipping/stuttering - Is it just me?  (Read 3111 times)

jeangot

  • Guru
  • ****
  • Posts: 233
    • View Profile
Hello,

I use a MSI Media Live box which uses an onboard HD Nvidia sound card with a Realtek ALC883 chipset. This is being handled under linux with teh snd-hda-intel driver.

I am very surprised that I don't find any mention of my problem in the board or wiki (unless I searched incorrectly) since many people seem to use this Media Live box which is highly recommended in the wiki. The problem is the following:
In the AW Wizard, I get proper DTS and AC3 in SPDIF Passthrough and everything is fine. But when trying to watch videos in LMCE (which uses the xine library) I randomly get files where the sound will break in and out constantly when using SPDIF out and digital audio (DTS or AC3). When I disable "passthrough" and watch the same files with PCM over SPDIF, it works just fine. The moment I try digitally encoded sound, the sound stutters.
I do have files however with digital sound (for example DTS) that played flawlessly.

The same problem occurs when playing the files with either Xine/Kaffeine or Mplayer under KDE.
I tried upgrading the alsa libraries and driver to the latest version 1.0.17. That didn't help.

I also tried countless recommended changes in xine.conf, asound.conf, muting unmuting etc, also with no luck.

One user recommends recuding the memory allocated to the Nvidia graphic card, but if I do that, the UI with alpha-blending gets very slow. I have NOT yet tried downgrading to overlay. MythTV seems to pass PCM over SPDIF at the moment, so I didn't see if the problem occurs there as well.

Is there someone out there running Digital sound over SPDIF with a media live? Did it just work out of the box or is there something I need to do? I'm not sure what else I could try at this point except buying a different sound card :-(

Thank you!

Jean
« Last Edit: February 19, 2009, 08:09:18 am by jeangot »

jeangot

  • Guru
  • ****
  • Posts: 233
    • View Profile
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #1 on: July 23, 2008, 07:00:54 pm »
If I switch to UI2 with overlay, I have the same problem, but if I use UI1, the sound is just fine!?! Now I'm even more confused because it could be caused by LMCE and not be a Linux problem?

totallymaxed

  • LinuxMCE God
  • ****
  • Posts: 4463
  • Smart Home Consulting
    • View Profile
    • Dianemo - at home with technology
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #2 on: July 23, 2008, 07:11:59 pm »
Hello,

I use a MSI Media Live box which uses an onboard HD Nvidia sound card with a Realtek ALC883 chipset. This is being handled under linux with teh snd-hda-intel driver.

I am very surprised that I don't find any mention of my problem in the board or wiki (unless I searched incorrectly) since many people seem to use this Media Live box which is highly recommended in the wiki. The problem is the following:
In the AW Wizard, I get proper DTS and AC3 in SPDIF Passthrough and everything is fine. But when trying to watch videos in LMCE (which uses the xine library) I randomly get files where the sound will break in and out constantly when using SPDIF out and digital audio (DTS or AC3). When I disable "passthrough" and watch the same files with PCM over SPDIF, it works just fine. The moment I try digitally encoded sound, the sound stutters.
I do have files however with digital sound (for example DTS) that played flawlessly.

The same problem occurs when playing the files with either Xine/Kaffeine or Mplayer under KDE.
I tried upgrading the alsa libraries and driver to the latest version 1.0.17. That didn't help.

I also tried countless recommended changes in xine.conf, asound.conf, muting unmuting etc, also with no luck.

One user recommends recuding the memory allocated to the Nvidia graphic card, but if I do that, the UI with alpha-blending gets very slow. I have NOT yet tried downgrading to overlay. MythTV seems to pass PCM over SPDIF at the moment, so I didn't see if the problem occurs there as well.

Is there someone out there running Digital sound over SPDIF with a media live? Did it just work out of the box or is there something I need to do? I'm not sure what else I could try at this point except buying a different sound card :-(

Thank you!

Jean

Hmmm... well the only thing we do when we ship an MSI Media Live based MD, we call them NC100'sm, is we turn off the analog audio in the Bios if the unit will be connected to a surround amplifier. Apart from that we do NO special config to make SPDIF work.

All the best

Andrew
Andy Herron,
Convergent Home Technologies Ltd

My Blog; http://ellipticalcurve.com

Get RaspSqueeze-CEC Wifi enabled for Dianemo/LinuxMCE: http://wp.me/P4KgIc-7C

Contact me for Smart Home consulting advice here;
@herron on Twitter, inquiries@ellipticalcurve.com via email or PM me here.

Get a Dianemo License: http://forum.linuxmce.org/index.php?topic=8880.msg100221#msg100221
Follow us on Facebook: https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465

Sales & Info:
http://www.dianemo.co.uk

jeangot

  • Guru
  • ****
  • Posts: 233
    • View Profile
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #3 on: July 23, 2008, 07:20:28 pm »
Andrew,

thanks, I will try that, and if that does not work I will look towards the possibility of a hardware problem (trying a separate sound card or something).
That's exactly the answer I needed, to make sure that there were no special tricks.

Jean

totallymaxed

  • LinuxMCE God
  • ****
  • Posts: 4463
  • Smart Home Consulting
    • View Profile
    • Dianemo - at home with technology
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #4 on: July 23, 2008, 07:49:25 pm »
Andrew,

thanks, I will try that, and if that does not work I will look towards the possibility of a hardware problem (trying a separate sound card or something).
That's exactly the answer I needed, to make sure that there were no special tricks.

Jean

Np Jean... let me know how you get on.

All the best

Andrew
Andy Herron,
Convergent Home Technologies Ltd

My Blog; http://ellipticalcurve.com

Get RaspSqueeze-CEC Wifi enabled for Dianemo/LinuxMCE: http://wp.me/P4KgIc-7C

Contact me for Smart Home consulting advice here;
@herron on Twitter, inquiries@ellipticalcurve.com via email or PM me here.

Get a Dianemo License: http://forum.linuxmce.org/index.php?topic=8880.msg100221#msg100221
Follow us on Facebook: https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465

Sales & Info:
http://www.dianemo.co.uk

jeangot

  • Guru
  • ****
  • Posts: 233
    • View Profile
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #5 on: July 24, 2008, 03:59:44 am »
Andrew,

disabling the analog portion of the sound card didn't change anything unfortunately. The fact that it works in UI1 still sound svery strange, so I was jut wondering: what display driver do you use? The default closed source nvidia driver enclosed with 07.10, or do you upgrade this to a later driver from nvidia's website, and if so which version?


Also do you know if it's possible to update the bios on these machines from linux, or do I need to run windows for that?


Jean

colinjones

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 3003
    • View Profile
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #6 on: July 24, 2008, 05:08:41 am »
maybe a silly question, but have you combed through you dmesg for initialisation or ongoing probs with the sound hardware? Also, through your /var/log/Xorg.0.log file for any initialisation or ongoing issues with X's use of sound?

btw, my sound when starting KDE is heavily corrupted - sounds stuttering/gated/clipped, and has for many rebuilds under some of the recent versions, but it has never effected sound in LMCE, I get perfect sound through my SPDIF, stereo or multichannel...

totallymaxed

  • LinuxMCE God
  • ****
  • Posts: 4463
  • Smart Home Consulting
    • View Profile
    • Dianemo - at home with technology
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #7 on: July 24, 2008, 11:10:03 am »
Andrew,

disabling the analog portion of the sound card didn't change anything unfortunately. The fact that it works in UI1 still sound svery strange, so I was jut wondering: what display driver do you use? The default closed source nvidia driver enclosed with 07.10, or do you upgrade this to a later driver from nvidia's website, and if so which version?


Also do you know if it's possible to update the bios on these machines from linux, or do I need to run windows for that?


Jean

We use the LinuxMCE-0710 default nVidia drivers.

Andrew
Andy Herron,
Convergent Home Technologies Ltd

My Blog; http://ellipticalcurve.com

Get RaspSqueeze-CEC Wifi enabled for Dianemo/LinuxMCE: http://wp.me/P4KgIc-7C

Contact me for Smart Home consulting advice here;
@herron on Twitter, inquiries@ellipticalcurve.com via email or PM me here.

Get a Dianemo License: http://forum.linuxmce.org/index.php?topic=8880.msg100221#msg100221
Follow us on Facebook: https://www.facebook.com/pages/Dianemo-Home-Automation/226019387454465

Sales & Info:
http://www.dianemo.co.uk

rodercot

  • Guest
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #8 on: July 24, 2008, 02:45:10 pm »
maybe a silly question, but have you combed through you dmesg for initialisation or ongoing probs with the sound hardware? Also, through your /var/log/Xorg.0.log file for any initialisation or ongoing issues with X's use of sound?

btw, my sound when starting KDE is heavily corrupted - sounds stuttering/gated/clipped, and has for many rebuilds under some of the recent versions, but it has never effected sound in LMCE, I get perfect sound through my SPDIF, stereo or multichannel...

 Colin,

 I only get this the first time I enter kde after a clean install. Then once the newest Nvidia driver is installed I get nice clean sound going into KDE.

 Jean,

 I am not sure if it matters but there is a buffer setting in KDE system properties hit the K blue button and then the first selection above the black line from the bottom up. The sound system hardware.

 rgds,

 Dave.

colinjones

  • Alumni
  • LinuxMCE God
  • *
  • Posts: 3003
    • View Profile
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #9 on: July 24, 2008, 03:23:52 pm »
dave, what version drivers are you using. I haven't bothered upgrading them yet so I am still using the default 169.12

rodercot

  • Guest
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #10 on: July 24, 2008, 05:09:54 pm »
Colin,

 I am using 173.14.05 on the hybrid but the default on the Nvidia site is now 173.14.09 and they just released 177.13 as a beta which people seemed to be using in Hardy with no issues that I can find. I tried 173.14.09 and 177.13 (It automagically deletes the old driver install by the way) I tried both drivers in hopes of getting HDMI-Audio with no luck. It seemed odd that all the other installs that use the HDa Intel.c audio driver  put a iec switch in the input section and these drivers do not for some reason. Although alsamixer sees that iec switch when looking in there I cannot mute or unmute it and it seems disabled, I did check the asound.conf file but was not sure how to add the extra plughw 1,0 which right now reads plughw 0,0. Which could have been the problem with the hdmi audio but not sure.

 Anyhow that is off topic for this thread - just a little testing info to let you know about.

 Regards,

 Dave

jeangot

  • Guru
  • ****
  • Posts: 233
    • View Profile
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #11 on: July 25, 2008, 12:32:35 am »
Hello Guys,

thanks for jumping in. No I don't see anything suspicious in my dmesg or in xorg.log (does this have any info about sound anyway? I always only see video related things in there and that part is working fine).
Since the difference between UI1 and UI2 is OpenGl, I thought that this could somehow be interfering, hence my asking about video drivers, but I use the exact same setup as Andrew it seems.
I guess I can try to experiment with various versions of Nvidia drivers to see if it helps, since I don't have any other ideas at the moment.

I wanted to run UI2 with a different driver than the nvidia driver to rule it out, but it won't start with vesa or with nv driver, so the only option for me is to try a very old or very new driver version...

Dave: I will check on that buffer setting tonight and play with it, thanks.

I will let you know if I find the solution!

This was an open box system from newegg, so I'm not sure if I can even RMA it...

jeangot

  • Guru
  • ****
  • Posts: 233
    • View Profile
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #12 on: July 25, 2008, 12:43:05 am »
One more note: I do see errors about "nv_nic_irq" in dmesg and not sure if that could be related and what it means

Also when running these videos in KDE with xine --verbose (where the sound has the same problem), I get a lot of:
fixing sound card drift by -2115 pts
errors

According to Xine:
Quote
Audio is stuttering and i see a lot of "metronom: fixing sound card drift by -2115 pts" on the console output
Might be a soundcard problem, if it only comes in longer intervals. Your soundcard does not keep it's sampling frequency accurately enough, which results in audio and video getting out of sync and xine has to compensate. If you see the message only from time to time, you might remedy it by using the resampling sync method. You can do this by setting the configuration entry audio.synchronization.av_sync_method to resample.

If you receive the metronom message more often, maybe switching to different drivers (alsa to oss or vise-versa) can help here. It has also been reported that setting the configuration entry audio.synchronization.force_rate to the native sampling rate of your soundcard (try 44100 and 48000) helps sometimes.

Another, whole different possibility is that you have some background process running which is messing with the clock (like some ntp client - chronny, ntpd, ...).

Occasional messages of "fixing sound card drift" may happen on start and when playing a long stream (like a movie). This is normal behaviour, nothing to worry about.


I tried the suggestions about changes in xine.conf, then restarted xine and explicitely specified the xine.conf file just to be sure it was read, and that didn't help.

jeangot

  • Guru
  • ****
  • Posts: 233
    • View Profile
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #13 on: July 25, 2008, 06:52:38 pm »
Hello,

after some of your suggestions I made the following test:

in UI2: I open KDE Desktop, and playback a file there. Sound is choppy and breaking off. Now if I click on "stop media station" in the lmce control pannel, the sound becomes perfect when the media station (meaning all the LMCE components running on that machine) is stopped! Start it again, and the sound becomes choppy again.
I then tried to kill various devices while Media Station is up, such as OrbiterGL, App_Server, HAL etc, but that didn't bring back sound so far, so I don't know yet which particular device causes this.

One thing that could be important and that I didn't mention so far: I have a development environement setup on this machine, as explained in the wiki. Is there maybe any possibility that installing this dev environement updated the one or other library, and that this could be causing the problem? Somehow there must be a difference between my system and your guys' systems, so that could be it? I think that the problem was already there before I installed the dev environement last time, but I'm not 100% sure.

And as a reminder, sound is always Ok in UI1.

Jean

jeangot

  • Guru
  • ****
  • Posts: 233
    • View Profile
Re: SPDIF Passthrough sound skipping/stuttering - Is it just me?
« Reply #14 on: July 29, 2008, 01:56:31 am »
A little update since I'm still having this problem:

I tried running a video in KDE with the Orbiter/Media Station running (bad sound). Then tried to kill every single device running on the MD until the sound started working, to find which one causes the problem. Killing Xine_Player, Mplayer_Player, MythTV etc all don't change anything, only when I kill OrbiterGL, then the sound starts working fine. If anyone has an idea what this could mean, please let me know by all means as I am running out of ideas. I'm going to try every single driver version from Nvidia to see if that makes a difference, based on the theory that it could have to do with OpenGL...

Also another interesting test I made, was that I tried using the coax digital output instead of optical, and that gives me exactly the same problem, which rules out a bunch of possible hardware problems in the sound card or in my receiver...

Jean