BalenaSound on PI0 W with pHAT - how to configure pHAT?

Hi all,
first time with Balena so patience please :slight_smile:

I just happily finished the BalenaSound tutorial:


everything in logs is ‘green’ :), I can connect with my phone via bluetooth, when I play music I see some (lost) packets flying in the logs, all good BUT when I play music…there’s silence.

I figured that what I need to do is to configure OS to use pHAT (as tutorial suggests but says nothing how to do it).
I looked at this: https://learn.pimoroni.com/tutorial/phat/raspberry-pi-phat-dac-install
But it’s for different OS image(?)
So I attempted to do it manually.
BUT
I can’t create asound.conf in /etc folder on the image (resin rootA) as this partition is ‘read only’.

I have a feeling that I’m going in the right direction but on a wrong path :smiley:

how can I use BalenaSound with pHAT?

Cheers!

Hi @thejacek, I’m not completely familiar with your problem, but I think you would need to follow the pimoroni instructions you have linked to inside your application container (as opposed to on the HostOS as you appear to be operating now). This way you’ll have a read-write root filesystem and the ability to install any additional packages. Ideally, once you have worked out the necessary changes, you would add them to your Dockerfile so that future deploys of your application will benefit.

@thejacek is this blog post any use to you? We talk about using the PHAT DAC down at the bottom of the post: https://www.balena.io/blog/turn-your-old-speakers-or-hi-fi-into-bluetooth-receivers-using-only-a-raspberry-pi/

ng no

thanks a lot @wrboyce.
The blog post you shared had the extra step with two parameters.
I did it and…it didn’t work :smiley: BUT I noticed different errors in the logs and also registered connection with my phone.
I set the ‘enable UART’ parameter which seems to be unrelated but after another restart I can finally hear the music :smiley:
thanks!

Final (?) question: is there some sort of default time-out setting ?
I noticed that from time to time the music stream is paused.
Phone is the same place all the time so it’s not due to lost range.

cheers

Awesome, great to hear that the project works for you now! :smiley: :speaker:

Regarding the time-out, there shouldn’t be any. It’s possible that your phone has any sort of power saving mode that would stop the stream? Or what app are you streaming from? And what does “pause” mean, what do you seen on your phone? Bluetooth ranges are tricky sometimes as well, so wouldn’t completely write that off.

hi @imrehg
I was streaming from Spotfiy on an iphone, by pause I literally mean that the music got paused in Spotfiy :slight_smile: hitting play resumed it.
Anyway the problem seems to went away and I’m another happy user of this setup :wink:
thanks!

1 Like

@thejacek glad to hear that it was worked out! :musical_note: