[PULSEAUDIO] No passthrough capabilities with AML-M8AUDIO

Hi,

Since the migration to CoreElec ( from LibreElec Kszaq build ) I try to make working my pulseaudio conf.

Before I have pulseaudio activate for general sound and for passthrough stream I use directly ALSA.
Now I can’t see the ALSA output when I activate pulseaudio and I can’t configure it to make it work with passthrough.

However I proceed correclty I think :

Allow all format =>
pactl set-sink-formats 1 “pcm; ac3-iec61937; dts-iec61937; eac3-iec61937”

Show conf :

pactl list sinks
Sink #1
State: SUSPENDED
Name: alsa_output.0.hdmi-stereo
Description: Built-in Audio Digital Stereo (HDMI)
Driver: module-alsa-card.c
Sample Specification: s16le 2ch 44100Hz
Channel Map: front-left,front-right
Owner Module: 14
Mute: no
Volume: front-left: 65536 / 100% / 0.00 dB, front-right: 65536 / 100% / 0.00 dB
balance 0.00
Base Volume: 65536 / 100% / 0.00 dB
Monitor Source: alsa_output.0.hdmi-stereo.monitor
Latency: 0 usec, configured 0 usec
Flags: HARDWARE DECIBEL_VOLUME LATENCY SET_FORMATS
Properties:
alsa.resolution_bits = “16”
device.api = “alsa”
device.class = “sound”
alsa.class = “generic”
alsa.subclass = “generic-mix”
alsa.name = “”
alsa.id = “SPDIF.41 dit-hifi-1”
alsa.subdevice = “0”
alsa.subdevice_name = “subdevice #0
alsa.device = “1”
alsa.card = “0”
alsa.card_name = “AML-M8AUDIO”
alsa.long_card_name = “AML-M8AUDIO”
device.bus_path = “/devices/aml_m8_snd.47/sound/card0”
sysfs.path = “/devices/aml_m8_snd.47/sound/card0”
device.form_factor = “internal”
device.string = “hdmi:0”
device.buffering.buffer_size = “16384”
device.buffering.fragment_size = “4096”
device.access_mode = “serial”
device.profile.name = “hdmi-stereo”
device.profile.description = “Digital Stereo (HDMI)”
device.description = “Built-in Audio Digital Stereo (HDMI)”
module-udev-detect.discovered = “1”
device.icon_name = “audio-card”
Ports:
hdmi-output-0: HDMI / DisplayPort (priority: 5900)
Active Port: hdmi-output-0
Formats:
ac3-iec61937, format.rate = “[ 32000, 44100, 48000, 88200, 96000, 176400, 192000 ]”
dts-iec61937, format.rate = “[ 32000, 44100, 48000, 88200, 96000, 176400, 192000 ]”
eac3-iec61937, format.rate = “[ 32000, 44100, 48000, 88200, 96000, 176400, 192000 ]”
pcm

restart kodi, still no passthrough capabilities …

12:17:32.659 T:4065559408 NOTICE: Found 1 Lists of Devices
12:17:32.659 T:4065559408 NOTICE: Enumerated PULSE devices:
12:17:32.659 T:4065559408 NOTICE: Device 1
12:17:32.660 T:4065559408 NOTICE: m_deviceName : Default
12:17:32.660 T:4065559408 NOTICE: m_displayName : Default
12:17:32.660 T:4065559408 NOTICE: m_displayNameExtra: Bluetooth Audio (PULSEAUDIO)
12:17:32.660 T:4065559408 NOTICE: m_deviceType : AE_DEVTYPE_PCM
12:17:32.660 T:4065559408 NOTICE: m_channels : FL, FR
12:17:32.660 T:4065559408 NOTICE: m_sampleRates : 5512,8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,176400,192000,384000
12:17:32.660 T:4065559408 NOTICE: m_dataFormats : AE_FMT_U8,AE_FMT_S16NE,AE_FMT_S24NE3,AE_FMT_S24NE4,AE_FMT_S32NE,AE_FMT_FLOAT
12:17:32.660 T:4065559408 NOTICE: m_streamTypes : No passthrough capabilities
12:17:32.667 T:4057166704 NOTICE: PulseAudio: Opened device Default in pcm mode with Buffersize 192 ms

As I said before, on Libreelec it work, so it’s not a hardware issue.

Thank’s for the help.

What is wrong with the default configuration?

The default conf with pulseaudio enable don’t allow me to use passthrough for dts ac3 etc…, just pcm sound work

With Pulseaudio :

21:32:42.524 T:4068705136 NOTICE: Found 1 Lists of Devices
21:32:42.524 T:4068705136 NOTICE: Enumerated PULSE devices:
21:32:42.524 T:4068705136 NOTICE: Device 1
21:32:42.524 T:4068705136 NOTICE: m_deviceName : Default
21:32:42.524 T:4068705136 NOTICE: m_displayName : Default
21:32:42.524 T:4068705136 NOTICE: m_displayNameExtra: Bluetooth Audio (PULSEAUDIO)
21:32:42.524 T:4068705136 NOTICE: m_deviceType : AE_DEVTYPE_PCM
21:32:42.525 T:4068705136 NOTICE: m_channels : FL, FR
21:32:42.525 T:4068705136 NOTICE: m_sampleRates : 5512,8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,176400,192000,384000
21:32:42.525 T:4068705136 NOTICE: m_dataFormats : AE_FMT_U8,AE_FMT_S16NE,AE_FMT_S24NE3,AE_FMT_S24NE4,AE_FMT_S32NE,AE_FMT_FLOAT
21:32:42.525 T:4068705136 NOTICE: m_streamTypes : No passthrough capabilities
21:32:42.576 T:4093746384 ERROR: GetString: error reading /storage/.kodi/userdata/disp_cap

