Moode Forum
[PROBLEM] How to keep HDMI audio stream alive? - Printable Version

+- Moode Forum (https://moodeaudio.org/forum)
+-- Forum: moOde audio player (https://moodeaudio.org/forum/forumdisplay.php?fid=3)
+--- Forum: Support (https://moodeaudio.org/forum/forumdisplay.php?fid=7)
+--- Thread: [PROBLEM] How to keep HDMI audio stream alive? (/showthread.php?tid=6106)

Pages: 1 2


How to keep HDMI audio stream alive? - oomzay - 01-05-2024

At the moment the HDMI stream stops whenever no tracks are playing. This causes my AV receiver to go into "no signal mode" which causes some clunky protection relay to switch off and a delay before next track is heard.

Is there some way to pad gaps with silence to keep the HDMI stream alive?

I could imagine an ALSA or Camilla module that injects silence when it has no input. Is there such a thing?

(I am hoping to fix the CamillaDSP and HDMI output format at 88.2kHz/24bit - so format switching shouldn't ever occur)


RE: How to keep HDMI audio stream alive? - Tim Curtis - 01-05-2024

MPD doesn't support keeping the audio channel open (or playing "silence") when nothing is playing.

My only experience with "Pure Direct" mode is on my Yamaha AVR. It turns off some parts of the AVR like the display screen, HDMI video etc but there are no issues whatsoever with audio in this mode. moOde plays glitch free.

Maybe there are some settings on the Onkyo that control the odd HDMI "no signal" behavior.

You can set resampling in MPD or if you want MPD plus Airplay, Spotify Connect and Bluetooth to be resampled then it can be set in CamillaDSP.


RE: How to keep HDMI audio stream alive? - oomzay - 01-05-2024

This problem occurs in any receiver mode (though only the pure/direct are of interest to me). Others have reported this problem/wish elsewhere (I cant remember where). I can find no setting for HDMI "no signal" behaviour - and I am not sure the receiver could meaningfully second-guess what is going to come next when the signal drops.

I think the solution would be below the MPD level. Like a plugin (term used loosely) in the ALSA framework that is always connected to the hdmi. For example something like plughw, but that keeps the output device fed/open even if nothing is coming in (generic solution), or add this feature to CamillaDSP output (less generic)? (NB I dont yet understand the ALSA architecture - Its on my big todo list!)


RE: How to keep HDMI audio stream alive? - TheOldPresbyope - 01-05-2024

It might be better to find out what signal is needed on HDMI to keep your AVR awake and then ask how to enable it via ALSA and the HDMI driver. (I have no idea, btw).

I like the idea of injecting silence. Reminds me of my idea to package and sell compressed vacuum back when I was a student.

Regards,
Kent


RE: How to keep HDMI audio stream alive? - oomzay - 01-06-2024

Could this configuration work without conflicting with moOde + camillaDSP automatic reconfiguration behaviour?

* Put an ALSA mixer (dmix) in front of the HDMI hw device.
* Play /dev/null into the mixer (launch this after alsa is ready - where?)
* Output camillaDSP to mixer

I am not yet clear how/where to actually configure this, but if the idea is sound I'll work that out next.
(I am very happy if this requires fixing the output channels, rate & format!)


RE: How to keep HDMI audio stream alive? - Nutul - 01-06-2024

(01-06-2024, 10:02 AM)oomzay Wrote: Could this configuration work without conflicting with moOde + camillaDSP automatic reconfiguration behaviour?

* Put an ALSA mixer (dmix) in front of the HDMI hw device.
* Play /dev/null into the mixer (launch this after alsa is ready - where?)
* Output camillaDSP to mixer

I am not yet clear how/where to actually configure this, but if the idea is sound I'll work that out next.
(I am very happy if this requires fixing the output channels, rate & format!)

It should theoretically work. The only problem I see is how to tell who to play to the mixer...


RE: How to keep HDMI audio stream alive? - oomzay - 01-06-2024

Help! I am that stage where the more I read about moOde & ALSA configuration the less I understand!

What I want to configure seems simple enough:

spotify -> camillaDSP -> mixer -> hw:HDMI

but how do I achieve that? Moode has ALSA Output "Default" and "Direct" options, Camilla has its own playback device setting but I can't see any alsa/asound.conf files in /etc or ~.


RE: How to keep HDMI audio stream alive? - Tim Curtis - 01-06-2024

Keeping the audio output open (or playing "silence") has to be done by the player i.e. MPD and it doesn't support that.
IIRC there is/was an issue posted in the MPD repo to provide this capability but I don't know its status.


RE: How to keep HDMI audio stream alive? - oomzay - 01-07-2024

@Tim Curtis I found MPD "always_on" option documented here: [https://mpd.readthedocs.io/en/stable/user.html#configuring-audio-outputs]

I added it to the audio_output section in /etc/mpd.conf but it seems this file gets overwritten automatically.


RE: How to keep HDMI audio stream alive? - steve4star - 01-07-2024

(01-07-2024, 09:42 AM)oomzay Wrote: @Tim Curtis I found MPD "always_on" option documented here: [https://mpd.readthedocs.io/en/stable/user.html#configuring-audio-outputs]

I added it to the audio_output section in /etc/mpd.conf but it seems this file gets overwritten automatically.

There is a thread about editing mpd.conf here 
https://moodeaudio.org/forum/showthread.php?tid=5706&highlight=mpd.conf