try better audio config to avoid pop on suspend

This commit is contained in:
Christoph Cullmann 2024-04-21 23:13:10 +02:00
parent 92787bd8e3
commit 1995b036b4

View file

@ -199,11 +199,50 @@ in
services.desktopManager.plasma6.enable = true; services.desktopManager.plasma6.enable = true;
# enable sound with PipeWire # enable sound with PipeWire
sound.enable = true;
hardware.pulseaudio.enable = false;
services.pipewire = { services.pipewire = {
enable = true; enable = true;
alsa.enable = true; alsa = {
jack.enable = true; enable = true;
support32Bit = true;
};
pulse.enable = true; pulse.enable = true;
wireplumber.configPackages = [
(pkgs.writeTextDir "share/wireplumber/wireplumber.conf.d/alsa.conf" ''
monitor.alsa.rules = [
{
matches = [
{
device.name = "~alsa_card.*"
}
]
actions = {
update-props = {
# Device settings
api.alsa.use-acp = true
}
}
}
{
matches = [
{
node.name = "~alsa_input.pci.*"
}
{
node.name = "~alsa_output.pci.*"
}
]
actions = {
# Node settings
update-props = {
session.suspend-timeout-seconds = 0
}
}
}
]
'')
];
}; };
# allow realtime # allow realtime
@ -485,8 +524,6 @@ in
optimize = "sudo nix --extra-experimental-features nix-command store optimise"; optimize = "sudo nix --extra-experimental-features nix-command store optimise";
# ssh around in the local network # ssh around in the local network
kuro = "ssh kuro.fritz.box";
kuroroot = "ssh root@kuro.fritz.box";
mini = "ssh mini.fritz.box"; mini = "ssh mini.fritz.box";
miniroot = "ssh root@mini.fritz.box"; miniroot = "ssh root@mini.fritz.box";
neko = "ssh neko.fritz.box"; neko = "ssh neko.fritz.box";