HDMI Passthrough RPi4 - AVR detection

  • I also have problem getting audio output device setting stick in Kodi as libreELEC does not seem to recognize my AVR when it's in standby mode.


    My setup is as follow:

    HDMI 1 Sony XH95

    HDMI 2 Pioneer VSX-520 AVR


    I am also doing some tests with my hdmi 1.4 receiver like yours and a LG oled 65c8, but until now I have not been able to get the audio from the receiver to work, in your tests the audio from the receiver you have managed to make it work.

  • I am also doing some tests with my hdmi 1.4 receiver like yours and a LG oled 65c8, but until now I have not been able to get the audio from the receiver to work, in your tests the audio from the receiver you have managed to make it work.

    Yeah, for me everything works just fine IF my Pioneer AVR is turned on before I boot up LE. I can then select audio output device correctly and set passthrough device correctly. Pioneer shows DTS HD and True HD etc. when playing content that has those tracks. Also HDR works well enough currently (minus some previously mentioned issues).


    Gonna test today after work what Hias suggested previously and will update what happens.


    HiassofT

    Do I need to load also edid file for my Sony TV or is the Pioneer edid loading enough? In your example you are using dat file for LG tv so you surely are not suggesting I use the same one with my Sony tv but instead I generate a new one for my tv?


    What about the full hd mode setting, does it have any affect about the 4k output in kodi in content wise? UI in kodi of course is set to 1080p already.

  • DerangedPineapple Pioneer edid loading (plus the associated video option for HDMI-A-2) should be enough - assuming you didn't have any issues with TV detection.


    I mainly posted the example to illustrate that multiple edid files need to be supplied with a single drm.edid_file option (separated by comma) and video mode settings as separate options.


    so long,


    Hias

  • Ok, I started from the scratch.


    There has not been any problems what so ever with Sony TV recognition so I don't include it's edid in loading.


    I booted up LE with TV and AVR turned on and verified that Kodi can see my AVR and it is so.


    Created the pioneer-vsx520.bin file following the steps in post #7 (copy pasted everything except used different HDMI port and different bin file name obviously).


    My /flash/config.txt

    External Content pastebin.com
    Content embedded from external sources will not be displayed without your consent.
    Through the activation of external content, you agree that personal data may be transferred to third party platforms. We have provided more information on this in our privacy policy.


    My /flash/cmdline.txt:

    Code
    boot=UUID=1903-1858 disk=UUID=ccb324ea-ccd0-4da9-83bd-1a85867fba48 quiet drm.edid_firmware=HDMI-A-2:edid/pioneer-vsx520.bin video=HDMI-A-2:D

    After everything was done I rebooted with AVR in standby mode and Kodi did see my AVR finally.


    dmesg | grep EDID returned:

    Code
    LibreELEC:~ # dmesg | grep EDID
    [    1.579482] [drm] Got external EDID base block and 1 extension from "edid/pioneer-vsx520.bin" for connector "HDMI-A-2"
    [   11.599213] [drm] Got external EDID base block and 1 extension from "edid/pioneer-vsx520.bin" for connector "HDMI-A-2"
    [   13.662040] [drm] Got external EDID base block and 1 extension from "edid/pioneer-vsx520.bin" for connector "HDMI-A-2"
    [   13.689616] [drm] Got external EDID base block and 1 extension from "edid/pioneer-vsx520.bin" for connector "HDMI-A-2"

    However if I remove the video=HDMI-A-2:D from cmdline.txt then Kodi won't see my AVR when it's in standby mode. Also dmesg does not find any EDID lines then either.


    Pastekodi: http://ix.io/2TRh


    Keep in mind that above pastekodi log was recorded with multiple reboots with debug turned on and several reboots actually worked as I was trying out whether LE sees my AVR when it's in standby.


    All in all, now it works perfectly reboot after reboot. On to the next issue which is the hdmi_ignore_cec_init=1 as it does nothing, often even my AVR turns on and TV also when booting LE but that's another story.


    Anyways, thank you very much for the help! Highly appreciated and I must say, awesome work you guys do with LE!

  • Thanks a lot for reporting back and I'm glad it's working now!


    I expected that the video= option is needed, without it linux doesn't detect that AVR.


    I'm currently working on a script to simplify this whole edid stuff - hopefully that should make it into beta2.


    I'm not 100% sure why hdmi_ignore_cec_init doesn't seem to work - make sure everything's set up correctly in kodi's CEC settings (though CEC should only be ever used on hdmi0 in kodi/linux - so it's puzzling why your AVR turns on).


    so long,


    Hias

  • Sure np, my pleasure to help in any way even if it's just providing feedback :)


    You can take that "AVR turned on with LE boot up" statement of mine with grain of salt as it may have happened because of ... well literally anything like cat stepped on the remote or something like that. It has not happened again so something else must be in play here and as you say it should not even be possible.


    I had CEC settings in kodi set as default when my TV woke up with LE boot up event. That's why I disabled almost everything in the CEC addon settings to prevent that. Will test further. I'll just open a new thread regarding this issue if I can find a way to reproduce it reliably.


    I will test it further how hdmi_ignore_cec_init behaves with my TV when I reset every CEC addon settings in the Kodi. Although this should not have any affect how hdmi_ignore_cec_init works in LE boot up event though right?


    Anyways, my setup is very close to be the perfect media and retro gaming station thanks to hard work of you guys. It's also extremely nice not have to pointlessly update my AVR just because it only supports hdmi 1.4 while being just fine AVR for the HBR purposes.

  • I'm currently working on a script to simplify this whole edid stuff - hopefully that should make it into beta2.

    Great thread topic on AVR detection and explanation on how-to utilse rpi4's spare HDMI port to output audio directly to AVR (HDMI 1.4b in my case) when following Settings are correctly assigned to required hdmi out. :cool:

    • Settings -> System -> Audio -> Audio output device
    • Settings -> System -> Audio -> Passthrough output device

    Just been testing method/process with hdmi0 (video) and hdmi1 (audio) this morning (which works perfectly, thanks) and like others, I now understand will need to permanently setup edid and config, such that rpi4 remembers hdmi1 connection, when rpi4 and/or AVR is powered off/on.


    Thank you HiassofT :thumbup:

    RPi4, (LibreELEC 10.0 Nightlies) Philips 55PUS7304 4K TV, Onkyo TX-SR608 AV Receiver.

  • Great thread topic on AVR detection and explanation on how-to utilse rpi4's spare HDMI port to output audio directly to AVR (HDMI 1.4b in my case) when following Settings are correctly assigned to required hdmi out. :cool:

    • Settings -> System -> Audio -> Audio output device
    • Settings -> System -> Audio -> Passthrough output device

    Just been testing method/process with hdmi0 (video) and hdmi1 (audio) this morning (which works perfectly, thanks) and like others, I now understand will need to permanently setup edid and config, such that rpi4 remembers hdmi1 connection, when rpi4 and/or AVR is powered off/on.


    Thank you HiassofT :thumbup:

    To me, on the other hand, I still can't get the audio to work, if I connect my Marantz av7701 to the second hdmi output of the raspberry pi4.

    The receiver is regularly recognized and with the method written in this thread, the receiver also works and I turn it off when I turn on the raspberry, but unfortunately no audio.


  • ginogio65 be aware that in my case I am still relying on manual method (checking through kodi GUI) that audio correctly assigned to hdmi1

    (Between reboots of rpi4 to update to latest nightly and when my TV/AVR combination are switched off/on)


    in my case, I need to ensure ALSA: vc4-hdmi-1, ONK TX-SR608 on HDMI is selected

    in your case, I note from secreen grab that you need to ensure ALSA: vc4-hdmi-1, MJI Marantz-AVR on HDMI is selected


    My understanding is that vc4-hdmi-1 relates to card0-HDMI-A-2 where for my own understanding I double checked by sshing into rpi4 and inputting tail /sys/class/drm/*/status command when both my TV and AVR is switched on and fully recognised.

    Code
    tail /sys/class/drm/*/status
    ==> /sys/class/drm/card0-HDMI-A-1/status <==
    connected
    
    ==> /sys/class/drm/card0-HDMI-A-2/status <==
    connected

    So in my usage case above confirms


    hdmi0 = card0-HDMI-A-1 = Philips 55PUS7304 4K TV

    hdmi1 = card0-HDMI-A-2 = Onkyo TX-SR608 AV Receiver


    You are ensuring that your AVR is remaining switched/fixed to hdmi port that you connected your rpi4 to your AVR and that both Audio settings assigned to ALSA: vc4-hdmi-1, MJI Marantz-AVR on HDMI ?


    This question/comment relates to my usage case with my TV connected to HDMI out from my AVR in order to utilise CEC/ARC features between TV/AVR. If I am not observant I can miss fact that my AVR may switch from rpi input hdmi port to TV output hdmi port.

    (i.e. Does this infrequently during navigation of Kodi GUI controlled via CEC and remote of TV)

    RPi4, (LibreELEC 10.0 Nightlies) Philips 55PUS7304 4K TV, Onkyo TX-SR608 AV Receiver.