I have a speaker connected with my arduino and an sd card module connected to them to play wav files . When i turn it on the volume is very low and muffled. I tried adding an audio amplifier but it didn't work. Here is the schematic:
Which impedance?
Which Vs?
Which PSU - max. current?
I have an 8 ohm speaker and the amplifier is connected to a 9 volt power supply
What is synthesizing the sound here? The Arduino or some component on the SD card module? Can you post details, please?
Two thoughts come to mind re:muffled sound:
1: The voice coil/speaker itself may not be particularly good at playing high frequencies. What kind of speaker is it?
2: whatever is synthesizing your sound from a digital file may not have a sufficiently high sampling frequency to reproduce higher frequencies.
Note that the output cap of 220uF with an 8R speaker impedance will cut off anything below 90Hz, so low frequencies may be poor as well. Furthermore, the 10K pot on the input of the LM386 together with a possible output cap on the audio source can form an R/C filter that will further cut out low frequencies. But since this affects LF and not HF, I assume this is not the cause for your muffled sound.
There is nothing synthesizing the sound. Only the generic 8 ohm speaker ,the sd card and the amplifier. I tried playing tones on the speaker and it worked well
You have digital data on the SD card, and an analog audio output, so something is doing the D/A conversion.
Note: when the speaker is connected directly to the arduino uno there is sound playing but the volume is low and muffled but when connected to the amplifier there is no sound
Is the amplifier ground connected to the Arduino GND?
No.
You mean that i should connect the positive of the amplifier to the power supply and its ground to the arduino
The positive of the power supply connects to Vs.
The negative of the power supply connects to the amplifier ground.
The GND of the Arduino also connects to the amplifier ground.
What do you mean by Vs
Post a picture of this amplifier you are using
It works but the sound quality is weird
Which Arduino are you using?
Please post clear photographs of the entire circuit as you have built it.
Please also post the sketch/code you are testing with.
This information will help people help you. As you have noticed, if you only provide information in very small bits, a very lengthy and often unsuccessful back-and-forth will ensue that can last for hours or even days.
Please help us help you.
Arduino uno with the TMRpcm library
I can't hear what you are hearing but don't expect high quality audio from that library.
It may be somewhat choppy with noise.
A simple lowpass filter on the Arduino pin may help but don't expect a big improvement.
What voltage power supply do you have connected to the amplifier?