Skip to content

Instantly share code, notes, and snippets.

@kiwec
Last active May 27, 2023 07:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kiwec/ea3b0f42bec12d46ba587b298bf81808 to your computer and use it in GitHub Desktop.
Save kiwec/ea3b0f42bec12d46ba587b298bf81808 to your computer and use it in GitHub Desktop.
Pipewire settings for FiiO K3
properties = {}
rules = [
{
matches = [{
node.name = "alsa_output.usb-GuangZhou_FiiO_Electronics_Co._Ltd_FiiO_K3-00.iec958-stereo"
}]
actions = {
update-props = {
audio.format = "S32LE"
# Should be twice the desired rate
audio.rate = 384000
api.alsa.headroom = 0
api.alsa.disable-batch = true
}
}
}
{
matches = [
{ device.name = "~alsa_card.*" }
]
actions = {
update-props = {
api.alsa.use-acp = true
api.acp.auto-profile = false
api.acp.auto-port = false
}
}
}
{
matches = [
{ node.name = "~alsa_input.*" }
{ node.name = "~alsa_output.*" }
]
actions = {
update-props = { node.pause-on-idle = false }
}
}
]
context.properties = {}
context.exec = []
stream.properties = {}
context.spa-libs = {
audio.convert.* = audioconvert/libspa-audioconvert
support.* = support/libspa-support
}
context.modules = [
{ name = libpipewire-module-rtkit
args = {
nice.level = -11
}
flags = [ ifexists nofail ]
}
{ name = libpipewire-module-protocol-native }
{ name = libpipewire-module-client-node }
{ name = libpipewire-module-adapter }
{ name = libpipewire-module-metadata }
{ name = libpipewire-module-protocol-pulse
args = {
server.address = [
"unix:native"
]
pulse.min.req = 128/192000
pulse.min.quantum = 128/192000
}
}
]
context.properties = {
link.max-buffers = 16
core.daemon = true
core.name = pipewire-0
default.clock.allowed-rates = [ 192000 48000 44100 ]
default.clock.rate = 192000
default.clock.quantum = 32
default.clock.min-quantum = 16
default.clock.max-quantum = 256
}
context.spa-libs = {
audio.convert.* = audioconvert/libspa-audioconvert
api.alsa.* = alsa/libspa-alsa
api.v4l2.* = v4l2/libspa-v4l2
api.libcamera.* = libcamera/libspa-libcamera
api.bluez5.* = bluez5/libspa-bluez5
api.vulkan.* = vulkan/libspa-vulkan
api.jack.* = jack/libspa-jack
support.* = support/libspa-support
}
context.modules = [
{ name = libpipewire-module-rtkit
args = {
}
flags = [ ifexists nofail ]
}
{ name = libpipewire-module-protocol-native }
{ name = libpipewire-module-profiler }
{ name = libpipewire-module-metadata }
{ name = libpipewire-module-spa-device-factory }
{ name = libpipewire-module-spa-node-factory }
{ name = libpipewire-module-client-node }
{ name = libpipewire-module-client-device }
{ name = libpipewire-module-portal
flags = [ ifexists nofail ]
}
{ name = libpipewire-module-access
args = {
}
}
{ name = libpipewire-module-adapter }
{ name = libpipewire-module-link-factory }
{ name = libpipewire-module-session-manager }
]
context.objects = [
{ factory = spa-node-factory
args = {
factory.name = support.node.driver
node.name = Dummy-Driver
node.group = pipewire.dummy
priority.driver = 20000
}
}
{ factory = spa-node-factory
args = {
factory.name = support.node.driver
node.name = Freewheel-Driver
priority.driver = 19000
node.group = pipewire.freewheel
node.freewheel = true
}
}
]
context.exec = [
{ path = "/bin/wireplumber" args = "" }
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment