SPDIF loses signal

Discussion in 'all things UNIX' started by Murderlove, May 16, 2010.

Thread Status:
Not open for further replies.
  1. Murderlove
    Offline

    Murderlove Registered Member

    Dear readers,

    I have been using Linux on and off. I have just installed Ubuntu 10.04 via the Wubi installer. I have come across a problem which I can not solve on my own. I therefor need your kind help.

    This is my setup:
    Asus Xonar Essence STX soundcard --> optical/SPDIF connection--> DAC--> RCA-connection--> Amplifier--> RCA connection--> 2 speakers and a subwoofer.

    I think that the drivers for the Asus Xonar STX are installed. I am not really sure about this because in my soundsettings I do not see what is displayed on this picture:
    http://techgage.com/viewimg/?img=/a..._linux_101909.png&desc=ASUS Xonar Under Linux
    Source:
    http://techgage.com/article/using_the_asus_xonar_essence_stx_under_linux/

    I am having troubles with this part of the review: "Although the Xonar uses a popular audio chipset (C-Media CMI878:cool: shared by many other high-end cards, such as from Auzentech, there's a special driver in ALSA specifically for Xonar, called "virtuoso". Most Linux distros should detect and install this driver upon booting up, or during the install, but if you have to install it manually (beyond the scope of this small article), it's "Asus Virtuoso 100/200 (Xonar)" you want to look for, under Device Drivers > Sound card support > ALSA > PCI sound devices. Once that driver is compiled, it can be loaded into the kernel as "snd-virtuoso"."

    Having said that, I have installed the latest ALSA drivers and selected the STX as my default soundcard. I have disabled the onboard sound via the BIOS.

    Here is my problem:
    I have been able to get sound, both analog as well as digital. Howevermy DAC displays that I do not have a signal until I play a soundfile. The moment I play a soundfile, the DAC displays 44.1KHz, then I hear a crackling/thunder sound for just a few seconds and then the soundfile plays. The crackling/thunder sound is there for only a few seconds, but it is really annoying.

    What worries me is that my DAC displays that I do not have a signal unless I play a soundfile. It is as if the SPDIF/optical output is put into hibernation untill a sound is being played. Because of a certain cable I use I can see when the SPDIF/optical output is on, or off. A light will go on when the output is on. When I am not playing a soundfile the DAC somehow loses connection and restarts when a sound is being played.

    I have tested this with oboard sound as well and I have the exact same problem.

    My question to you is: what do I need to do so that the SPDIF/optical output won't loose signal but remains on all the time? That crackling sound is really annoying.

    I look forward hearing from you.

    PS: the above described problem is not there in windows.
  2. NoIos
    Offline

    NoIos Registered Member

    Have you tried to set acpi = off and see if changes something.
    I have really not much experience troubleshooting audio problems in linux but you could give my advice a try. Others will help you here too, I'm sure about it.
  3. linuxforall
    Offline

    linuxforall Registered Member

    Is your sound card being detected right under system>preferences>sound devices?

    If that works you may need to upgrade ALSA, there is an easy way out with a script.
  4. Murderlove
    Offline

    Murderlove Registered Member

    How do I set acpi = off?

    My soundcard is detected, athough it doesn't say that it is the Asus Xonar Essence STX, but HD audio. I already have the latest version of ALSA installed. But I am interested in that script.

    Here is a picture of what I see regarding soundsettings:
    http://www.plaatjesupload.nl/bekijk/2010/05/16/1274026161-450.png
    Last edited: May 16, 2010
  5. linuxforall
    Offline

    linuxforall Registered Member

    Here you go http://ubuntuforums.org/showthread.php?t=1046137
  6. Murderlove
    Offline

    Murderlove Registered Member

    Thank you.

    EDIT 1:
    I have followed the steps in the guide above regarding the installation of the latest ALSA. I am still getting the "no signal" display on my DAC if I do not play a sound file. However I do not hear the crackling/thunder sound anymore when I start up a sound file :). Unfortunately a side effect of that script is that my sound slider does not work. I can't put sound higher or lower via system>preferences>sound devices. Even if I mute sound there is still coming sound out of my speakers. Whilst I do have a sound slider on my amplifier it is still annoying that I can't turn the volume up or down via the OS.

    EDIT 2:
    I found out that I can't turn the volume up or down when I'm playing youtube files. When I am playing MP3's of my harddisk the volume slider works :D

    EDIT 3:
    Unfortunately the crackling sound has returned.
    Last edited: May 16, 2010
  7. NoIos
    Offline

    NoIos Registered Member

    For setting acpi = off I believe the best place to get infos:
    https://help.ubuntu.com/community/Grub2

    Check this link and more specifically the chapter:
    Configuring GRUB 2
    and then the voice:
    GRUB_CMDLINE_LINUX_DEFAULT
  8. linuxforall
    Offline

    linuxforall Registered Member

    Check this thread for cracking sound.
  9. Murderlove
    Offline

    Murderlove Registered Member

    Thank you, I will check that out.

    Which thread? The thread that you had posted regarding the ALSA script? I am indeed reading that thread and the links posted in that thread, I haven't seen anyone who reports that the SPDIF output loses signal so far.
  10. linuxforall
    Offline

    linuxforall Registered Member


    Sorry bout that.

    http://ubuntuforums.org/showthread.php?t=987252
  11. Murderlove
    Offline

    Murderlove Registered Member

    Thank you. Unfortunately that thread did not offer a solution. Maybe I need to give Ubuntu Studio a try.
  12. linuxforall
    Offline

    linuxforall Registered Member

    Ubuntustudio won't do much, it comes with real time kernel which is good for audio editing, apart from that its Ubuntu all the way, maybe you can try a newer kernel to see if this issue goes away.
  13. Murderlove
    Offline

    Murderlove Registered Member

    Hello everyone,

    Just a quick update. I have finally been able to get my sound working. After some research (4 sound-cards(2 onboard, 2 third party) and 2 motherboards further) I found out that Pulseaudio was the culprit. I simply couldn't get my sound to work with Pulseaudio. Analog sound works fine, it becomes a problem when using S/PDIF.

    What I understood was that there was a delay of sound regarding Pulseaudio, I did not notice this delay with Analog sound, but did notice it with S/PDIF. This delay causes the sound to crackle at first. After reading this page:
    http://howto.blbosti.com/2010/04/ubuntu-make-alsa-default-instead-of-pulseaudio/
    I was finally able to make ALSA default and my sound works perfectly. My S/PDIF connection still loses signal when there is no sound file being played, but at least there is no soundcrackle.

    It's such a shame that I am unable to get it to work with Pulseaudio. What's even more a shame is that one isn't able to switch to ALSA or OSSv4 anymore without doing these workarounds. It's as if Pulseaudio is being forced upon us.
  14. linuxforall
    Offline

    linuxforall Registered Member

    Pulseaudio is the reason I switched to Pulseless KDE Kubuntu with arts and phonon and sound is way superior from my ancient Yamaha sound card. Pulse would make the sound crack.
Thread Status:
Not open for further replies.