-
-
Notifications
You must be signed in to change notification settings - Fork 243
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(deck): Restore audio changes on main, this is in lieu of steamdec…
…k-dsp which will remain on :testing for now.
- Loading branch information
Showing
5 changed files
with
190 additions
and
0 deletions.
There are no files selected for viewing
71 changes: 71 additions & 0 deletions
71
system_files/deck/shared/usr/etc/pipewire/99-input-denoising.conf
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
context.modules = [ | ||
{ name = libpipewire-module-filter-chain | ||
args = { | ||
node.description = "Noise Canceling source" | ||
media.name = "Noise Canceling source" | ||
filter.graph = { | ||
nodes = [ | ||
{ | ||
type = ladspa | ||
name = rnnoise | ||
plugin = /usr/lib64/ladspa/librnnoise_ladspa.so | ||
label = noise_suppressor_stereo | ||
control = { | ||
"VAD Threshold (%)" = 23.0 | ||
"VAD Grace Period (ms)" = 200 | ||
} | ||
} | ||
{ | ||
type = ladspa | ||
name = equaliser | ||
plugin = /usr/lib64/ladspa/caps.so | ||
label = Eq10X2 | ||
control = { | ||
"31 Hz" 0 | ||
"63 Hz" 0 | ||
"125 Hz" 0 | ||
"250 Hz" 0 | ||
"500 Hz" 0 | ||
"1 kHz" 0 | ||
"2 kHz" 0 | ||
"4 kHz" 0 | ||
"8 kHz" -3 | ||
"16 kHz" -3 | ||
} | ||
} | ||
{ | ||
type = ladspa | ||
name = compressor | ||
plugin = /usr/lib64/ladspa/caps.so | ||
label = CompressX2 | ||
control = { | ||
"measure" 1 | ||
"mode" 1 | ||
"threshold" 0.5 | ||
"strength" 0.25 | ||
"attack" 0.75 | ||
"release" 0.5 | ||
"gain (dB)" 12 | ||
} | ||
} | ||
] | ||
links = [ | ||
{ output = "rnnoise:Output (L)" input = "equaliser:in.l" } | ||
{ output = "rnnoise:Output (R)" input = "equaliser:in.r" } | ||
{ output = "equaliser:out.l" input = "compressor:in.l" } | ||
{ output = "equaliser:out.r" input = "compressor:in.r" } | ||
] | ||
} | ||
capture.props = { | ||
node.name = "capture.rnnoise_source" | ||
node.passive = true | ||
audio.rate = 48000 | ||
} | ||
playback.props = { | ||
node.name = "rnnoise_source" | ||
media.class = Audio/Source | ||
audio.rate = 48000 | ||
} | ||
} | ||
} | ||
] |
25 changes: 25 additions & 0 deletions
25
system_files/deck/shared/usr/etc/wireplumber/bluetooth.lua.d/60-bluez-jupiter.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
bluez_monitor.properties = { | ||
-- we only want these audio profiles: | ||
-- 0000110a-0000-1000-8000-00805f9b34fb Audio Source | ||
-- 0000110b-0000-1000-8000-00805f9b34fb Audio Sink | ||
-- 0000110d-0000-1000-8000-00805f9b34fb Advanced Audio Distribution | ||
["bluez5.roles"] = "[ a2dp_sink a2dp_source ]", | ||
|
||
-- And only this one headset related profile: | ||
-- 00001112-0000-1000-8000-00805f9b34fb Headset | ||
-- disabled: 00001108-0000-1000-8000-00805f9b34fb hsp_hs | ||
-- disabled: 0000111e-0000-1000-8000-00805f9b34fb hfp_hs | ||
-- disabled: 0000111f-0000-1000-8000-00805f9b34fb hfp_ag | ||
-- >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> * <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< | ||
-- NOTE: check hfphsp-backend below as that also affects hs/hf profiles | ||
-- >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> * <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<< | ||
["bluez5.headset-roles"] = "[ hsp_ag ]", | ||
|
||
-- HFP/HSP backend (default: native). | ||
-- Available values: any, none, hsphfpd, ofono, native | ||
-- setting this to "none" disables all headset roles | ||
["bluez5.hfphsp-backend"] = "none", | ||
|
||
-- Disable dummy AVRCP player | ||
["bluez5.dummy-avrcp-player"] = false | ||
} |
48 changes: 48 additions & 0 deletions
48
system_files/deck/shared/usr/etc/wireplumber/main.lua.d/60-alsa-acp5x-config.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
--ACP5X card hardware never hibernates, so remove the pops and lags. | ||
|
||
table.insert (alsa_monitor.rules, { | ||
matches = { | ||
{ | ||
-- Matches all sources from card acp5x | ||
{ "node.name", "matches", "alsa_input.*" }, | ||
{ "alsa.card_name", "matches", "acp5x" }, | ||
}, | ||
|
||
{ | ||
-- Matches all sources from card acp6x | ||
{ "node.name", "matches", "alsa_input.*" }, | ||
{ "alsa.card_name", "matches", "acp6x" }, | ||
}, | ||
|
||
{ | ||
-- Matches all sources from SOF drivers | ||
{ "node.name", "matches", "alsa_input.*" }, | ||
{ "alsa.card_name", "matches", "sof-nau8821-max" }, | ||
}, | ||
|
||
{ | ||
-- Matches all sinks from card acp5x | ||
{ "node.name", "matches", "alsa_output.*" }, | ||
{ "alsa.card_name", "matches", "acp5x" }, | ||
}, | ||
|
||
{ | ||
-- Matches all sinks from card acp6x | ||
{ "node.name", "matches", "alsa_output.*" }, | ||
{ "alsa.card_name", "matches", "acp6x" }, | ||
}, | ||
|
||
{ | ||
-- Matches all sinks from card acp6x | ||
{ "node.name", "matches", "alsa_output.*" }, | ||
{ "alsa.card_name", "matches", "sof-nau8821-max" }, | ||
}, | ||
|
||
|
||
}, | ||
apply_properties = { | ||
["session.suspend-timeout-seconds"] = 0, | ||
["api.alsa.headroom"] = 1024, | ||
|
||
} | ||
}) |
25 changes: 25 additions & 0 deletions
25
system_files/deck/shared/usr/etc/wireplumber/main.lua.d/60-alsa-card0-config.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
-- HDMI output is always plugged in card 0 (HD_Audio Generic) | ||
-- We always give higher priority to nodes from that card | ||
-- Disable suspend timeout for HDMI to remove audio delay after idle | ||
|
||
table.insert (alsa_monitor.rules, { | ||
matches = { | ||
{ | ||
-- Matches all sources from card HD-Audio Generic | ||
{ "node.name", "matches", "alsa_input.*" }, | ||
{ "alsa.card_name", "matches", "HD-Audio Generic" }, | ||
}, | ||
{ | ||
-- Matches all sinks from card HD-Audio Generic | ||
{ "node.name", "matches", "alsa_output.*" }, | ||
{ "alsa.card_name", "matches", "HD-Audio Generic" }, | ||
}, | ||
}, | ||
apply_properties = { | ||
["priority.driver"] = 900, | ||
["priority.session"] = 900, | ||
["api.alsa.period-size"] = 256, | ||
["api.alsa.headroom"] = 1024, | ||
["session.suspend-timeout-seconds"] = 0 | ||
} | ||
}) |
21 changes: 21 additions & 0 deletions
21
system_files/deck/shared/usr/etc/wireplumber/main.lua.d/60-alsa-ps-controller-config.lua
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
-- PS4/PS5 Controller output is always referenced as Wireless Controller | ||
-- We always give the lowest priority to nodes from that card | ||
|
||
table.insert (alsa_monitor.rules, { | ||
matches = { | ||
{ | ||
-- Matches all sources from card Controller | ||
{ "node.name", "matches", "alsa_input.*" }, | ||
{ "alsa.card_name", "matches", "Wireless Controller" }, | ||
}, | ||
{ | ||
-- Matches all sinks from card Wireless Controller | ||
{ "node.name", "matches", "alsa_output.*" }, | ||
{ "alsa.card_name", "matches", "Wireless Controller" }, | ||
}, | ||
}, | ||
apply_properties = { | ||
["priority.driver"] = 99, | ||
["priority.session"] = 99, | ||
} | ||
}) |