Archive:Set up HDMI audio on GeForce GT210, GT220, or GT240

From Official Kodi Wiki
Jump to navigation Jump to search
Time.png THIS PAGE IS OUTDATED:

This page or section has not been updated in a long time, no longer applies, refers to features that have been replaced/removed, and/or may not be reliable.

This page is only kept for historical reasons, or in case someone wants to try updating it.

XBMC Live [Eden] 11.0

May 4, 2012

Update : Lesser configuration in Eden:

In XBMC System => System => Audio output [Both Audio Out and passthrough] on custom : hdmi:CARD=NVidia

Use :

add-apt-repository ppa:team-iquik/alsa
add-apt-repository ppa:ubuntu-audio-dev/ppa
apt-get update
apt-get upgrade

When you dont have sound, start alsamixer, choose your card, en unmute it (M).

If this still dont works, use the manual below.

XBMC Live [Dharma] 10.1

April 11, 2011

EVGA GT210 - added file "sudo nano /etc/asound.conf" for menu sound

pcm.!default {
   type plug
   slave {
       pcm "hw:0,3"
       rate 48000
   }
}

In XBMC System => System => Audio output [Both Audio Out and passthrough] on custom "plughw:0,3" [Card 0, Device 3 from "aplay -l in telnet"]

Update: Didn't need to put custom "plughw:0,3" "HDA Nvidia hdmi" works also. Tested with G210 / Asus EN210


Before You Begin/Notes

This guide assumes that you have a GeForce G210, GT220, or GT240 card, are using a reasonably up-to-date system, and that you have at least the nVidia 190 series proprietary drivers installed.

Getting ALSA

Team iQuick also has a PPA with the latest ALSA drivers and Ubuntu Audio Dev PPA has the necessary kernel modules for Lucid (What XBMC-Live is based on).

add-apt-repository ppa:team-iquik/alsa
add-apt-repository ppa:ubuntu-audio-dev/ppa
apt-get update
apt-get upgrade
apt-get install linux-alsa-driver-modules-$(uname -r) --force-yes

Or if you haven't yet installed ALSA:

apt-get install alsa-base alsa-utils linux-alsa-driver-modules-$(uname -r)

Compiling from source:

ALSA 1.0.23 contains the new drivers. You can download, compile, and install it without further additions, and proceed to configuration. The drivers are also included with the 2.6.34 Linux kernel; users of this kernel should be able to skip straight to configuration as long as the snd_hda_codec_nvhdmi module (and its dependencies) are available.

In general, you can choose to install ALSA from source or use the ALSA Upgrade Script. Alternatively, you can find updated packages for your distribution. Note that only the drivers from 1.0.23 or later are required; updating the ALSA userspace tools is optional.

Ubuntu users make sure to remove the linux-backports-modules-alsa-`uname -r` package or your newly compiled ALSA drivers will be ignored.

Setting Module Options

You may need to set options in /etc/modprobe.d/sound.conf depending on your card. The general format is:

options snd-hda-intel OPTIONS

Please list your card and working module options below, along with the working device(s). Note that these options may change with future revisions and refinements to the drivers.


