Configure pipewire so that hotplugging into an external display/speaker is recognized properly

This commit is contained in:
Joshua Yuen 2026-10-06 20:21:22 -04:00
parent eb480a205c
commit 5364812171
Signed by: josh
GPG Key ID: 530DA0331EFE99F5
1 changed files with 21 additions and 0 deletions

View File

@ -19,6 +19,27 @@ in
jack.enable = true; jack.enable = true;
}; };
# Re-enable PulseAudio-style auto profile switching (ACP), since
# WirePlumber 0.5 disables it and never reacts to HDMI hotplug events,
# leaving audio stuck on analog when a dock/TV is connected.
services.pipewire.wireplumber.extraConfig."99-acp-auto-profile" = {
"monitor.alsa.rules" = [
{
matches = [
{
"device.name" = "~alsa_card.*";
}
];
actions = {
update-props = {
"api.acp.auto-profile" = true;
"api.acp.auto-port" = true;
};
};
}
];
};
# Allows Pipewire to use the realtime scheduler for increased performance # Allows Pipewire to use the realtime scheduler for increased performance
security.rtkit.enable = true; security.rtkit.enable = true;
}; };