diff options
-rw-r--r-- | accounts/gkleen@sif/default.nix | 7 | ||||
-rw-r--r-- | accounts/gkleen@sif/wireplumber/bluetooth.lua.d/50-bluez-config.lua | 20 | ||||
-rw-r--r-- | accounts/gkleen@sif/wireplumber/main.lua.d/51-alsa-disable.lua | 12 | ||||
-rw-r--r-- | hosts/sif/default.nix | 12 |
4 files changed, 45 insertions, 6 deletions
diff --git a/accounts/gkleen@sif/default.nix b/accounts/gkleen@sif/default.nix index 61a5fdb4..84ac88a7 100644 --- a/accounts/gkleen@sif/default.nix +++ b/accounts/gkleen@sif/default.nix | |||
@@ -331,6 +331,13 @@ in { | |||
331 | ${pkgs.systemd}/bin/systemctl --user try-restart dunst | 331 | ${pkgs.systemd}/bin/systemctl --user try-restart dunst |
332 | ''; | 332 | ''; |
333 | }; | 333 | }; |
334 | "wireplumber" = { | ||
335 | source = ./wireplumber; | ||
336 | recursive = true; | ||
337 | onChange = '' | ||
338 | ${pkgs.systemd}/bin/systemctl --user try-restart wireplumber | ||
339 | ''; | ||
340 | }; | ||
334 | }; | 341 | }; |
335 | 342 | ||
336 | fonts.fontconfig.enable = true; | 343 | fonts.fontconfig.enable = true; |
diff --git a/accounts/gkleen@sif/wireplumber/bluetooth.lua.d/50-bluez-config.lua b/accounts/gkleen@sif/wireplumber/bluetooth.lua.d/50-bluez-config.lua new file mode 100644 index 00000000..948b7dfa --- /dev/null +++ b/accounts/gkleen@sif/wireplumber/bluetooth.lua.d/50-bluez-config.lua | |||
@@ -0,0 +1,20 @@ | |||
1 | rule = { | ||
2 | matches = { | ||
3 | { | ||
4 | { "device.name", "matches", "bluez_card.*" }, | ||
5 | }, | ||
6 | }, | ||
7 | apply_properties = { | ||
8 | ["bluez5.auto-connect"] = "[ hfp_hf hsp_hs a2dp_sink ]", | ||
9 | }, | ||
10 | } | ||
11 | |||
12 | table.insert(bluez_monitor.rules,rule) | ||
13 | |||
14 | bluez_monitor.properties = { | ||
15 | ["bluez5.enable-msbc"] = true, | ||
16 | ["bluez5.enable-sbc-xq"] = true, | ||
17 | ["bluez5.enable-hw-volume"] = false, | ||
18 | ["bluez5.headset-roles"] = "[ hsp_hs hsp_ag hfp_hf hfp_ag ]", | ||
19 | ["bluez5.codecs"] = "[ sbc sbc_xq aac ldac aptx aptx_hd aptx_ll aptx_ll_duplex faststream faststream_duplex ]", | ||
20 | } | ||
diff --git a/accounts/gkleen@sif/wireplumber/main.lua.d/51-alsa-disable.lua b/accounts/gkleen@sif/wireplumber/main.lua.d/51-alsa-disable.lua new file mode 100644 index 00000000..eafa6184 --- /dev/null +++ b/accounts/gkleen@sif/wireplumber/main.lua.d/51-alsa-disable.lua | |||
@@ -0,0 +1,12 @@ | |||
1 | rule = { | ||
2 | matches = { | ||
3 | { | ||
4 | { "device.name", "equals", "alsa_card.pci-0000_01_00.1" }, | ||
5 | }, | ||
6 | }, | ||
7 | apply_properties = { | ||
8 | ["device.disabled"] = true, | ||
9 | }, | ||
10 | } | ||
11 | |||
12 | table.insert(alsa_monitor.rules,rule) | ||
diff --git a/hosts/sif/default.nix b/hosts/sif/default.nix index 4e099f38..fc5bd8f6 100644 --- a/hosts/sif/default.nix +++ b/hosts/sif/default.nix | |||
@@ -342,9 +342,9 @@ in { | |||
342 | "link.max-buffers" = 16; | 342 | "link.max-buffers" = 16; |
343 | "log.level" = 2; | 343 | "log.level" = 2; |
344 | "default.clock.rate" = 192000; | 344 | "default.clock.rate" = 192000; |
345 | "default.clock.quantum" = 1024; | 345 | "default.clock.quantum" = 2048; |
346 | "default.clock.min-quantum" = 32; | 346 | "default.clock.min-quantum" = 32; |
347 | "default.clock.max-quantum" = 2048; | 347 | "default.clock.max-quantum" = 4096; |
348 | "core.daemon" = true; | 348 | "core.daemon" = true; |
349 | "core.name" = "pipewire-0"; | 349 | "core.name" = "pipewire-0"; |
350 | }; | 350 | }; |
@@ -402,16 +402,16 @@ in { | |||
402 | name = "libpipewire-module-protocol-pulse"; | 402 | name = "libpipewire-module-protocol-pulse"; |
403 | args = { | 403 | args = { |
404 | "pulse.min.req" = "32/192000"; | 404 | "pulse.min.req" = "32/192000"; |
405 | "pulse.default.req" = "1024/192000"; | 405 | "pulse.default.req" = "2048/192000"; |
406 | "pulse.max.req" = "2048/192000"; | 406 | "pulse.max.req" = "4096/192000"; |
407 | "pulse.min.quantum" = "32/192000"; | 407 | "pulse.min.quantum" = "32/192000"; |
408 | "pulse.max.quantum" = "2048/192000"; | 408 | "pulse.max.quantum" = "4096/192000"; |
409 | "server.address" = [ "unix:native" ]; | 409 | "server.address" = [ "unix:native" ]; |
410 | }; | 410 | }; |
411 | } | 411 | } |
412 | ]; | 412 | ]; |
413 | "stream.properties" = { | 413 | "stream.properties" = { |
414 | "node.latency" = "2048/192000"; | 414 | "node.latency" = "4096/192000"; |
415 | "resample.quality" = 1; | 415 | "resample.quality" = 1; |
416 | }; | 416 | }; |
417 | }; | 417 | }; |