Skip to content

Add Bluetooth audio support and a Terminal-based music player#5

Open
ggoodale wants to merge 23 commits into
ardangelo:masterfrom
ggoodale:bluetooth
Open

Add Bluetooth audio support and a Terminal-based music player#5
ggoodale wants to merge 23 commits into
ardangelo:masterfrom
ggoodale:bluetooth

Conversation

@ggoodale
Copy link
Copy Markdown

This PR adds the following:

  • Pipewire, a low-level Linux audio management framework
  • BlueZ v5, Bluetooth support for Linux
  • cmus, a terminal-based music player for Linux

Pipewire is configured to launch at boot time, owned by the beepy user for ease of use. BlueZ integration is configured and pipewire will auto-switch to a bluetooth audio device when one is connected.

To use:

  1. Make sure your chosen bluetooth audio device is in pairing mode.
  2. As root, launch bluetoothctl and run the following:
[bluetooth]# scan on

< much console spam detailing detected. Look for the <hex device id> for the device you want to connect to.>

[bluetooth]# scan off
[bluetooth]# trust <hex device id>
[bluetooth]# pair<hex device id>
  1. Your bluetooth audio device should now be paired with your Beepy. Restart pipewire:
> sudo /etc/init.d/background/S45pipewire restart
  1. as the beepy user, launch cmus:
> cmus

Default shortcuts:

  • '5' will launch a file browser in your current directory
  • 'q' will quit
  • 'x' starts playback
  • 'c' pauses playback
  • 'v; stops playback

Currently this supports MP3, ogg, and WAV, but cmus could be rebuilt with support for AAC, FLAC, or other audio formats as well. Tested with a pair of Apple bluetooth headphones and a bluetooth speaker I had laying around.

@ardangelo It appears that submodule changes have been swept up in this PR for reasons beyond my limited git-fu. let me know if I need to recreate this PR to exclude them (and how to do that, if you know!)

Grant Goodale and others added 19 commits January 14, 2024 12:35
…b to make wifi happy, but that's neither here nor there
Something in udev would really prefer it if there was an "sgx" group in existence at boot time.
Something in udev would really prefer it if there was an "sgx" group in existence at boot time.
@ardangelo
Copy link
Copy Markdown
Owner

After rebasing on master branch, I was able to pair and play a few seconds of an MP3. It did cut out after a few seconds and then cmus locked up. Could be something with my Bluetooth setup, though.

@ggoodale
Copy link
Copy Markdown
Author

ggoodale commented Jan 28, 2024 via email

@ardangelo
Copy link
Copy Markdown
Owner

Just got back to this,
Can you rebase on the master branch? Or if you give me write access to the branch I can rebase it.
I'm preparing another release soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants