Pybadge LC internal speaker no sound
Moderators: adafruit_support_bill, adafruit
Please be positive and constructive with your questions and comments.
- blnkjns
- Posts: 963
- Joined: Fri Oct 02, 2020 3:33 am
Pybadge LC internal speaker no sound
Just tried the PRJC Audio Lib on my PyBadge LC for another forum topic, but I could only get sound from an external piezo connected to the A0 and GND pins. The internal one does not give any sound. Do you need to connect some solder pads on the bottom for it to work? The non LC version seems to have a few extra components between the built in speaker and pin A0.
- dastels
- Posts: 15699
- Joined: Tue Oct 20, 2015 3:22 pm
Re: Pybadge LC internal speaker no sound
The only audio circuitry difference should be the external speaker connector. To use the external speaker, the trace labelled "A0" next to the onboard speaker should be cut (disabling the onboard speaker). Check that jumper/trace. If it's been cut, that'd be why you don't get sound from the onboard speaker. You can pick up the amplified A0 output on the square pad (of the two on either side for the cuttable trace) farthest from the edge of the board (i.e. toward the reset button).
Dave
Dave
- blnkjns
- Posts: 963
- Joined: Fri Oct 02, 2020 3:33 am
Re: Pybadge LC internal speaker no sound
The trace is not cut, and the A0 jumper contacts do not have a signal (on neither side).
I do get sound when connecting either the A0 or A1 pin to a piezo.
I do get sound when connecting either the A0 or A1 pin to a piezo.
- dastels
- Posts: 15699
- Joined: Tue Oct 20, 2015 3:22 pm
Re: Pybadge LC internal speaker no sound
Can you post a clear photo of the bottom of the board?
Dave
Dave
- dastels
- Posts: 15699
- Joined: Tue Oct 20, 2015 3:22 pm
Re: Pybadge LC internal speaker no sound
Thanks. Everything looks fine.
Since you say there's no signal, my thought is that you aren't enabling the amplifier. That's done by setting the SAMD51 pin PA27 high.
Dave
Since you say there's no signal, my thought is that you aren't enabling the amplifier. That's done by setting the SAMD51 pin PA27 high.
Dave
- blnkjns
- Posts: 963
- Joined: Fri Oct 02, 2020 3:33 am
Re: Pybadge LC internal speaker no sound
Thanks, that was it. Maybe it should get a place in the speaker section of the guide.
PA27 did not work, but in variants.cpp I fount you can use:
PA27 did not work, but in variants.cpp I fount you can use:
Code: Select all
pinMode(51,HIGH);
digitalWrite(51,HIGH);
Last edited by blnkjns on Mon May 31, 2021 11:43 am, edited 1 time in total.
- dastels
- Posts: 15699
- Joined: Tue Oct 20, 2015 3:22 pm
Re: Pybadge LC internal speaker no sound
I wasn't sure what the Arduino pin number was for that. PA27 is the MCU internal pin number as far as I can tell.
But great news. Have fun with it!
Dave
But great news. Have fun with it!
Dave
Please be positive and constructive with your questions and comments.