Okay, so...
Installed ubuntu on a separate drive, did the whole:
sudo -i
apt-get install alsa-tools alsa-tools-gui -y
hdajackretask
showed unconnected pins, checked all of them and chose HDMI/DisplayPort
WinSCP'd onto the PC while running ubuntu, copied out:
/usr/bin/hdajackretask
/usr/bin/hdahacksensetest - for the lols
Changed the drive back to the one with Libreelec, copied both of those files into
/storage/.config/modprobe.d
/storage/.config/firmware
Rebooted.
Still the same. I think I may have misunderstood what you've asked me to try out.
Whilst still in Ubuntu, went into alsamixer, to see what was available with the sound working, not sure if the below means anything, but these are what are in /proc/asound on ubuntu:
root@shane-HP-ProDesk-400-G4-DM:/proc/asound# cat cards
0 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0x4000100000 irq 128
root@shane-HP-ProDesk-400-G4-DM:/proc/asound# cat devices
1: : sequencer
2: [ 0- 0]: digital audio playback
3: [ 0- 0]: digital audio capture
4: [ 0- 3]: digital audio playback
5: [ 0- 7]: digital audio playback
6: [ 0- 8]: digital audio playback
7: [ 0- 0]: hardware dependent
8: [ 0- 2]: hardware dependent
9: [ 0] : control
33: : timer
root@shane-HP-ProDesk-400-G4-DM:/proc/asound# cat hwdep
00-00: HDA Codec 0
00-02: HDA Codec 2
root@shane-HP-ProDesk-400-G4-DM:/proc/asound# cat modules
0 snd_hda_intel
root@shane-HP-ProDesk-400-G4-DM:/proc/asound#
Display More
Back on Libreelec, this is what is in most of the files there, no modules...:
LibreELEC:/proc/asound # cat cards
0 [PCH ]: HDA-Intel - HDA Intel PCH
HDA Intel PCH at 0x4000100000 irq 133
LibreELEC:/proc/asound # cat devices
2: [ 0- 0]: digital audio playback
3: [ 0- 0]: digital audio capture
4: [ 0- 0]: hardware dependent
5: [ 0- 2]: hardware dependent
6: [ 0] : control
33: : timer
LibreELEC:/proc/asound # cat hwdep
00-00: HDA Codec 0
00-02: HDA Codec 2
Display More
If I try to edit /proc/asound/devices, seems it's read only.: