unofficial mirror of bug-guix@gnu.org 
 help / color / mirror / code / Atom feed
* bug#38915: Can't change profile of Bluetooth headphones
@ 2020-01-04 13:30 Matthew Leach
  2020-01-04 21:33 ` Ricardo Wurmus
  0 siblings, 1 reply; 4+ messages in thread
From: Matthew Leach @ 2020-01-04 13:30 UTC (permalink / raw)
  To: 38915

Hi Guix!

I have a pair of Bluetooth headphones that I I've paired and connected to
my guix machine.  They show up in the 'configuration' tab of
pavucontrol.  By default the profile is 'Headset Head Unit (HSP/HFP)'.

When I try and change the profile to 'High Fidelity Playback (A2DP Sink)'
this fails and the headphones are stuck in the HSP profile.

I see the following line in `/var/log/debug' when attempting to switch
profiles:

--8<---------------cut here---------------start------------->8---
W: [pulseaudio] module-bluez5-device.c: Refused to switch profile to a2dp_sink: Not connected
--8<---------------cut here---------------end--------------->8---

It looks as though this may have something to do with pulseaudio running
as the GDM user: [0].  My current work-around for this is:

--8<---------------cut here---------------start------------->8---
$ sudo killall pulseaudio && pulseaudio
--8<---------------cut here---------------end--------------->8---

to make pulseaudio run as my user.

[0]: https://wiki.debian.org/BluetoothUser/a2dp#Refused_to_switch_profile_to_a2dp_sink:_Not_connected
-- 
Matt

^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#38915: Can't change profile of Bluetooth headphones
  2020-01-04 13:30 bug#38915: Can't change profile of Bluetooth headphones Matthew Leach
@ 2020-01-04 21:33 ` Ricardo Wurmus
  2020-01-05 20:04   ` Matthew Leach
  2020-01-05 20:05   ` Matthew Leach
  0 siblings, 2 replies; 4+ messages in thread
From: Ricardo Wurmus @ 2020-01-04 21:33 UTC (permalink / raw)
  To: Matthew Leach; +Cc: 38915


Hi Matthew,

> I have a pair of Bluetooth headphones that I I've paired and connected to
> my guix machine.  They show up in the 'configuration' tab of
> pavucontrol.  By default the profile is 'Headset Head Unit (HSP/HFP)'.
>
> When I try and change the profile to 'High Fidelity Playback (A2DP Sink)'
> this fails and the headphones are stuck in the HSP profile.
>
> I see the following line in `/var/log/debug' when attempting to switch
> profiles:
>
> --8<---------------cut here---------------start------------->8---
> W: [pulseaudio] module-bluez5-device.c: Refused to switch profile to a2dp_sink: Not connected
> --8<---------------cut here---------------end--------------->8---
>
> It looks as though this may have something to do with pulseaudio running
> as the GDM user: [0].  My current work-around for this is:
>
> --8<---------------cut here---------------start------------->8---
> $ sudo killall pulseaudio && pulseaudio
> --8<---------------cut here---------------end--------------->8---
>
> to make pulseaudio run as my user.

For what it’s worth: if you have a setup that doesn’t require pulseaudio
it is possible to use bluez-alsa (running bluealsa as a daemon) and
configure it to use the a2dp profile.  I’m using this on a headless
“server” in the living room to send music to bluetooth speakers.

> [0]: https://wiki.debian.org/BluetoothUser/a2dp#Refused_to_switch_profile_to_a2dp_sink:_Not_connected

The second workaround requires writing a configuration file to the gdm
user’s home directory.  Is this something that we could do in the gdm
service configuration?

--
Ricardo

