I'm working on building a portable self-playing "box" I can use to add sound effects or ambient noises to an area. I got everything working but I'm getting a ton of noise on the speaker and not really sure what the source is. Am I blowing out the speaker? The in-line potentiometer? Switching power supply?
Any feedback would be appreciated.
Any feedback would be appreciated.
Attachments
Last edited:
Could be anything. You'll have to experiment. Post the schematic.
Does the noise reduce at lower volume control settings?
Can you try running it on batteries or a linear supply?
Does the noise reduce at lower volume control settings?
Can you try running it on batteries or a linear supply?
First disconnect the input to the audio amplifier, and replace with a short. Is there still noise?
Is the voltage regulator isolated? If not, there probably is a ground loop.
Is the voltage regulator isolated? If not, there probably is a ground loop.
Is the voltage regulator isolated? If not, there probably is a ground loop.
I think it is. Right now all the components are sitting on my work bench so it should be isolated.
This is key. That should tell you whether it is the power supply and amp, or the signal generation in the ESP.First disconnect the input to the audio amplifier, and replace with a short. Is there still noise?
Jan
@jan.didden , @rayma , I did some testing like you guys suggested. It looks like the noise is coming from the ESP32 itself. When I shorted the input to the audio amp, it was very silent/clear. I then tried driving the speaker straigh from the ESP32, while super quiet, you could hear the same noise as you could through the amp.
So I guess the question is, is there a way to clean up the noise on the audio coming out of the ESP32?
So I guess the question is, is there a way to clean up the noise on the audio coming out of the ESP32?
Guess I would first try heavily filtering the ESP32 audio output before it gets to the volume control.
That is an 8 bit DAC. The audio quality will be lousy.
Try just before the volume control a series 10k resistor, with a shunt 3.3nF capacitor.
If that does not help enough, you may need to use an I2S DAC instead.
That is an 8 bit DAC. The audio quality will be lousy.
Try just before the volume control a series 10k resistor, with a shunt 3.3nF capacitor.
If that does not help enough, you may need to use an I2S DAC instead.
Would a Aluminum electrolytic capacitor work? I have a box of them at the house like this.shunt 3.3nF capacitor
Not really, it has to be nonpolar at least. Or 2.7nF would also be ok.
Note that these values are in nF, not uF.
Note that these values are in nF, not uF.
Last edited:
I suspect there could be beating between the DAC output sample rate and the TPA3118 class-D clock frequency. What AM0/1/2 settings does the TPA3118 board use and what sample rate is used on the ESP?
@Mark Tillotson , I bypassed the amp (TPA3118) and I was still getting the same noise (at a much lower overall volume). I'm honestly not sure what settings the TPA3118 uses as I just picked it up on Amazon. I'm looking into the default sample rate, I'll let you know.
- Home
- Design & Build
- Electronic Design
- Getting a lot of noise, not sure if I'm blowing out the speaker or something else?