Sharing Pins- Audio Adapter Shield- and Wi Fi Breakbreakout

Hello, can I share Teensy 3.2 pins- (11 & 12) on my between the audio adaptor board https://www.pjrc.com/store/teensy3_audio.html and wifi breakout https://learn.adafruit.com/adafruit-atwinc1500-wifi-module-breakout/pinouts ?

Thank you! Sanone
You need to use the alternate SPI pins for pins 11 and 13. The alternate pin for 11 (MOSI) is pin 7. The alternate pin for 13 (SCLK) is pin 14. The audio board needs to use pins 11 and 13 for I2S objects, instead of them being used as the default pins for SPI:

Note, some boards don't work too well being shared with other SPI devices like the SD card and flash memory readers on the audio shield. I've heard that for those boards, you need to have additional hardware (tri-state buffer?). Also, if the wifi driver doesn't have support for SPI_TRANSACTIONS, you may need to add that as well.
 
You need to use the alternate SPI pins for pins 11 and 13. The alternate pin for 11 (MOSI) is pin 7. The alternate pin for 13 (SCLK) is pin 14. The audio board needs to use pins 11 and 13 for I2S objects, instead of them being used as the default pins for SPI:

Note, some boards don't work too well being shared with other SPI devices like the SD card and flash memory readers on the audio shield. I've heard that for those boards, you need to have additional hardware (tri-state buffer?). Also, if the wifi driver doesn't have support for SPI_TRANSACTIONS, you may need to add that as well.

Thank you Michael, I will try this and let you know.
 
Open any of the Audio library examples which use the SD card, like File > Examples > Audio > WavFilePlayer.

You'll see these 2 lines.

Code:
  SPI.setMOSI(SDCARD_MOSI_PIN);
  SPI.setSCK(SDCARD_SCK_PIN);

You need these in setup(), before you do anything with SPI. These configure which pins will be used for SPI.

Then connect to pins 7, 12, 14 for MOSI, MISO, SCK. Connect the other signals to any unused pins. Avoid using the pins the audio shield needs for I2C and I2S digital audio.
 
Open any of the Audio library examples which use the SD card, like File > Examples > Audio > WavFilePlayer.

You'll see these 2 lines.

Code:
  SPI.setMOSI(SDCARD_MOSI_PIN);
  SPI.setSCK(SDCARD_SCK_PIN);

You need these in setup(), before you do anything with SPI. These configure which pins will be used for SPI.

Then connect to pins 7, 12, 14 for MOSI, MISO, SCK. Connect the other signals to any unused pins. Avoid using the pins the audio shield needs for I2C and I2S digital audio.

Thank you, In your docs in addition to the 2 I2C pins you have the audio chip using 9,11,13,22,23, if I'm understanding correctly I can use any free digital pins to replace any of those? And similarly Can 10 for the SD card and 6 for the memory chip be swapped out with any other digital pins?
 
Back
Top