^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#38915: Can't change profile of Bluetooth headphones
  2020-01-04 21:33 ` Ricardo Wurmus
@ 2020-01-05 20:04   ` Matthew Leach
  2020-01-05 20:05   ` Matthew Leach
  1 sibling, 0 replies; 4+ messages in thread
From: Matthew Leach @ 2020-01-05 20:04 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: 38915

Ricardo Wurmus <rekado@elephly.net> writes:

> Hi Matthew,

Hi Ricardo,

Thanks for your reply.

>
>> I have a pair of Bluetooth headphones that I I've paired and connected to
>> my guix machine.  They show up in the 'configuration' tab of
>> pavucontrol.  By default the profile is 'Headset Head Unit (HSP/HFP)'.
>>
>> When I try and change the profile to 'High Fidelity Playback (A2DP Sink)'
>> this fails and the headphones are stuck in the HSP profile.
>>
>> I see the following line in `/var/log/debug' when attempting to switch
>> profiles:
>>
>> --8<---------------cut here---------------start------------->8---
>> W: [pulseaudio] module-bluez5-device.c: Refused to switch profile to a2dp_sink: Not connected
>> --8<---------------cut here---------------end--------------->8---
>>
>> It looks as though this may have something to do with pulseaudio running
>> as the GDM user: [0].  My current work-around for this is:
>>
>> --8<---------------cut here---------------start------------->8---
>> $ sudo killall pulseaudio && pulseaudio
>> --8<---------------cut here---------------end--------------->8---
>>
>> to make pulseaudio run as my user.
>
> For what it’s worth: if you have a setup that doesn’t require
> pulseaudio it is possible to use bluez-alsa (running bluealsa as a
> daemon) and configure it to use the a2dp profile. I’m using this on a
> headless “server” in the living room to send music to bluetooth
> speakers.

Ideally I'd like to use pulseaudio as I have multiple streams that I
send to my bluetooth speaker. Nevertheless, I tried to give bluez-alsa a
go but I failed to kill pulseaudio. It would always start back up as the
GDM user.

>
>> [0]: https://wiki.debian.org/BluetoothUser/a2dp#Refused_to_switch_profile_to_a2dp_sink:_Not_connected
>
> The second workaround requires writing a configuration file to the gdm
> user’s home directory. Is this something that we could do in the gdm
> service configuration?

Ideally i'd like to stop GDM running pulseaudio as I can test out your
solution above and it may fix this issue. I'm unsure how to modify GDMs
configuration, however.
-- 
Matt

^ permalink raw reply	[flat|nested] 4+ messages in thread

* bug#38915: Can't change profile of Bluetooth headphones
  2020-01-04 21:33 ` Ricardo Wurmus
  2020-01-05 20:04   ` Matthew Leach
@ 2020-01-05 20:05   ` Matthew Leach
  1 sibling, 0 replies; 4+ messages in thread
From: Matthew Leach @ 2020-01-05 20:05 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: 38915

Ricardo Wurmus <rekado@elephly.net> writes:

> Hi Matthew,

Hi Ricardo,

Thanks for your reply.

>
>> I have a pair of Bluetooth headphones that I I've paired and connected to
>> my guix machine.  They show up in the 'configuration' tab of
>> pavucontrol.  By default the profile is 'Headset Head Unit (HSP/HFP)'.
>>
>> When I try and change the profile to 'High Fidelity Playback (A2DP Sink)'
>> this fails and the headphones are stuck in the HSP profile.
>>
>> I see the following line in `/var/log/debug' when attempting to switch
>> profiles:
>>
>> --8<---------------cut here---------------start------------->8---
>> W: [pulseaudio] module-bluez5-device.c: Refused to switch profile to a2dp_sink: Not connected
>> --8<---------------cut here---------------end--------------->8---
>>
>> It looks as though this may have something to do with pulseaudio running
>> as the GDM user: [0].  My current work-around for this is:
>>
>> --8<---------------cut here---------------start------------->8---
>> $ sudo killall pulseaudio && pulseaudio
>> --8<---------------cut here---------------end--------------->8---
>>
>> to make pulseaudio run as my user.
>
> For what it’s worth: if you have a setup that doesn’t require
> pulseaudio it is possible to use bluez-alsa (running bluealsa as a
> daemon) and configure it to use the a2dp profile. I’m using this on a
> headless “server” in the living room to send music to bluetooth
> speakers.

Ideally I'd like to use pulseaudio as I have multiple streams that I
send to my bluetooth speaker. Nevertheless, I tried to give bluez-alsa a
go but I failed to kill pulseaudio. It would always start back up as the
GDM user.

>
>> [0]: https://wiki.debian.org/BluetoothUser/a2dp#Refused_to_switch_profile_to_a2dp_sink:_Not_connected
>
> The second workaround requires writing a configuration file to the gdm
> user’s home directory. Is this something that we could do in the gdm
> service configuration?

Ideally i'd like to stop GDM running pulseaudio as I can test out your
solution above and it may fix this issue. I'm unsure how to modify GDMs
configuration, however.
-- 
Matt

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2020-01-06 21:25 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-04 13:30 bug#38915: Can't change profile of Bluetooth headphones Matthew Leach
2020-01-04 21:33 ` Ricardo Wurmus
2020-01-05 20:04   ` Matthew Leach
2020-01-05 20:05   ` Matthew Leach

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).