Archive:Remap HDMI audio on Gen 1 ION - Linux: Difference between revisions

From Official Kodi Wiki
Jump to navigation Jump to search
(+ categories)
>UNiversal
m (update and revitalize)
Line 1: Line 1:
HDMI audio output requires several steps to configure properly. My requirements were passthrough, non-passthrough and menu sounds all coming over HDMI to my receiver (fairly common). Some challenges were that the Gen 1 ION had incorrect channel mappings (e.g. Center came out of Left Rear) and menu sounds do not default to HDMI.  
HDMI audio output requires several steps to configure properly. My requirements were passthrough, non-passthrough and menu sounds all coming over HDMI to my receiver (fairly common). Some challenges were that the Gen 1 ION had incorrect channel mappings (e.g. Center came out of Left Rear) and menu sounds do not default to HDMI.  
MythBuntu 11.10
XBMC Eden Beta 2
Linux 3.0.0


== Remapping Surround Channels ==
== Remapping Surround Channels ==


I first noticed the audio channels were mismapped while watching a movie - all the voices were coming out of the left rear channel, not center. To verify this, I ran the following command:
I first noticed the audio channels were mis-mapped while watching a movie - all the voices were coming out of the left rear channel, not center. To verify this, I ran the following command:


  speaker-test -D hdmi -c 6
  speaker-test -D hdmi -c 6


To correct the output, I created the following channel mapping in ~/.asoundrc (.asoundrc is a file which will override the default alsa settings for a user.)
To correct the output, I created the following channel mapping in ~/.asoundrc or /etc/asound.conf(.asoundrc overrides the default alsa settings per user, while /etc/asound.conf is a global settings override)


pcm.hdmi-remap {
===For 7.1: Eden===
type route
<pre>
slave.pcm hdmi
pcm.hdmi-remap {
ttable.0.0 1
      type route
ttable.1.1 1
      slave.pcm hdmi
ttable.2.4 1
      ttable.0.0 1
ttable.3.5 1
      ttable.1.1 1
ttable.4.2 1
      ttable.2.4 1
ttable.5.3 1
      ttable.3.5 1
ttable.6.6 1  
      ttable.4.2 1
ttable.7.7 1  
      ttable.5.3 1
}
      ttable.6.6 1  
      ttable.7.7 1  
}
</pre>


