summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--bragi.nix26
-rw-r--r--custom/trivmix-service.nix3
2 files changed, 18 insertions, 11 deletions
diff --git a/bragi.nix b/bragi.nix
index 93af8fd7..67f8daf5 100644
--- a/bragi.nix
+++ b/bragi.nix
@@ -146,20 +146,26 @@ in rec {
146 }; 146 };
147 }; 147 };
148 148
149 systemd.services."mpdmix0" = trivmixService { name = "mpdmix0"; connectOut = "system:playback_3"; group = "mpd"; initial = "-35dB"; }; 149 systemd.services."mpdmix0" = trivmixService { name = "mpdmix0"; connectOut = "outnode0:in"; group = "mpd"; initial = "-35dB"; };
150 systemd.services."mpdmix1" = trivmixService { name = "mpdmix1"; connectOut = "system:playback_4"; group = "mpd"; initial = "-35dB"; }; 150 systemd.services."mpdmix1" = trivmixService { name = "mpdmix1"; connectOut = "outnode1:in"; group = "mpd"; initial = "-35dB"; };
151 151
152 systemd.services."passmix0" = trivmixService { name = "passmix0"; connectOut = "system:playback_3"; connectIn = "system:capture_5"; group = "vali_out"; initial = "-5dB"; }; 152 systemd.services."passmix0" = trivmixService { name = "passmix0"; connectOut = "outnode0:in"; connectIn = "system:capture_5"; group = "vali_out"; initial = "-5dB"; };
153 systemd.services."passmix1" = trivmixService { name = "passmix1"; connectOut = "system:playback_4"; connectIn = "system:capture_6"; group = "vali_out"; initial = "-5dB"; }; 153 systemd.services."passmix1" = trivmixService { name = "passmix1"; connectOut = "outnode1:in"; connectIn = "system:capture_6"; group = "vali_out"; initial = "-5dB"; };
154 154
155 systemd.services."passmix2" = trivmixService { name = "passmix2"; connectOut = "system:playback_5"; connectIn = "system:capture_1"; group = "vali_in"; initial = "1"; }; 155 systemd.services."passmix2" = trivmixService { name = "passmix2"; connectOut = "system:playback_5"; connectIn = "system:capture_1"; group = "mic_out"; initial = "1"; };
156 systemd.services."passmix3" = trivmixService { name = "passmix3"; connectOut = "system:playback_6"; connectIn = "system:capture_1"; group = "vali_in"; initial = "1"; }; 156 systemd.services."passmix3" = trivmixService { name = "passmix3"; connectOut = "system:playback_6"; connectIn = "system:capture_1"; group = "mic_out"; initial = "1"; };
157 157
158 systemd.services."passmix4" = trivmixService { name = "passmix4"; connectOut = "system:playback_3"; connectIn = "system:capture_7"; group = "hel_out"; initial = "-5dB"; }; 158 systemd.services."passmix4" = trivmixService { name = "passmix4"; connectOut = "outnode0:in"; connectIn = "system:capture_7"; group = "hel_out"; initial = "-5dB"; };
159 systemd.services."passmix5" = trivmixService { name = "passmix5"; connectOut = "system:playback_4"; connectIn = "system:capture_8"; group = "hel_out"; initial = "-5dB"; }; 159 systemd.services."passmix5" = trivmixService { name = "passmix5"; connectOut = "outnode1:in"; connectIn = "system:capture_8"; group = "hel_out"; initial = "-5dB"; };
160 160
161 systemd.services."passmix6" = trivmixService { name = "passmix6"; connectOut = "system:playback_7"; connectIn = "system:capture_1"; group = "hel_in"; initial = "1"; }; 161 systemd.services."outnode0" = trivmixService { name = "outnode0"; initial = "1"; };
162 systemd.services."passmix7" = trivmixService { name = "passmix7"; connectOut = "system:playback_8"; connectIn = "system:capture_1"; group = "hel_in"; initial = "1"; }; 162 systemd.services."outnode1" = trivmixService { name = "outnode1"; initial = "1"; };
163
164 systemd.services."headphones0" = trivmixService { name = "heaphones0"; connectOut = "system:playback_3"; connectIn = "outnode0:out"; group = "headphones"; initial = "1"; };
165 systemd.services."headphones1" = trivmixService { name = "heaphones1"; connectOut = "system:playback_4"; connectIn = "outnode1:out"; group = "headphones"; initial = "1"; };
166
167 systemd.services."speakers0" = trivmixService { name = "speakers0"; connectOut = "system:playback_7"; connectIn = "outnode0:out"; group = "speakers"; initial = "0"; };
168 systemd.services."speakers1" = trivmixService { name = "speakers1"; connectOut = "system:playback_8"; connectIn = "outnode1:out"; group = "speakers"; initial = "0"; };
163 169
164 services.mpd = { 170 services.mpd = {
165 enable = true; 171 enable = true;
diff --git a/custom/trivmix-service.nix b/custom/trivmix-service.nix
index e9120f88..44044504 100644
--- a/custom/trivmix-service.nix
+++ b/custom/trivmix-service.nix
@@ -4,6 +4,7 @@
4, connectIn ? null 4, connectIn ? null
5, group ? null 5, group ? null
6, initial ? null 6, initial ? null
7, adjustable ? true
7, trivmix 8, trivmix
8, stdenv 9, stdenv
9, makeWrapper 10, makeWrapper
@@ -34,7 +35,7 @@ in {
34 ${optionalString connect "--run ${connectScript}"} \ 35 ${optionalString connect "--run ${connectScript}"} \
35 ${optionalString (! isNull run) "--run ${run}"} \ 36 ${optionalString (! isNull run) "--run ${run}"} \
36 ${optionalString (! isNull initial) "--level ${initial}"} \ 37 ${optionalString (! isNull initial) "--level ${initial}"} \
37 /dev/shm/mix/${name}/level \ 38 ${optionalString (adjustable && isNull group) "/dev/shm/mix/${name}/level"} \
38 ${optionalString (! isNull group) "/dev/shm/mix/${group}/level"} 39 ${optionalString (! isNull group) "/dev/shm/mix/${group}/level"}
39 ''; 40 '';
40 User = "jack"; 41 User = "jack";