danjperron / PicoAudioPWM

PWM audio on pico with 8KHz stereo wave file
72 stars 12 forks source link

Any volume control? Or do I just need an amp? #9

Open RYoder97 opened 1 month ago

RYoder97 commented 1 month ago

Great library, thank you. It works with headphones, but when I try to connect alligator clips to an aux cable connected to a speaker it's barely audible. I imagine I need an amplifier for this. But is there any volume control coded into the library itself?

danjperron commented 1 month ago

You need a amplifier! The signal level is fixed!
It's like the old turn table output or a four track cassette player.

B.T.W. a speaker is 8 Ohm and the signal can't give more than +/- 1.5ma so W= i²r then The effective power output from the GPIO after the 1K resistor on a 8 ohm speaker is around ( 0.7 (1.5e-3ma)² 8Ω) = 0.01 milli Watt. So not very audible.

Headphone speaker impedance could be up to 600 ohm so it delivers more power with current provided by the pico GPIO. This is why headphone works.