-
Notifications
You must be signed in to change notification settings - Fork 431
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Using Amplifier and TTL converter at same time #101
Comments
You can use PAM8302 shutdown pin(SD) to one GPIO with a resistor pull-down. GPIO15 for example, must be pulled low anyway to enter uart bootloader or boot from flash. |
Thanks for the solution. I exactly do the same thing. But my problem is something else. I can disable PAM8302 when I use the TTL converter (CP2104), but I can't disable TTL converter (RxD pin) when the amplifier is active. When I cut off the wire to CP2104, the sound is much louder. |
The I2S pins are fixed on the ESP8266, not like the ESP32 where you can move them around a bit. That said, if you are using an I2S DAC then it's a binary, digital signal. Either it makes it into the DAC or not. Loads on the I2S-DOUT pin don't matter as long as the swing from 0->1->0 meets all the Vin(low,high) thresholds. A volume change would indicate that your V(analog) to the DAC/AMP is too low, probably due to the USB -> TTL converter using enough current to drop the voltage presented. If you can, and the amp supports it, using the raw 5V from the USB port, not any regulated 3.3V, for the analog V supply may help. OTW you need a separate power source. |
You could connect a tri state output logic buffer/mux between cp2104 and control it with same pin as Pam shutdown. |
I think a n-mosfet is enough Also a pull-up is needed at esp8266 rx - somewhere around 10k should be enought. The tri-state buffer is better for speed when programming... |
Thanks, you guys are great. I have no ideal about tri state buffer, it’s difficult for me, but I definitely test the Mosfet one. I have to mention the sound level is not bad already but because my device is for outdoor, even a little bit louder is important. |
The n-mosfet solution works beautifully. Just one more thing, is there any complimentary cheap P-Channel for 2N7002. Because then I can switch PAM8302 (SD pin) on when TTL converter is off and vice versa using just one pin. Does this solution work? Thanks |
I am not aware of a generic 2N7002 p-mos complimentary. But it exist many p-mos in SOT23 package. Mos Source - GND It can also be good to have a pull-down on gate to discharge the gate capacitance if the input is free floating. Some example of gates http://pastraiser.com/technology/nmos/basicnmosgates.html |
I use TTL/USB convert and Amplifier (PAM8302) at the same time. It means the RxD is connected to TTL converter and the Amplifier. When I disconnect the TTL connection, the sound volume is amazingly louder and when I add a resistor to limit the current for TTL converter, it stops working. Any idea to fix the problem without adding noise to the audio? Can I add a transistor switch to for TTL converter to trig it with a little bit current?
Thanks for your great lib and perfect support.
The text was updated successfully, but these errors were encountered: