[SOLVED] bluetooth can pair but how to play music now?
Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Wow took so long to pair this and then got a ding from the bluetooth speaker that it's connected.
This is a server Ubuntu Linux 20.04 Linux 5.4.0-65-generic on x86_64
Used bluetoothctl
Code:
bluetoothctl -- power on
bluetoothctl -- scan on
bluetoothctl -- pair E8:D0:3C:3D:07:C8
bluetoothctl -- connect E8:D0:3C:3D:07:C8
A little sound came from the speaker and the bluetooth fashing LED went off.
I can see it like this:
Code:
root@rayday0:~# bluetoothctl info E8:D0:3C:3D:07:C8
Device E8:D0:3C:3D:07:C8 (public)
Name: JBL Pulse 4 two
Alias: JBL Pulse 4 two
Class: 0x00240414
Icon: audio-card
Paired: yes
Trusted: yes
Blocked: no
Connected: yes
LegacyPairing: no
UUID: Serial Port (00001101-0000-1000-8000-00805f9b34fb)
UUID: Audio Sink (0000110b-0000-1000-8000-00805f9b34fb)
UUID: A/V Remote Control Target (0000110c-0000-1000-8000-00805f9b34fb)
UUID: A/V Remote Control (0000110e-0000-1000-8000-00805f9b34fb)
root@rayday0:~#
Now how do I play a sound though it?
Can look on Google and all say how to pair them but none I can find that say how to play sound though them. I did but it was on the desktop. Not server.
Here is what I did on the command line and thought it would list it as JBL Pulse4 two but don't see that when I do a squeezelite -l to pick it to play music with.
Here is my command line:
Code:
root@rayday0:~# bluetoothctl
Agent registered
[CHG] Controller A4:34:D9:0D:C7:E3 Pairable: yes
[JBL Pulse 4 two]# help
Menu main:
Available commands:
-------------------
advertise Advertise Options Submenu
scan Scan Options Submenu
gatt Generic Attribute Submenu
list List available controllers
show [ctrl] Controller information
select <ctrl> Select default controller
devices List available devices
paired-devices List paired devices
system-alias <name> Set controller alias
reset-alias Reset controller alias
power <on/off> Set controller power
pairable <on/off> Set controller pairable mode
discoverable <on/off> Set controller discoverable mode
discoverable-timeout [value] Set discoverable timeout
agent <on/off/capability> Enable/disable agent with given capability
default-agent Set agent as the default one
advertise <on/off/type> Enable/disable advertising with given type
set-alias <alias> Set device alias
scan <on/off> Scan for devices
info [dev] Device information
pair [dev] Pair with device
trust [dev] Trust device
untrust [dev] Untrust device
block [dev] Block device
unblock [dev] Unblock device
remove <dev> Remove device
connect <dev> Connect device
disconnect [dev] Disconnect device
menu <name> Select submenu
version Display version
quit Quit program
exit Quit program
help Display help about this program
export Print environment variables
[JBL Pulse 4 two]# trust E8:D0:3C:3D:07:C8
Changing E8:D0:3C:3D:07:C8 trust succeeded
[JBL Pulse 4 two]# connect E8:D0:3C:3D:07:C8
Attempting to connect to E8:D0:3C:3D:07:C8
Connection successful
[JBL Pulse 4 two]# exit
root@rayday0:~# squeezelite -l
Output devices:
default - Playback/recording through the PulseAudio sound server
surround21 - 2.1 Surround output to Front and Subwoofer speakers
surround40 - 4.0 Surround output to Front and Rear speakers
surround41 - 4.1 Surround output to Front, Rear and Subwoofer speakers
surround50 - 5.0 Surround output to Front, Center and Rear speakers
surround51 - 5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71 - 7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
null - Discard all samples (playback) or generate zero samples (capture)
samplerate - Rate Converter Plugin Using Samplerate Library
speexrate - Rate Converter Plugin Using Speex Resampler
jack - JACK Audio Connection Kit
oss - Open Sound System
pulse - PulseAudio Sound Server
upmix - Plugin for channel upmix (4,6,8)
vdownmix - Plugin for channel downmix (stereo) with a simple spacialization
bluetoothspeaker - Max2Play bluetooth speaker
btheadset
hdmi:CARD=PCH,DEV=0 - HDA Intel PCH, HDMI 0 - HDMI Audio Output
hdmi:CARD=PCH,DEV=1 - HDA Intel PCH, HDMI 1 - HDMI Audio Output
hdmi:CARD=PCH,DEV=2 - HDA Intel PCH, HDMI 2 - HDMI Audio Output
hdmi:CARD=PCH,DEV=3 - HDA Intel PCH, HDMI 3 - HDMI Audio Output
hdmi:CARD=PCH,DEV=4 - HDA Intel PCH, HDMI 4 - HDMI Audio Output
dmix:CARD=PCH,DEV=3 - HDA Intel PCH, HDMI 0 - Direct sample mixing device
dmix:CARD=PCH,DEV=7 - HDA Intel PCH, HDMI 1 - Direct sample mixing device
dmix:CARD=PCH,DEV=8 - HDA Intel PCH, HDMI 2 - Direct sample mixing device
dmix:CARD=PCH,DEV=9 - HDA Intel PCH, HDMI 3 - Direct sample mixing device
dmix:CARD=PCH,DEV=10 - HDA Intel PCH, HDMI 4 - Direct sample mixing device
dsnoop:CARD=PCH,DEV=3 - HDA Intel PCH, HDMI 0 - Direct sample snooping device
dsnoop:CARD=PCH,DEV=7 - HDA Intel PCH, HDMI 1 - Direct sample snooping device
dsnoop:CARD=PCH,DEV=8 - HDA Intel PCH, HDMI 2 - Direct sample snooping device
dsnoop:CARD=PCH,DEV=9 - HDA Intel PCH, HDMI 3 - Direct sample snooping device
dsnoop:CARD=PCH,DEV=10 - HDA Intel PCH, HDMI 4 - Direct sample snooping device
hw:CARD=PCH,DEV=3 - HDA Intel PCH, HDMI 0 - Direct hardware device without any conversions
hw:CARD=PCH,DEV=7 - HDA Intel PCH, HDMI 1 - Direct hardware device without any conversions
hw:CARD=PCH,DEV=8 - HDA Intel PCH, HDMI 2 - Direct hardware device without any conversions
hw:CARD=PCH,DEV=9 - HDA Intel PCH, HDMI 3 - Direct hardware device without any conversions
hw:CARD=PCH,DEV=10 - HDA Intel PCH, HDMI 4 - Direct hardware device without any conversions
plughw:CARD=PCH,DEV=3 - HDA Intel PCH, HDMI 0 - Hardware device with all software conversions
plughw:CARD=PCH,DEV=7 - HDA Intel PCH, HDMI 1 - Hardware device with all software conversions
plughw:CARD=PCH,DEV=8 - HDA Intel PCH, HDMI 2 - Hardware device with all software conversions
plughw:CARD=PCH,DEV=9 - HDA Intel PCH, HDMI 3 - Hardware device with all software conversions
plughw:CARD=PCH,DEV=10 - HDA Intel PCH, HDMI 4 - Hardware device with all software conversions
usbstream:CARD=PCH - HDA Intel PCH - USB Stream Output
sysdefault:CARD=LAPDOCK - LAPDOCK, USB Audio - Default Audio Device
front:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - Front speakers
surround21:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - 2.1 Surround output to Front and Subwoofer speakers
surround40:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - 4.0 Surround output to Front and Rear speakers
surround41:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - 4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - 5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - 5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - 7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
iec958:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - IEC958 (S/PDIF) Digital Audio Output
dmix:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - Direct sample mixing device
dsnoop:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - Direct sample snooping device
hw:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - Direct hardware device without any conversions
plughw:CARD=LAPDOCK,DEV=0 - LAPDOCK, USB Audio - Hardware device with all software conversions
usbstream:CARD=LAPDOCK - LAPDOCK - USB Stream Output
root@rayday0:~#
The:
Code:
bluetoothspeaker - Max2Play bluetooth speaker
btheadset
Are there because I been working on this for 2 days now and if I do a:
or the btheadset it still don't play music through it.
I though after I did connect and how it shows the name when you go in to bluetoothctl the prompt shows [JBL Pulse 4 two] so I thought that would show up in the devices list. squeezelite -l but it can't be that easy.
Guess if someone else does this. I think some were before this I set a pulse file up with the mac address of the Bluetooth speaker. I guess that is why it works though bluetooth now. Not sure where this file is.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.