Speaker phat, loud clicks and removing the alsa driver

speaker phat, loud clicks and removing the alsa driver

I noticed someone else posted about the loud clicks on sound start, as i am using the device for small sound bursts (from espeak) this is very annoying. odd thing is it does not always do it, any resolution to this?

Also I do not want the ALSA meter plug in how do I remove it? is it enough to just remove the alsaconf config section and leave the library in place.

in response to your second question, yes, taking the asound.conf file will disable the VU meter. However it plays no small part in minimising the clicks and pops and would need to be replaced with a suitable substitute.

Unfortunately, I think that you will likely find that, while annoying, the espeak bursts are as minimal as they will be, and without the asound.conf will become unbearable.

I simply don’t think the speaker can take the frequency changes that espeak produce, by nature of speech synthesis. You could try to substitute it with a larger cone speaker that would be less stressed by the constant frequency changes, but of course that would mean a less compact set up.

the problem is the click on startup, same click occurs if I use aplay to play a .wav file, on the other topic 14 days ago it was stated by gadgetoid it was a hardware problem and you were looking into it. sounds like it may be an oversight in the circuit design of the phat. It sounds like you need to keep the clock running on the phat because if I generate a long silence wav file and set that playing in background, that keeps dac clock running, and then in parrallel I use espeak I do not get any clicks any more. But not really an acceptable solution as it is draining cpu resources playing the silence wave file in the background.


removing the vu meter settings from /etc/asound.conf does not remove the click nor does it make it worse, that was not why I wanted to remover the vu meter, that was because I want to control the leds myself.

pHAT BEAT and pHAT DAC are completely different beasts. As noted in that topic, the issue is as much with the I2S clock starting and stopping as it is with the susceptibility of the cone having a fit under a voltage change/stress.

Technically, I think it is possible to keep the stream open constantly, such as your workaround. There are ‘tricks’ using pulseaudio too that can help I believe, but ultimately, keeping a speaker under constant voltage will result in damage.

So, yes, we’re looking into possible solution, but it is a balancing act. My view is that for espeak use an external speaker and a custom asound (dmix properly configured most notably) is a must. YMMV.

did you not read that I am talking about the speaker phat.

The reason I bought the speaker phat was so it runs low power. and so you do not need to waste time setting up your own speaker system and powered external amp.

But the click on audio start up is not acceptable.

the speaker phat would be ok for espeak if it did not go click on startup of sound near every time which is a problem with your design. (to be honest I cannot see the speaker phat as useful for anything but a short sound notifier, the sound quality is abysmal for general audio use.)

what I would consider acceptable is either a fix within 7 days (21 days since first reported) or when you redo this board properly a replacement board that does not go click on startup.

1 Like

there is no need being aggressive - it’s entirely your right to be disatisfied with the product. In which case you should contact sales/support and request a refund.

ah! the old “no need to be aggressive!” response eh! I considered being aggressive after your bullshit then toned it down…

I tried masking the click with a bell sound via aplay which kind of works but aplay locks after intermittent amounts of uses…

but aplay on standard pi works reliably ok. so perhaps a driver problem?

one question, what are the pinouts that require soldering (though that is a brilliant supply method… in bits so immediately must be your soldering that is the problem eh!)

I wanted (obviously) pass through of not used pins to use the pi further.

1 Like

There is no need for that language around here. This is a place for constructive feedback and for support. If you would like support then please ask for it in a constructive manner. If you just want to rant this is not the place for you.

the pinout of the board and more information is here https://pinout.xyz/pinout/speaker_phat

1 Like

oh! we are on to the “no need for that language round here” response eh! escalate escalate!

what kind of language do you think pirates used? when it seems you use the blackest of passive aggressive magic wordage eh!

by the way “pi2003” I was asking an “authority” on the question for what the 'k it is worth, of course I have seen that page and soldered up all those pins and a few ground pins for good measure!

If you have seen the pinout page would you be able to develop your question so we may be able to better help you?

1 Like

@skypi - I understand your frustrations, but as far as I can tell @RogueM has simply tried to help.

At no point have we called your soldering into question- did you contact support and receive such a response from them? It’s certainly a pretty standard thing to point out, since we see a lot of issues caused by soldering. Please don’t take offence- front-line support has to be pretty terse and try the common things first, or myself and the engineers at Pimoroni would never get any work done.

As it happens we almost always replace products damaged by poor soldering, I’ve even hand-soldered the odd board myself to send out to a customer. We most certainly don’t ship boards unassembled so we can “blame problems on the soldering”. It’s to keep the cost of the pHAT form-factor low and give people the flexibility to stack, or use right-angled headers as they see fit.

As far as I’m aware, the canonical solution for keeping the i2s clock running is to use Pulse Audio to keep the audio device open.

I was investigating a kernel level solution to soften the blow of the i2s clock stop/start, but this wont be a fix that happens soon, or perhaps even at all, because it involves a lot of things that I presently do not understand.

1 Like

don’t get me wrong, I’m just being sarcastic… (highest form of wit is it?) but… as surely you can see as I posted actual what kind-of fixed it but didn’t really as the whole aplay failing thing seems to point to drivers?

1 Like

can you tell me you have a speaker phat wired up and when you do the command espeak “blah blah blah” it does not go CLICK blah blah blah, if you can then I am wrong!

delete this thread, I do not want anything reflecting badly on you guys, I appreciate these things can be unforeseen, I will post another thread after I have done a reinstall of jessie lite and manually installed the driver. If aplay works reliably then I think the bell sound to mask the click will work.

I’m certainly going to try a setup with Pulse Audio and see if I can get it up and running. I have a lot to juggle, though, which is why this stuff doesn’t happen as quickly as I’d like.

I don’t see this reflecting badly upon us, and loathe to remove any discussion lest someone else who’s frustrated with the clicking drops by here and tries to find solidarity.

We’ll figure it out!

yeah looks like pulseaudio will work for me, it is runnable headless and also includes a ducking module which is useful.

I can confirm installing pulse audio and in /etc/pulse/default.pa commenting out the module

load-module module-suspend-on-idle

cures the click on speaker hat, but pulse audio sits using 1-2% cpu on a pi zero when idle

aplay works OK however cant figure out why the following command does not work

pacmd play-file test.wav 0

no error, just does not play the file.


The pacmd problem stumped me at first, but it seems to require an absolute path to the file.


pacmd play-file "$(pwd)/test.wav" 0

I too am also getting loud clicks and random clicks, was this ever resolved?

Thank you in advance