nVidia GPU Manufacturer/Model Options Best/working device (X=Card #)
G210 Point of View GF G210 enable_msi=0 probe_mask=0xffff,0xfff2 plughw:X,7 (only stereo confirmed)
G210 MSI N210 MD512H enable_msi=0 plughw:X,7 (only stereo confirmed)
G210 Asus EN210 no options needed with a current alsa snapshot plughw:X,7 (PCM, multichannel PCM, bitsteam (DD/DD-EX/DTS/DTS-ES)
G210 Club 3D CGNX-212LI enable_msi=0 probe_mask=0xfff2 plughw:X,7 (only stereo confirmed)
G210 Galaxy G210 PCI-E 512M enable_msi=0 probe_mask=0xfff2 hw:X,3 (6 channels)
G210 EVGA 512-P3-1213-LR probe_mask=2 plughw:X,3 (confirmed 2ch PCM, 6ch AC3 bitstream)
GT220 Asus BRAVO 220 SILENT/DI/1GD2(LP) no options needed with a current alsa snapshot plughw:X,7 (PCM, multichannel PCM, bitsteam (DD/DD-EX/DTS/DTS-ES)
GT220 Zontac ZT-20201-10L GT220 enable_msi=0 probe_mask=0xfff2 plughw:X,3 (6 channels)
GT220 ASUS ENGT220/DI/1GD2(LP) enable_msi=0 probe_mask=0xfff2 hw:X,3 (only stereo confirmed)
GT220 ASUS ENGT220/G/DI/1GD3(LP)/A enable_msi=0 probe_mask=0xfff2 hw:X,3 (PCM, multichannel PCM, bitstream (DD/DD-EX/DTS/DTS-ES)
GT220 HP Pavilion Elite HPE-141F enable_msi=0 probe_mask=0xffff,0xfff2 hw:X,3 (only stereo confirmed)
GT210/GT220/GT240 Any GT210/GT220/GT240 enable_msi=0 probe_mask=0xffff,0xfff2 plughw:X,3 (PCM, multichannel PCM, bitsteam (DD/DD-EX/DTS/DTS-ES))
GT240 MSI N240GT-MD1G enable_msi=0 probe_mask=0xffff,0xfff2 hw:X,3 (only stereo confirmed)
GT240 ASUS ENGT240/DI/512MD5/A enable_msi=0 plughw:X,7 (only stereo confirmed)
GT240 Zotac ZEGT240/DI/1024 enable_msi=0 probe_mask=0xfff2 plughw:X,3
ION-2 Asus AT5IONT-I enable_msi=0 probe_mask=0xffff,0xfff2 plughw:X,3
ION-2 Jetway Mini-Top enable_msi=0 plughw:X,7
ION-2 Asus S1-AT5NM10E no options needed with a current alsa snapshot hw:X,7 (6 channels)
  • I'm asserting that any GT210/GT220/GT240 should use plughw or plug to allow AC3 passthru. I'm not an alsa expert but the following link suggests plug should be used. However I found this info after getting it working with plughw and I'm loath to break a working system to test it (volunteers?). Alsa Recommened DeviceNames

Once you've set your module options, proceed to "PulseAudio Configuration" (if applicable) or "Finishing Configuration".

If that doesn't work...

if probe_mask doesn't work for you (it didn't for me, one boot my GT220 came up first instead of second, but next reboot it came up second without me touching the probe_mask parameter, you can try this (which works reliably for me):

options snd-hda-intel enable_msi=0 index=-2

or

options snd-hda-intel enable_msi=0 index=1

The first one tells snd-hda-intel "don't grab index 0", while the second one says "grab index 1" (so even if you disable your on-board card, your GT220 is still going to be hw:1,7)

I have to make a BIG NOTE that I don't have another Nvidia sound card on the motherboard, and that's why the above works for me. It won't work if you have an integrated nvidia sound AND a GT220.

For the case with Nvidia motherboard audio + GT210/GT220/GT240 HDMI don't be discouraged by the note above. I added the "enable_msi=0 probe_mask=0xffff,0xfff2" to /etc/modprobe.d/alsa-base.conf (Ubuntu 9.04) but I'm not 100% sure that's even necessary with 1.0.23. After that my HDMI audio showed up as plughw:2,3.

If multiple nVidia devices still show up with the recommended probe_mask, you may need to adjust it. More information about selecting the correct parameters for this option can be found in Takashi Iwai's documentation for the High-Definition Audio drivers.

XBMC Configuration

It may happen that even the PulseAudio configuration doesn't work. For example with the Point of View GeForce G210. In this case, simply set up the module options as described above, and then go into the XBMC Settings -> System -> Audio, select a custom device for audio and insert plughw:X,7. The audio should now work!

PulseAudio Configuration

If using PulseAudio, add the following line to /etc/pulse/default.pa:

load-module module-alsa-sink device=hw:1,3

Where 1,3 is card#,device# for the nVidia HDMI output given by aplay -l.

Finishing Installation

Now, reboot your system. Using `alsamixer', select your nVidia card (select it from the F6 menu, or use the -c option) and unmute the S/PDIF output (press "m"; the box should change from "MM" to "OO".) Enjoy!

If you have no sound, you should ensure that your user is a member of the "audio" group:

$ groups
adm dialout cdrom audio video plugdev mythtv lpadmin

Consult your distributions' documentation to determine how to add users to groups.

If you still have no sound, you can try editing/creating /etc/asound.conf:

pcm.!default hdmi:NVidia
pcm:iec958 hdmi:NVidia

Ensure that $HOME/.asoundrc is empty, does not exist, or does not override these settings. Reboot.