ALSA Question
#1
I wanted to pass through high def audio to my AVR with Kodi on my HTPC and followed the instructions to disable Pulse Audio by adding autospawn = no to client.conf. Everything works perfectly while watching videos in Kodi just as I wanted.

However when I exit Kodi and try to watch a YouTube video or other sources I do not hear any audio at all. I'm a bit new to Linux so not sure what might be happening and how to potentially fix it. Did the fix I made for Kodi disable sound in other non-Kodi applications (even when Kodi is shut down)?

I am running Kodi 16.1 on Ubuntu 16.04 and using an NVidia GT 430 video card and HDMI for video and audio.
Reply
#2
This "fix" disables pulseaudio, globally. So webbrowser and so on cannot mix properly. If you only use AC3, DTS, EAC3 - then pulseaudio can be configured to do that, also (see our pulseaudio wiki)
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#3
Thank you. I do want to use ALSA for Kodi because I want to use HD Audio passthrough. When I exit Kodi, how can I get audio from other applications like YouTube or Firefox, ideally still using ALSA?
Reply
#4
"Ideally still using ALSA"?

Create an /etc/asound.conf that has your hdmi output as default device, reboot - done.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#5
(2016-10-01, 22:19)fritsch Wrote: "Ideally still using ALSA"?

Create an /etc/asound.conf that has your hdmi output as default device, reboot - done.

Do you have an example of this file? I'm new with Linux. I couldn't find anything through Google that would give me any clue on what to put in that file. Thanks.
Reply
#6
(2016-10-01, 22:29)andydufresne Wrote:
(2016-10-01, 22:19)fritsch Wrote: "Ideally still using ALSA"?

Create an /etc/asound.conf that has your hdmi output as default device, reboot - done.

Do you have an example of this file? I'm new with Linux. I couldn't find anything through Google that would give me any clue on what to put in that file. Thanks.

would this be what i should put there?

pcm.!default {
type hw
card 0
}

ctl.!default {
type hw
card 0
}
Reply
#7
Most likely no :-)

it depends on the alsa output, check: aplay -l (small "ell") to find out the correct card and it's output
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#8
Here is the output of aplay -l. I think device 9 is the active HDMI

**** List of PLAYBACK Hardware Devices ****
card 0: NVidia [HDA NVidia], device 3: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: NVidia [HDA NVidia], device 7: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: NVidia [HDA NVidia], device 8: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: NVidia [HDA NVidia], device 9: HDMI 0 [HDMI 0]
Subdevices: 1/1
Subdevice #0: subdevice #0
Reply
#9
Code:
pcm.!default {
  type plug
  slave {
    pcm "hw:0,3"
    rate 48000
  }
}

Remember: This won't allow mixing of two streams, e.g. two tabs at once. You should better toy with a script or using the ALSA hack, the pulseaudio wiki presents.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#10
(2016-10-01, 23:28)fritsch Wrote:
Code:
pcm.!default {
  type plug
  slave {
    pcm "hw:0,3"
    rate 48000
  }
}

Remember: This won't allow mixing of two streams, e.g. two tabs at once. You should better toy with a script or using the ALSA hack, the pulseaudio wiki presents.

Thank you, I will try this.

By ALSA hack, do you mean this? Launch Kodi with: pasuspender -- env AE_SINK=ALSA kodi
Reply
#11
Yes.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#12
Thank you. Both work. Solved.
Reply
#13
Hi, please help me.

I am unable to pass through high def audio (e.g. DTS-HDMA) to my AVR with Kodi on my HTPC using ALSA.

I'm using Kodi 17.4 on Ubuntu 16.04.3.

- I modified /etc/pulse/client.conf (autospawn=no)
- I created /etc/asound.conf
Code:
pcm.!default {
  type plug
  slave {
    pcm "hw:0,3"
    rate 192000
  }
}

but I get an upconverted (192 kHz) PCM signal instead of wanted DTS-HDMA.

What do I do wrong?

Thnaks in advance for your help!
Reply
#14
No Debug Log no issue - no chance to help.
First decide what functions / features you expect from a system. Then decide for the hardware. Don't waste your money on crap.
Reply
#15
Debug log:

https://pastebin.com/nWRe4VA4

(I don't know, what is that device 1)
Reply

Logout Mark Read Team Forum Stats Members Help
ALSA Question0