Nofan Tasi thanks, I think I know now what's going wrong.
Could you please stop kodi and then run aplay -L and post the output?
With kodi stopped also please confirm if this works fine:
so long,
Hias
Nofan Tasi thanks, I think I know now what's going wrong.
Could you please stop kodi and then run aplay -L and post the output?
With kodi stopped also please confirm if this works fine:
so long,
Hias
Nofan Tasi thanks, I think I know now what's going wrong.
Could you please stop kodi and then run aplay -L and post the output?
With kodi stopped also please confirm if this works fine:
so long,
Hias
Good news!
After stopping kodi I can load the pulseaudio module.
And, when starting kodi again, audio does works in flatpak Chromium.
In fact: if I put line
in .config/autostart.sh then all is fine.
Moreover if I then enable Librespot, Librespot works as well ... however:
If I then run Chromium, youtube cannot play (I suppose an audio issue) and suggests to restart device.
In short:
The line in autostart.sh is a valid workaround BUT switching between flatpak Chromium and Librespot does not continue well.
I think I can live with this situation. I start LibreELEC with Librespot disabled and I can run Chromium with audio. And : when I need Librespot I enable it and restart LibreELEC (or maybe stop and start Kodi) and do not run Chromium.
Thanks for all your help and suggestions. Have a nice day!
Also: I will be more than happy to test possible fixes.
fwiw: I actually should not need a browser but from time to time an add-on (e.g. Netflix and VRT-Nu) does not work good and then having a fallback to play in a browser on a sufficiently powerful machine is a nice luxury.
here is requested output
LibreELEC:~ # systemctl stop kodi.service
LibreELEC:~ # aplay -L
null
Discard all samples (playback) or generate zero samples (capture)
hdmi:CARD=HDMI,DEV=0
HDA Intel HDMI, iMac
HDMI Audio Output
hdmi:CARD=HDMI,DEV=1
HDA Intel HDMI, HDMI 1
HDMI Audio Output
hdmi:CARD=HDMI,DEV=2
HDA Intel HDMI, HDMI 2
HDMI Audio Output
default:CARD=PCH
HDA Intel PCH, CS4206 Analog
Default Audio Device
sysdefault:CARD=PCH
HDA Intel PCH, CS4206 Analog
Default Audio Device
front:CARD=PCH,DEV=0
HDA Intel PCH, CS4206 Analog
Front output / input
surround21:CARD=PCH,DEV=0
HDA Intel PCH, CS4206 Analog
2.1 Surround output to Front and Subwoofer speakers
surround40:CARD=PCH,DEV=0
HDA Intel PCH, CS4206 Analog
4.0 Surround output to Front and Rear speakers
surround41:CARD=PCH,DEV=0
HDA Intel PCH, CS4206 Analog
4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=PCH,DEV=0
HDA Intel PCH, CS4206 Analog
5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=PCH,DEV=0
HDA Intel PCH, CS4206 Analog
5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=PCH,DEV=0
HDA Intel PCH, CS4206 Analog
7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
iec958:CARD=PCH,DEV=0
HDA Intel PCH, CS4206 Digital
IEC958 (S/PDIF) Digital Audio Output
LibreELEC:~ # pactl load-module module-alsa-sink device=sysdefault:CARD=PCH
14
LibreELEC:~ # pactl list sinks
Sink #1
State: IDLE
Name: alsa_output.sysdefault_CARD_PCH
Description: Built-in Audio
Driver: module-alsa-sink.c
Sample Specification: s32le 2ch 48000Hz
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.sysdefault_CARD_PCH.monitor
Latency: 337429 usec, configured 341333 usec
Flags: HARDWARE DECIBEL_VOLUME LATENCY
Properties:
alsa.resolution_bits = "32"
device.api = "alsa"
device.class = "sound"
alsa.class = "generic"
alsa.subclass = "generic-mix"
alsa.name = "CS4206 Analog"
alsa.id = "CS4206 Analog"
alsa.subdevice = "0"
alsa.subdevice_name = "subdevice #0"
alsa.device = "0"
alsa.card = "1"
alsa.card_name = "HDA Intel PCH"
alsa.long_card_name = "HDA Intel PCH at 0x98814000 irq 41"
alsa.driver_name = "snd_hda_intel"
device.bus_path = "pci-0000:00:1b.0"
sysfs.path = "/devices/pci0000:00/0000:00:1b.0/sound/card1"
device.bus = "pci"
device.vendor.id = "8086"
device.vendor.name = "Intel Corporation"
device.product.id = "8c20"
device.product.name = "8 Series/C220 Series Chipset High Definition Audio Controller"
device.form_factor = "internal"
device.string = "sysdefault:CARD=PCH"
device.buffering.buffer_size = "131072"
device.buffering.fragment_size = "8192"
device.access_mode = "mmap+timer"
device.description = "Built-in Audio"
device.icon_name = "audio-card-pci"
Formats:
pcm
LibreELEC:~ # systemctl start kodi.service
LibreELEC:~ # pactl list sinks
Sink #1
State: SUSPENDED
Name: alsa_output.sysdefault_CARD_PCH
Description: Built-in Audio
Driver: module-alsa-sink.c
Sample Specification: s32le 2ch 48000Hz
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.sysdefault_CARD_PCH.monitor
Latency: 0 usec, configured 0 usec
Flags: HARDWARE DECIBEL_VOLUME LATENCY
Properties:
alsa.resolution_bits = "32"
device.api = "alsa"
device.class = "sound"
alsa.class = "generic"
alsa.subclass = "generic-mix"
alsa.name = "CS4206 Analog"
alsa.id = "CS4206 Analog"
alsa.subdevice = "0"
alsa.subdevice_name = "subdevice #0"
alsa.device = "0"
alsa.card = "1"
alsa.card_name = "HDA Intel PCH"
alsa.long_card_name = "HDA Intel PCH at 0x98814000 irq 41"
alsa.driver_name = "snd_hda_intel"
device.bus_path = "pci-0000:00:1b.0"
sysfs.path = "/devices/pci0000:00/0000:00:1b.0/sound/card1"
device.bus = "pci"
device.vendor.id = "8086"
device.vendor.name = "Intel Corporation"
device.product.id = "8c20"
device.product.name = "8 Series/C220 Series Chipset High Definition Audio Controller"
device.form_factor = "internal"
device.string = "sysdefault:CARD=PCH"
device.buffering.buffer_size = "131072"
device.buffering.fragment_size = "8192"
device.access_mode = "mmap+timer"
device.description = "Built-in Audio"
device.icon_name = "audio-card-pci"
Formats:
pcm
Display More
Thanks again for the logs and tests!
There's a bug in the current audio device selection code, it misses the :CARD=PCH which is important in your case.
I'll have a look at fixing that and report back when I have an updated addon to test.
so long,
Hias
Nofan Tasi can you please test with the attached tools.externalhelper addon?
I've fixed audio device handling and also added a setting to manually specify the audio device (the latter shouldn't be needed in your case).
Please drop the pactl load-module workaround from your autostart when testing that.
It'd also be interesting to know if this works with librespot installed.
so long,
Hias
Thanks for the kind and excellent support! You are a hero ![]()
Your addon fixes the 'flatpak Chromium' no-audio issue.
Moreover: I can switch beween 'flatpak Chromium' and 'Librespot service' multiple times and both continue to work just fine.
Your addon 'Settings' has a 'Run' button but with current default values all works fine without any manual intervention.
Just curious: What is the 'Confirm start' setting? Maybe it controls if (yes/no) the addon is active right after LibreELEC (or Kodi?) startup?
One observation: the Volume Up and Volume Down buttons on my remote do not seem to have any effect when running Chromium.
Is or was (or will) this addon (be) in Team LibreELEC repository?
Thanks a lot for reporting back, glad to hear it works now!
I'll PR the fixes so the should be in our addon repo in the next few days.
With the "confirm start" option you can disable the "Start Chromium" etc dialogs that pop up before starting the flatpak addons.
Concerning volume control: that's usually handled by special (background) services of desktop environments, but LE doesn't include a full desktop environment so the buttons on your keyboard/remote won't have any effect.
so long,
Hias
...that's usually handled by special (background) services of desktop environments, but LE doesn't include a full desktop environment so the buttons on your keyboard/remote won't have any effect.
Ah - that kinda-sorta has a bearing on a question I had.
Ideally I'd like to use the same IR-remote I use in main LibreELEC/Kodi via lirc & keymaps, but haven't had a chance yet to poke around seriously.
VaccuumTube's in-app settings dialogue says it uses up/down arrows to navigate, but it doesn't seem to recognise them on the bluetooth keyboard or IR-remote I'm using.
I was going to ask how keyboard/mouse/remote handling & configuration worked in the Flatpak environment, but if there isn't any plumbing for it, because of lack of a "proper" desktop environment ... ??
Keyboard handling is actually quite simple, both kodi and wayland use libinput plus libxkb for that so we just need to pass the keyboard layout that's configured in kodi on to wayland (via an environment variable) and you get the same keyboard layout in flatpak addons as in kodi.
What's missing in the wayland environment though is software to listen on volume keys and adjust audio volume. Usually that's handled by the (pulseaudio) volume/mixer applets in desktop environments, but there's no such thing (yet) in LE.
Kodi handles the volume keys on it's own which is why it works in kodi.
Remotes are quite a mess though. Currently we need to run remotes through eventlircd (and explicitly configure libinput not to handle them, too) as libxkb and kodi still doesn't support quite a lot of buttons found on remotes (especially the quite important "OK" button).
There's a kodi PR to improve that https://github.com/xbmc/xbmc/pull/27932 but it hasn't been merged and also still doesn't support all common remote buttons.
Realistically we won't get proper remote button support before the kodi 22 / LE13 release so we won't be able to drop that eventlircd workaround until some time during the LE14 dev cycle.
Well, someone could write a separate program that translates LIRC events back to input events and injects those via uinput but that's quite meh (and would also be another - hopefully - short lived workaround).
so long,
Hias
Well, as luck would have it, the volume thing is not an issue for me as I let the AV-receiver box handle that aspect of things ![]()
As far as the remote goes, I may also be in luck. I'm using the Logitech Harmony system (fingers crossed it stays alive) and I have the facility to have the remote send any arbitrary key-command(s) for a given button.
Thanks for the pointers of what to look at - I'll report back when I've had a chance to poke around in more detail.
If you want to play around with the remote:
Simply "systemctl mask eventlircd" and disable the eventlircd udev rule by creating an empty .config/udev.rules.d/98-eventlircd.rules file - then reboot.
If you configure the "OK" button to send "enter" (via ir-keytable) the up/down/left/right buttons will work like cursor keys and "OK" like the enter key on a keyboard.
so long,
Hias
Thanks a lot for reporting back, glad to hear it works now!
I am glad I was of some help.
I believe I noticed addon fix got committed 18 May so now I installed 19 May LE nightly.
In 'my addons' I notice Team LibreELEC version is 12.80.7.0 which is same version as the one you gave.
So I am not sure if fix is in official addons repository.
Now shall I install current official Team LibreELEC 12.80.7.0 (and test again) or wait for a higher next version?
Have a nice day!
Now shall I install current official Team LibreELEC 12.80.7.0 or (and test again) or wait for a higher next version?
No, wait for the next version, it'll be 12.80.7.1 and Kodi should auto-update to it when it hits our repo.
It usually takes a day or two from PR merge until addons are uploaded to our repos.
so long,
Hias
No, wait for the next version, it'll be 12.80.7.1 and Kodi should auto-update to it when it hits our repo.
12.80.7.1 works fine and has solved the defect. congrats