Using an Intel NUC11TNHi5
,Tiger Lake, I've no HDMI sound on boot on a Samsung TV model Q80A
.
Running ubuntu 22.04, kernel 5.15.0-53-generic
, with intel-media-va-driver-non-free
and enable_fbc=1 enable_guc=3 fastboot=1
as option for i915 module_
Bug is present on wayland and xorg/x11
I can fix this either via
- unpluging the HDMI cable
- Disabling OR Enabling a TV setting Input signal plus.
(I beleive the TV need to be forced to rescan input to detect the audio or something like that)
This bug isn't present on windows 10
After the startup disable then re enable the output with xrandr
It's an HDMI cable but marked as DP-1 go figure why.
mkdir -p ~/.config/systemd/user/
cat <<EOF > ~/.config/systemd/user/samsung-hdmi-sound-fix.service
[Unit]
Description=Fix samsung HDMI audio bug
[Service]
# Wait 5 second after startup of the user session
ExecStartPre=/bin/sleep 5
# Turn off for 20s the output
ExecStartPre=xrandr --output DP-1 --off
ExecStartPre=/bin/sleep 20
# Reenable the output with the right setting UHD 60hz scale 200% with audio.
ExecStart=xrandr --output DP-1 --mode 3840x2160 --rate 60 --scale 0.5x0.5 --set audio on
Type=oneshot
[Install]
WantedBy=default.target
EOF
systemctl --user daemon-reload
systemctl --user enable samsung-hdmi-sound-fix.service
This will automatically turn off then later turn back on your screen on session startup.
This is really ugly but working well so far