Replies: 2 comments 1 reply
-
|
take a look at this for your BT playback scenario https://github.com/scyto/ha-bluetooth-audio-manager this would help with your audio our to BT devices, for audio in I am blocked by lack of SCO support in haos audio (i may take a crack at it at some point as it should be just the additon of a couple of modules to PA config hass audio container) I do think pipewire is likely the long term direction but it is not the magic solution either - for example there are may broken scenarios in pipewire for multiplexing or de-multiplexing audio that seem just plain brokem, and too many of their utils assume an X installation (e.g. the hdjackretask app). i had to build my own for that one lol |
Beta Was this translation helpful? Give feedback.
-
|
For reference, here are two indirectly related feature requests for Open Home Foundation’s experimental Linux-Voice-Assistant project (to make remote Linux-based voice assistant satellites running on Raspberry Pi SBC-type computers) that adds additional use case for Pipewire in HAOS. See: And |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Could if be a good idea to implement PipeWire (and WirePlumber) audio pipeline(s) for "Local Audio-Out" and "Local Audio-In" in HAOS with the Music Assistant add-on?
Why a operatingsystem like Home Assistant Operating System would want use PipeWire is summerized in their FAQ here ("Linux has 1 kernel API named ALSA. PipeWire unifies the 2 user-space servers in practical use: PulseAudio and JACK. With 1 Kernel and 1 user-space audio subsystem, Linux has reached the ideal situation."). PipeWire has been used since Fedora 27 (November 2017) for Wayland screen sharing and has been the default audio server since Fedora 34 (April 2021).
Some additional benefits to using PipeWire:
I think that PipeWire could more or less also be used as a drop-in replacement for applications that normally interact with PulseAudio, JACK, or ALSA. One specific use case for PipeWire (and WirePlumber) could be useful for is "Local Audio-Input" with the Music Assistant add-on?
https://github.com/orgs/music-assistant/discussions/1156
WirePlumber is an optinal modular high-level session / policy manager library that wraps PipeWire's API for external daemons/tools:
https://pipewire.pages.freedesktop.org/wireplumber/
https://fedoraproject.org/wiki/Changes/WirePlumber
https://wiki.archlinux.org/title/WirePlumber
https://wiki.gentoo.org/wiki/WirePlumber
Was mostly wondering if adding PipeWire support could achieve a better plug-and-play experience (as per HA roadmap goals)?
I have not verified but understand that PipeWire has low-latency performence as long as use high audio sample rate?
As I understand PipeWire (and WirePlumber) depends on ALSA and them working in userspace making them useful.
Link to PipeWire FAQ for reference:
ALSA is still the kernel-level interface, so concept-wise PipeWire just unifies JACK and PulseAudio into one service, and handles a few other things as well. From a user perspective it more or less just merging everything into one unified interface, which should be more user-friendly. With the idea behind PipeWire being to be compatible with every other audio subsystem on Linux, and unify audio and video streaming under one roof, as well as fix the audio latency of PulseAudio.
PipeWire is generally recommended over PulseAudio for modern Linux, offering lower latency, better Bluetooth support, and native compatibility with both PulseAudio and JACK applications, making it superior for both general use and and music production.
For backward-compatiblity a tip is that can on theory make PipeWire backwards-compatible with PulseAudio if use
pipewire-pulse, see:DESCRIPTION: pipewire-pulse starts a PulseAudio-compatible daemon that integrates with the PipeWire media server, by running a pipewire process through a systemd service. This daemon is a drop-in replacement for the PulseAudio daemon.
PipeWire can also replaces JACK but provides a jack-compatible API with results being that JACK clients being redirected to PipeWire. See:
DESCRIPTION: pw-jack modifies the LD_LIBRARY_PATH environment variable so that applications will load PipeWire's reimplementation of the JACK client libraries instead of JACK's own libraries. If PipeWire's reimplementation of the JACK client libraries has been installed as a system-wide replacement for JACK's own libraries, then the whole system already behaves in that way, in which case pw-jack has no practical effect.
Beta Was this translation helpful? Give feedback.
All reactions