Change PCM format for HDMI output

  • Hello!

    Background of my issue: I have a somewhat old TV which only supports 16 Bit and 20 Bit PCM audi input.

    Unfortunately something is going wrong somewhere and I do not get any audio from my TV in stock configuration. I assume there is a problem with the 20 Bit PCM format for my TV. By default, audio is passed to ALSA in 32 Bit format.

    After some tries, i figured out that audio is playing fine from TV if passed as 16 Bit PCM format.

    Now I am searching for any solution to convert the audi coming from Kodi to 16 Bit PCM format before passed to TV over HDMI. (Any solution welcome)

    My approach was to convert die audio stream in the ALSA layer by a plug, so i configured ~/.config/asound.conf as follows (based on the description from

    This works as expected at the ALSA layer and now a can play e.g. 24 Bit audio passed to ALSA default device by aplay and hear the sound from my TV.

    But in Kodi, the default ALSA device is not updated (still shows analog output and no audio on TV) and the HDMI selection as audio output still uses the 32 Bit format for ALSA. Also, my complex_convert alias (from asound.conf) is not showing as ALSA sink in the Kodi audi selection list.

    Is it possible to use the complex_convert ALSA alias as audio sink for Kodi?

    Other approach: Kodi selects audio sample format as AE_FMT_S32NE, is there a way to force it to AE_FMT_S16LE?

    Kodi debug log

    Any ideas how I can solve my issue?

  • Yes, but this only changes the sampling rate, not the format. No audio from TV with "fixed" output configuration with either 44.1 or 48 kHz.

    Edited once, last by Bromor ().

  • As solution I added pulseaudio in between and now audio is playing fine from TV.

    Added to ~/.config/

    pactl load-module module-alsa-sink device="default"