Audio Adapter Board r: how to connect SMT Speaker and configure SPI pin for SD card?

Status
Not open for further replies.

tranha

Active member
Hi all

I am new to the Audio Adapter Board and I am using a Teensy 3.2. While waiting for the parts arrive I have some general question:

1. If I want to connect the Audio Board to a SMT Speaker, how can I do that? Am I supposed to connect that speaker to L/G (or R/G) on the Line In pins ?

2. In my project, I just want to simply play a WAV file when a button is pressed. Therefore I looked at the WavFilePlayer example I saw this configuration:

Code:
#define SDCARD_CS_PIN    10
#define SDCARD_MOSI_PIN  7
#define SDCARD_SCK_PIN   14

If I mount the teensy on the Audio Board, must this configuration be fixed? Can I change it to use different pins ?

Thanks
 
Hi all

I am new to the Audio Adapter Board and I am using a Teensy 3.2. While waiting for the parts arrive I have some general question:

1. If I want to connect the Audio Board to a SMT Speaker, how can I do that? Am I supposed to connect that speaker to L/G (or R/G) on the Line In pins ?

2. In my project, I just want to simply play a WAV file when a button is pressed. Therefore I looked at the WavFilePlayer example I saw this configuration:

Code:
#define SDCARD_CS_PIN    10
#define SDCARD_MOSI_PIN  7
#define SDCARD_SCK_PIN   14

If I mount the teensy on the Audio Board, must this configuration be fixed? Can I change it to use different pins ?

Thanks

Those pins are fixed by the hardware. Even if you were to mount the boards off of the Teensy and connect wires to each of the pins, you have no choice for the SCK/MOSI pins, and little choice for the CS pin.

The SCK pin (SPI clock) is normally pin 13, but with the audio shield you have to use the one alternative pin (pin 14). This is because the only pin that can be used for I2S receive is also pin 13.

The MOSI pin (SPI pin for master sending to the slave) is normally pin 11, but with the audio shield you have to use the alternative pin (pin 7). This is because the only pin that supports the I2S MCLK function is pin 11.

Depending on the micro SD drive, the CS pin can be one of 5 pins (or a few alternates for for those):
 
Thanks for you r response!

Then I wonder if the Audio Board would affect my Bluefruit SPI Friend configuration.

Basically I'm also using a Bluefruit SPI Friend for this project and my SPI configurtion for this is:

#define BLUEFRUIT_SPI_CS 6
#define BLUEFRUIT_SPI_IRQ 9
#define BLUEFRUIT_SPI_SCK 13
#define BLUEFRUIT_SPI_MISO 12
#define BLUEFRUIT_SPI_MOSI 11

Do i need to change anything if I want to include both Bluefruit and the Audio Board in the project?
 
Last edited:
You need to use the same pins for MOSI and SCK for both the audio board and the Teensy.

You also must not use the other pins defined by the audio board/i2s (6, 9, 13, 15/A1, 23/A9, 22/A8).

You might be able to use 15/A1 if you don't hook up a potentiometer to the board, but given there are resistors/capacitors for using that as a volume switch, it may be problematical.

You can use the i2c bus (19/A5, 18/A4) as long as your i2c devices use different addresses than the audio board devices (0x0A, 0x1A). The audio board provides i2c pull-ups, so you do not need additional pull-ups.

So you need to change all of the above pins except for the MISO pin (pin 12). If the bluefruit driver has special teensy SPI optimizations, you might need to use one of the two remaining CS pins (20/A6 or 21/A7) that are special CS pins for the Teensy.
 
Last edited:
I plan to de-solder the headphone jack to take it out but then I don't know how to connect a SMT speaker to it
 
I mean I don't want to use the headphone-jack, I already took the jack out so that I can connect any SMT speaker on it but I don't know how to connect.
 
Maybe I am lost here.

When you say SMT speaker, does the speaker have a built in AMP? As far as I know the Audio board output is only headphone jack level, which for a speaker you would need some other AMP to output it to a speaker. Which is different than the Propshield, which has an amp chip on it. Assuming you are going to an AMP, you could probably connect it to the 3 pads you desoldered the jack from.

I know Frank has mentioned on the thread: https://forum.pjrc.com/threads/3798...n-for-T3-6-similar-capabilities-of-Propshield that he has purchased small amps that can be used. My guess is that it would be possible for example to use a couple of the LM48310 that is used on the prop-shield or the one I am using that is mentioned on the above thread and connect up the HPL to one amp and the HPR to the other and HPVGND to both as they are shown in the schematic for the Audio adapter: http://pjrc.com/store/teensy3_audio.html

But again I am not really understanding what it is you may be trying to do.
 
Status
Not open for further replies.
Back
Top