I am having trouble getting pygame to stream audio to a Bluetooth speaker using bluealsa, other programs such as aplay and mpd work completely fine however when initialising pygame's mixer it will usually throw an error being:
pygame.error: Couldn't set hardware audio parameters: Success
Following this any other programs attempting to play audio will break. The output of aplay:
aplay: set_params:1403: Unable to install hw params:
ACCESS: RW_INTERLEAVED
FORMAT: S16_LE
SUBFORMAT: STD
SAMPLE_BITS: 16
FRAME_BITS: 32
CHANNELS: 2
RATE: 44100
PERIOD_TIME: [85333 85334)
PERIOD_SIZE: (3763 3764)
PERIOD_BYTES: (15052 15056)
PERIODS: (5 6)
BUFFER_TIME: (511882 511883)
BUFFER_SIZE: 22574
BUFFER_BYTES: 90296
TICK_TIME: 0
asound config:
defaults.bluealsa.service "org.bluealsa"
defaults.bluealsa.device "00:11:67:11:14:7A"
defaults.bluealsa.profile "a2dp"
defaults.bluealsa.delay 10000
pcm.!default bluealsa
ctl.!default bluealsa
I'm hoping someone will a little more knowledge about bluealsa might be able to help.
*I have already seen the article on the Raspberry Pi exchange however it doesn't provide any answers an is quite a few years old
** This has also been posted on the unix / linux exchange
Thanks in advance.