Skip to content

Instantly share code, notes, and snippets.

View vschroeter's full-sized avatar

Valentin Schröter vschroeter

  • Potsdam, Germany
View GitHub Profile
@vschroeter
vschroeter / BluetoothPipewireUbuntu24.md
Last active January 27, 2025 10:59
Setup bluetooth on Ubuntu 24.04 with Piperwire (on Raspberry Pi 5)

Setup bluetooth on Ubuntu 24.04 with Piperwire (on Raspberry Pi 5)

I've had a hard time bringing bluetooth to work on a Raspberry Pi 5 with Ubuntu 24.04 using Pipewire as audio backend. Maybe you run into the same situation and find this helpful.

With the common tutorials on how to enable a bluetooth speaker connection on Ubuntu, there were the following problems for my combination of Ubuntu 24.04 on a Raspberry Pi 5 and using PipeWire (as of July 2024):

  • either the audio quality was fine but the connection automatically disconnects after a few seconds
  • or the connection does not disconnect, but the audio begins to stutter extremely after 60 to 90 seconds of audio played

Since Ubuntu 22.10, PipeWire is the default soundserver on Ubuntu, so trying to use Bluetooth with PulseAudio as soundserver would mean to uninstall the recommended default and reconfigure the system.

@AkdM
AkdM / .gitignore
Last active February 11, 2025 17:58
Daily backup Home Assistant configuration into a git repository
# You can whitelist files/folders with !, those will not be ignored.
# Everything that starts with a / are for root elements
# ignore
/custom_components/
/zigbee2mqtt/log
/zigbee2mqtt/state.json
/home-assistant_v2.* # Exclude Home Assistant history-related database. Make sure to enable git LFS if you don't exclude that, since those files can go easily over 100MB
/home-assistant.log*
/.ssh/
@shakthizen
shakthizen / pipewire.md
Last active July 9, 2024 14:53 — forked from the-spyke/pipewire.md
Enable PipeWire on Ubuntu 22.04

Enable PipeWire on Ubuntu 22.04

This guide is only for original Ubuntu out-of-the-box packages. If you have added a custom PPA like pipewire-debian, you might get into conflicts.

Ubuntu 22.04 has PipeWire partially installed and enabled as it's used by browsers (WebRTC) for recoding the screeen under Wayland. We can enable remaining parts and use PipeWire for audio and Bluetooth instead of PulseAudio.

Starting from WirePlumber version 0.4.8 automatic Bluetooth profile switching (e.g. switching from A2DP to HSP/HFP when an application needs microphone access) is supported. Jammy (22.04) repos provide exactly version 0.4.8. So, we're good.

Based on Debian Wiki, but simplified for Ubuntu 22.04.