No more Audio after some time

Hello,

i hope you Guys can help my, i tried so many things and Settings now, i don’t know what to do anymore. First my Problem: i installed OSMC on a Raspberry Pi 4 and running it trough a (brand new) 7.5m HDMI Cable to my Yamaha AV RX-V379 Receiver. As TV i use a Sony Bravia KDX8008C UHD. The Firmware on all Devices are updated, i use the newest Version of OSMC. Everything is just working fine, i can play Movies, watch IP TV, can watch Music Videos etc etc. But after some time, the whole Audio drops out. It seems to be complete randomly. Sometime it happens after i stop a running Video, sometimes when i leave the Main Menue for a few Minutes and do nothing. But when i then click through the Items, i hear no more Sound. When i start a Movie, no more Sound. For the first 10 Seconds the Video freezes, then continue but whith no Sound. There is no way i can change, to get the Sound back. The only Solution is to restart the whole Raspberry. Then everything is workin fine again till the next dropout.

I tried Libreelec on another SD Card and there i have no Problems, everything seems to work fine. But i want to stick with OSMC, because i run a Home Assistant Supervisor Installation on the same Device. I used this Combination for about 1 1/2 Years, everything worked fine, no Audio dropouts untill my SSD died on the Pi running the OSMC/Home Assistant. I wasn’t able to recover the HDD Data, so i installed a new SSD and reinstalled a fresh Version of OSMC/Home Assistant. But since then i have this Problems.

I tried to change all Settings, change the Channels from 5.1 to 2.0, changed the Output Device, changed the Keep alive Signal from 1 Minute to Infinite and back… enabled and disabled the Passthrough. Nothing helps.

So i hope someone can help me figure out the Problem here.

Here are my uploaded Log Files: https://paste.osmc.tv/motupohabo.xml

I think the Point where it happes is right at the End of the log:

2022-12-19 14:24:21.713 T:848 INFO : CActiveAESink::OpenSink - initialize sink
2022-12-19 14:24:21.713 T:848 DEBUG : CActiveAESink::OpenSink - trying to open device ALSA:sysdefault:CARD=vc4hdmi0
2022-12-19 14:24:21.714 T:848 INFO : CAESinkALSA::Initialize - Attempting to open device “sysdefault:CARD=vc4hdmi0”
2022-12-19 14:24:21.720 T:848 INFO : CAESinkALSA - ALSA: pcm_hw.c:1715:(snd_pcm_hw_open) open ‘/dev/snd/pcmC0D0p’ failed (-16): Device or resource busy
2022-12-19 14:24:21.720 T:848 INFO : CAESinkALSA - Unable to open device “sysdefault:CARD=vc4hdmi0” for playback
2022-12-19 14:24:21.720 T:848 ERROR : CAESinkALSA::Initialize - failed to initialize device “sysdefault:CARD=vc4hdmi0”
2022-12-19 14:24:21.721 T:848 DEBUG : CActiveAESink::OpenSink - trying to open device ALSA:default
2022-12-19 14:24:21.721 T:848 INFO : CAESinkALSA::Initialize - Attempting to open device “default”
2022-12-19 14:24:21.726 T:848 INFO : CAESinkALSA - ALSA: pcm_hw.c:1715:(snd_pcm_hw_open) open ‘/dev/snd/pcmC0D0p’ failed (-16): Device or resource busy
2022-12-19 14:24:21.726 T:848 INFO : CAESinkALSA - Unable to open device “default” for playback
2022-12-19 14:24:21.726 T:848 ERROR : CAESinkALSA::Initialize - failed to initialize device “default”
2022-12-19 14:24:21.727 T:848 ERROR : CActiveAESink::OpenSink - no sink was returned

This Error-Message repeats and repeats and spam the Log File. But what is causing this??

Thank you very much for any Help!
Greetings from Germany

Which version of LibreELEC did you use?

Thanks

Sam

i used the newest Version, did a fresh Install.

I did now the very long way and tried to figure out, which component is causing this Problem here… Because after some reinstalls of OSMC, on a fresh System without any changes, there is everything fine. I installed now Raspberry Pi OS and installed Kodi via the apt-get method. It is also the v19.4, so i thought that would be okay but after installing Home Assistant and Samba Client etc. i had the same issue again! So as i said, i did the long way. I installed everything again, installed everything fresh and did no Backup Restore for Home Assistant, i did a new Config from scratch. And so far i installed everything again but now it is working, so more dropouts so far. The only thing i not installed is SMB Client. I do now everything via SHH/Home Assistant WebUI. Long story short, it is working, i think it is not OSMC’s fault, but i don’t know what the Problem was.

I think something waited to use the Sound Interface, when Kodi is no more using it and does not release it again. I’am no Linux Expert, so i don’t know if this makes sense but i think for some Reason Docker or Home Assistant used the Sound Interface. I tried many Commands like “lsof | grep dev/snd” and “fuser /dev/snd/pcmC0D0c” … but nothing showed that something on the System use the Sound Interface.

Maybe have someone an idea what this caused.

Greetings

Do you have any attached peripherals to the device?
Are you doing a true fresh install or restoring your Kodi settings each time?

Yes, there is a Wemos D1 Attached but only to power it via USB. It is just a Tempsensor connected via ESPEasy. So it should not affect this Problem i think. Another thing is a connected Switch via GPIO Pins for a Doorbell. I use it as a simple Input Button for Home Assistant, which triggers a Doorbell Sound via Google Home Speaker. I thought this is maybe the Problem, but i removed the GPIO Integration from Home Assistant and removed the Plugs from the GPIO Pins. But it did not help. Another Attached Device is the SSD Disk via USB3 to Sata Adapter. So OSMC runned as USB Device from a SSD.

But as i said, i installed everything again, no Backup Restores, everything fresh. Installed first Kodi, then Simple IPTV Client and then Docker, Home Assistant, MQTT Mosquitto Broker and nothing more. I added all Devices in Home Assistant again and did everything from scratch. And now it works. Even the Doorbell and GPIO Integration works again, so this can’t be the Problem.

So it must be anything in the Home Assistant Backup or the SMB Client, because this two Things i did not install again and now it works. But i think SMB also do not use the Sound Interface or has something to do with it. So there is only Home Assistant left, but i have no plan, what can cause this… Because Home Assistant don’t uses the local Soundinterface. You can add Bluetooth Devices and Google Home Speaket etc. for Media Play but i can not define a local Sound Interface, as far as i know. I did not find anything about this…

I think Home Assistant may be your issue.

Sam