Low latency for sdac
This commit is contained in:
parent
adf3aeadfa
commit
91a5ee5df5
|
@ -111,6 +111,7 @@
|
|||
./modules/common/linux
|
||||
(common-nix stable)
|
||||
inputs.secrets.nixosModules.common
|
||||
inputs.nix-gaming.nixosModules.pipewireLowLatency
|
||||
];
|
||||
};
|
||||
|
||||
|
|
|
@ -153,6 +153,14 @@ in
|
|||
alsa.support32Bit = true;
|
||||
|
||||
pulse.enable = true;
|
||||
|
||||
lowLatency = {
|
||||
# enable this module
|
||||
enable = true;
|
||||
# defaults (no need to be set unless modified)
|
||||
quantum = 64;
|
||||
rate = 48000;
|
||||
};
|
||||
};
|
||||
# udev configurations
|
||||
services.udev.packages = with pkgs; [
|
||||
|
|
5
nki-home/audio/default.nix
Normal file
5
nki-home/audio/default.nix
Normal file
|
@ -0,0 +1,5 @@
|
|||
{ config, pkgs, lib, ... }: {
|
||||
environment.etc = {
|
||||
"wireplumber/main.lua.d/51-sdac.lua".source = ./sdac.lua;
|
||||
};
|
||||
}
|
16
nki-home/audio/sdac.lua
Normal file
16
nki-home/audio/sdac.lua
Normal file
|
@ -0,0 +1,16 @@
|
|||
rule = {
|
||||
matches = {
|
||||
{
|
||||
{ "node.name", "matches", "alsa_output.usb-Grace_Design_SDAC-00.*" },
|
||||
},
|
||||
},
|
||||
apply_properties = {
|
||||
["audio.format"] = "S24_3LE",
|
||||
["audio.rate"] = 96000,
|
||||
["api.alsa.period-size"] = 2,
|
||||
["api.alsa.headroom"] = 0,
|
||||
["api.alsa.disable-batch"] = true
|
||||
},
|
||||
}
|
||||
|
||||
table.insert(alsa_monitor.rules, rule)
|
|
@ -7,6 +7,7 @@
|
|||
imports =
|
||||
[
|
||||
(modulesPath + "/installer/scan/not-detected.nix")
|
||||
./audio
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "nvme" "xhci_pci" "ahci" "usbhid" "usb_storage" "sd_mod" ];
|
||||
|
|
Loading…
Reference in a new issue