Hi, I have a makerverse pam8302 Class D Amplifier but I cannot get the mute button to work. I am having popping noises playing on my speaker as soon as I plug it in. I am using the digitalwrite LOW to mute the pam but becuase of the slight delay between powering on and code execution, there is still a pop sound when power is applied. Is there a way that the pam can be muted without the arduino and then turned on after power is applied to skip the popping sounds.
Hey @Dennis273978
Welcome to the forums.
I use the makerverse amp in my audio projects.
Popping is a really common audio problem and I have a guess as to whatās going on.
To resolve this, there are some brute force methods and some sneaky software methods.
I have some questions because I want to recommend something that will make sense for your project.
- Can I clarify what is connected to the input of the amplifier?
- Is it easy to get a quick picture of your setup?
- By mute button I gather you are talking about the active low Shut-Down pin. Is that right?
- When you say āas soon as I plug it inā does that mean you are plugging in a speaker after the amp is powered on?
Pix
Hi, thanks for replying. I am using a dfrobot mp3 mini player. During the void setup process it will reboot a few times so it creates several popping sounds hence my idea of using an external amp to mute the speaker during this process. There is currently a 2n700 wired to the SD pin but it is providing identical results as too before since it still needs to be pulled low by the arduino. Yes by mute I mean active low shutdown pin. What I mean is as soon as I plug in the usb c cable into the arduino which powers everything else.
Ohhh!
Do you own any ne555 timers? (Or equivelent)
No, unfourtunatly. Would that solve my problem?
Yeah but there are other ways.
Maybe some kind of latch.
We want something that is stable during start up.
I think you meant you had 2n7000 mosfet.
I think thats what I see in the picture.
Do you have more of those?
I have quickly googled a ne555 delay time on switch, would this placed on the vcc line of the makerverse fix my issue, or would it be placed on the SPKR+ line. I do have another 2n700 but thats all. If a ne555 would fix my issue I can quickly duck down to jaycar which is close by and get what ever other parts are needed as well. Could you expand on how that could fix my issue? Thanks!
Sure.
Found you a youtube video.
Im proposing you invert the output (pin 3) of the 555 and pass it into the sd of the amp.
Thatll keep the shutdown HIGH for the bootup of the board and then automatically enable the amp after a few moments.
Would that suit you?
I think this will solve it just a few questions. So the ne555 circuit can be powered off the existing arduino correct? It is essentially acting as a fancy switch for the amp. What do you mean by āinvertingā, is it just instead of using the lamp in the video, using the amp? He mentions using different value capcitors to determine the delay, what is the best way of determining which capacitor to buy? is there a variable option?
Great questions @Dennis273978
I think the best way to answer them is with a diagram.
Iāll log off for the night.
Grampa Pix over here gonna
Tomorrow ill draw up a diagram for a fleible delayed enable circuit.
Hopefully we can get this sorted for ya.
Thanks heaps mate, looking forward to seeing the diagram.
Here is a thread about the same problem. You may want to take a look: Arduino Speaker set-up creating constant popping noise - Audio - Arduino Forum
This is a fun use for a 555 timer that I hadnāt seen before.
I normally include some decoupling capacitors in my projects and am a bit more hand-wavy with the values. Normally just what I have readily available at the time. If you already have some capacitors handy you could have a bit of an experiment.
Thanks Lia but I am not experiencing pops during mp3 playback. The pops I have are from powering the circuit
Thanks jack, I donāt have any but Iām picking up the 555 today and I will pick up some common capacitors, as I understand itās a RC circuit so Resistor x capacitor. I think a pot will be a good adjustable way to change the time so the capacitor value wouldnāt matter that much correct?
Thatās it. You are changing how fast the capacitor charges up changing that resistor value. A larger capacitor will also take longer to charge up.
Diagram
problem weāre solving (as I understand it)
*The āvoid setup()ā function causes popping sounds because devices are a little stop start.
To keep the amplifier inactive during this messy bootup, we need to keep the shutdown pin stable in a LOW state for a bit.
555 bootup
- On boot, this 555 output starts low.
- The capacitor charges and it reaches a threshold.
- At that threshold the 555 output transitions HIGH and there it will remain because the capacitor has no way to discharge.
This is great! We wanted our shutdown to start low, while the void setup()
function runs, and then transition HIGH activating the amp. Now we have something that starts low, waits for a bit, and transition HIGH. We just need to plug the output of the 555 into the shutdown of the amp.
Variable
The potentiometer connected to pin 2 allows you to adjust the bootup time.
If you need longer, you can put in a bigger cap, (or maybe a 1 megaohm pot).
This allows a dynamic period of down time since I imaging your void setup() code will change with your projectās development.
What do you think
Will this work for you?
Pix
This is awesome! Seems like the perfect solution. Iāll pick up the parts tonight and update this thread if it works, for others who might encounter the same issue
Great work Pix!
Hey Pix, Ive wired it up and followed a youtube guide on it to assist me and now its working but opposite. The ne555 allows the pam to play for the variable time I set THEN mutes it indefinitely. I am quite confused as to what to do know. Ive checked the wiring and it looks correct and the same as your graph.