If I stop pulseaudio, ALSA is present and work ( for sound and passthrough stream ) but I need to use pulseaudio for a custom solution ( network stream etc… )

Without Pulseaudio :

21:28:06.765 T:4059267952 NOTICE: Enumerated ALSA devices:
21:28:06.765 T:4059267952 NOTICE: Device 1
21:28:06.765 T:4059267952 NOTICE: m_deviceName : hdmi:CARD=AMLM8AUDIO,DEV=0
21:28:06.765 T:4059267952 NOTICE: m_displayName : AML-M8AUDIO
21:28:06.765 T:4059267952 NOTICE: m_displayNameExtra: HDMI
21:28:06.765 T:4059267952 NOTICE: m_deviceType : AE_DEVTYPE_HDMI
21:28:06.765 T:4059267952 NOTICE: m_channels : FL, FR, BL, BR, FC, LFE, SL, SR
21:28:06.765 T:4059267952 NOTICE: m_sampleRates : 32000,44100,48000,88200,96000,176400,192000
21:28:06.765 T:4059267952 NOTICE: m_dataFormats : AE_FMT_S16NE,AE_FMT_S16LE,AE_FMT_RAW
21:28:06.765 T:4059267952 NOTICE: m_streamTypes : STREAM_TYPE_AC3,STREAM_TYPE_DTSHD,STREAM_TYPE_DTSHD_CORE,STREAM_TYPE_DTS_1024,STREAM_TYPE_DTS_2048,STREAM_TYPE_DTS_512,STREAM_TYP
21:28:06.813 T:4094852304 ERROR: GetString: error reading /storage/.kodi/userdata/disp_cap

Problem is your Kodi settings not Pulseaudio, you have likely broken it messing around with it, pass-through works just fine otherwise we would have a lot more posts on the issue.

I just reset my kodi conf ( mv ~/.kodi ~/.kodi-backup ) and I have exactly the same behaviour with pulseaudio.
The sound work but no passthrough …

@anon88919003 you said " we would have a lot more posts on the issue " => Because by default the pulseaudio conf delivery on CoreElec don’t load the ALSA driver ( only bluetooth ) and i this case it work, passthrout use directly ALSA and it work But in my case I want to use pulseaudio completly and detect the AML card ( load-module module-udev-detect ) and that’s the issue.

I just build CoreElec without the patch “kodi-100.15-rename-default-pulse-device.patch” and no it work like a charm. The pulseaudio sink with passthrough appear :

Enumerated PULSE devices:
23:26:21.186 T:4066571120 NOTICE: Device 1
23:26:21.186 T:4066571120 NOTICE: m_deviceName : Default
23:26:21.186 T:4066571120 NOTICE: m_displayName : Default
23:26:21.186 T:4066571120 NOTICE: m_displayNameExtra: Default Output Device (PULSEAUDIO)
23:26:21.186 T:4066571120 NOTICE: m_deviceType : AE_DEVTYPE_PCM
23:26:21.186 T:4066571120 NOTICE: m_channels : FL, FR
23:26:21.186 T:4066571120 NOTICE: m_sampleRates : 5512,8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,176400,192000,384000
23:26:21.186 T:4066571120 NOTICE: m_dataFormats : AE_FMT_U8,AE_FMT_S16NE,AE_FMT_S24NE3,AE_FMT_S24NE4,AE_FMT_S32NE,AE_FMT_FLOAT
23:26:21.186 T:4066571120 NOTICE: m_streamTypes : No passthrough capabilities
23:26:21.186 T:4066571120 NOTICE: Device 2
23:26:21.186 T:4066571120 NOTICE: m_deviceName : alsa_output.0.hdmi-stereo
23:26:21.186 T:4066571120 NOTICE: m_displayName : Built-in Audio Digital Stereo (HDMI)
23:26:21.186 T:4066571120 NOTICE: m_displayNameExtra: HDMI / DisplayPort (PULSEAUDIO)
23:26:21.186 T:4066571120 NOTICE: m_deviceType : AE_DEVTYPE_IEC958
23:26:21.186 T:4066571120 NOTICE: m_channels : FL, FR
23:26:21.186 T:4066571120 NOTICE: m_sampleRates : 5512,8000,11025,16000,22050,32000,44100,48000,64000,88200,96000,176400,192000,384000
23:26:21.186 T:4066571120 NOTICE: m_dataFormats : AE_FMT_U8,AE_FMT_S16NE,AE_FMT_S24NE3,AE_FMT_S24NE4,AE_FMT_S32NE,AE_FMT_FLOAT,AE_FMT_RAW
23:26:21.186 T:4066571120 NOTICE: m_streamTypes : STREAM_TYPE_AC3,STREAM_TYPE_DTSHD_CORE,STREAM_TYPE_DTS_1024,STREAM_TYPE_DTS_512,STREAM_TY

Hello @max3163 Actually your configuration interests me as I’m trying to use Pulseaudio as well, but I can’t find the way to make kodi list the pulse cards.
Moreover, I’m also trying to connect to local tcp pulse server (pactl list sinks confirms that it works after I’ve changed default server in client.conf and reboot/restart pulse service) but when I list the audio devices in kodi they don’t appear (what’s strange is that they appeared once for a little while but then I never figured out how to reproduce it)

Thanks for your help

Ok I found out why, I just need to restart Kodi once after the device has completely started, I don’t know yet why (timing or dependencies somewhere)

About | FAQ | Terms of Service | Privacy Policy | Legal Notice