Note: There is intentionally no ''slave.channels'' line in my .asoundrc file since it seems to corrupt the digital stream and prevented proper DTS and DD passthrough to my receiver. If you hear static when using passthrough, this might be the reason why!
:{{highlight|'''Note:'''|bordered=yes|color=#BEF781}} There is intentionally no ''slave.channels'' line in the configuration file since it seems to corrupt the digital stream and prevented proper DTS and DD passthrough to my receiver. If you hear static when using passthrough, this might be the reason why!


To test our new configuration, we can run:
To test our new configuration, we can run:
Line 34: Line 33:
Hopefully the channels will now be mapped correctly.  
Hopefully the channels will now be mapped correctly.  


== Menu Sounds ==
===For 5.1: Frodo===
<pre>
pcm.!default {
    type plug
    slave {
        pcm both
    }
}
 
pcm.both {
    type route
    slave {
        pcm hdmi
    }
      ttable.0.0 1
      ttable.1.1 1
      ttable.2.4 1
      ttable.3.5 1
      ttable.4.2 1
      ttable.5.3 1
}
</pre>
 
=== Menu Sounds ===
 
:{{highlight|'''Note:'''|bordered=yes|color=#BEF781}} Not needed in Frodo.


To configure menu sounds, I told alsa to use the hdmi-remap device as default. I did this by adding the following section to my ~/.asoundrc file:
To configure menu sounds, I told alsa to use the hdmi-remap device as default. I did this by adding the following section to my ~/.asoundrc file:
Line 47: Line 71:
Within Settings -> System -> Audio Output, I set the following values:
Within Settings -> System -> Audio Output, I set the following values:


* Audio Output : HDMI
==='''Eden'''===
* Speaker Configuration : 7.1
 
* Boost volume level on downmix : No
* Audio Output : '''HDMI'''
* Dolby Digitla (AC3) capable receiver : Yes
* Speaker Configuration : '''7.1'''
* DTS capable receiver : Yes
* Boost volume level on downmix : '''No'''
* Audio output device : Custom
* Dolby Digitla (AC3) capable receiver : '''Yes'''
* Custom audio device : hdmi-remap
* DTS capable receiver : '''Yes'''
* Passthrough output device : hdmi(ALSA)
* Audio output device : '''Custom'''
* Custom audio device : '''hdmi-remap'''
* Passthrough output device : '''hdmi(ALSA)'''
 
==='''Frodo'''===
* Audio Output : '''HDMI'''
* Speaker Configuration : '''5.1'''
* Boost volume level on downmix : '''No'''
* Dolby Digitla (AC3) capable receiver : '''Yes'''
* DTS capable receiver : '''Yes'''
* Audio output device : '''HDA NVidia HDMI 0'''
* Passthrough output device : '''HDA NVidia HDMI 0'''
 
After a reboot, sound should be working as expected. Feel free to update this information as needed.


After a reboot, sound was working as expected. Please let me know if you have a similar experience!
{{forum link2|[[forum:147733|'''Linux''' Frodo HDMI audio channel remap discussion]]}}


[[Category:How-to]]
[[Category:How-to]]
[[Category:Linux]]
[[Category:Linux]]

Revision as of 12:11, 18 December 2012

HDMI audio output requires several steps to configure properly. My requirements were passthrough, non-passthrough and menu sounds all coming over HDMI to my receiver (fairly common). Some challenges were that the Gen 1 ION had incorrect channel mappings (e.g. Center came out of Left Rear) and menu sounds do not default to HDMI.

Remapping Surround Channels

I first noticed the audio channels were mis-mapped while watching a movie - all the voices were coming out of the left rear channel, not center. To verify this, I ran the following command:

speaker-test -D hdmi -c 6

To correct the output, I created the following channel mapping in ~/.asoundrc or /etc/asound.conf(.asoundrc overrides the default alsa settings per user, while /etc/asound.conf is a global settings override)

For 7.1: Eden

pcm.hdmi-remap {
       type route
       slave.pcm hdmi
       ttable.0.0 1
       ttable.1.1 1
       ttable.2.4 1
       ttable.3.5 1
       ttable.4.2 1
       ttable.5.3 1
       ttable.6.6 1 
       ttable.7.7 1 
}
Note: There is intentionally no slave.channels line in the configuration file since it seems to corrupt the digital stream and prevented proper DTS and DD passthrough to my receiver. If you hear static when using passthrough, this might be the reason why!

To test our new configuration, we can run:

speaker-test -D hdmi-remap -c 6

Hopefully the channels will now be mapped correctly.

For 5.1: Frodo

pcm.!default {
    type plug
    slave {
        pcm both
    }
}

pcm.both {
    type route
    slave {
        pcm hdmi
    }
       ttable.0.0 1
       ttable.1.1 1
       ttable.2.4 1
       ttable.3.5 1
       ttable.4.2 1
       ttable.5.3 1
}

Menu Sounds

Note: Not needed in Frodo.

To configure menu sounds, I told alsa to use the hdmi-remap device as default. I did this by adding the following section to my ~/.asoundrc file:

pcm.!default {
	type plug
	slave.pcm hdmi-remap
}

XBMC Configuration

Within Settings -> System -> Audio Output, I set the following values:

Eden

  • Audio Output : HDMI
  • Speaker Configuration : 7.1
  • Boost volume level on downmix : No
  • Dolby Digitla (AC3) capable receiver : Yes
  • DTS capable receiver : Yes
  • Audio output device : Custom
  • Custom audio device : hdmi-remap
  • Passthrough output device : hdmi(ALSA)

Frodo

  • Audio Output : HDMI
  • Speaker Configuration : 5.1
  • Boost volume level on downmix : No
  • Dolby Digitla (AC3) capable receiver : Yes
  • DTS capable receiver : Yes
  • Audio output device : HDA NVidia HDMI 0
  • Passthrough output device : HDA NVidia HDMI 0

After a reboot, sound should be working as expected. Feel free to update this information as needed.

Attention talk.png Linux Frodo HDMI audio channel remap discussion