skip navigational linksPJRC
Shopping Cart Checkout Shipping Cost Download Website
Home Products Teensy Blog Forum
You are here: PJRC Store Teensy 32 bit Audio Adaptor

PJRC Store
Full Product List
Teensy 32 bit
Teensy 8 bit
MP3 Player
8051 Dev Board
Payment Options
Privacy Policy

Audio Adaptor Board for Teensy 3.0 - 3.6

TEENSY3_AUDIO Audio board for use with Teensy 3.0 and 3.1 $14.25

Inventory Status:In Stock
Last physical count:Sep 12, 2017

This audio adaptor lets you easily add high quality 16 bit, 44.1 kHz sample rate (CD quality) audio to your projects with Teensy 3.0, 3.1, 3.2, 3.5 or 3.6. It supports stereo headphone and stereo line-level output, and also stereo line-level input or mono microphone input.

The Teensy Audio Library lets you use the input and output simultaneously together with a toolkit of audio processing objects, to easily create all types of sophisticated audio applications. You can play multiple sound files, create synthesized waveforms, apply effects, mix multiple streams and output high quality audio to the headphones or line out pins.

Teensy 3.x have the Cortex-M4 DSP instructions which provide plenty of computational power for real-time FFT (spectrum analysis), opening up the possibility of creating advanced sound-reactive projects.

Two of these 14x1 pins can be used to easily soolder the Teensy 3.x and audio board together.

A 14 pin socket and 14 pin header can be used to make them plug together.

An optional Thumbwheel Potentiometer can be added for volume or control an audio parameter.

FunctionTeensy Pins UsedShareable
Audio9, 11, 13, 18, 19, 22, 2318, 19 (other I2C chips)
Volume Pot15 (A1)-
SD Card7, 10, 12, 147, 12, 14 (other SPI chips)
Memory Chip6, 7, 12, 147, 12, 14 (other SPI chips)

Front SideBack Side

Mechanical drawing and Eagle library.
Estimated power consumption.

Optional Add-Ons

This photo shows a Teensy 3.1 soldered under the audio adaptor using two 14x1 pins.

The optional volume knob and line in/out header are also added.

Signals to Teensy

The audio chip, part number SGTL5000, connects to Teensy using 7 signals. The I2C pins SDA and SCL are used to control the chip and adjust parameters. Audio data uses I2S signals, TX (to headphones and/or line out) and RX (from line in or mic), and 3 clocks, LRCLK (44.1 kHz), BCLK (1.41 MHz) and MCLK (11.29 MHz). All 3 clocks are created by Teensy3. The SGTL5000 operates in "slave mode", where all its clock pins are inputs.

The SD socket is accessed with 4 SPI pins. SCLK and MOSI are used at alternate locatoins. See the audio library examples for details on how to select these different pins. The SD card is useful for playing music. Sandisk and other good quality SD cards are capable of playing 2 WAV files simultaneously.

Wires for MCLK, BCLK, LRCLK, TX & RX should be kept short. The audio shield is meant to connect to Teensy through short pins. Wires can be used, but wires must be short to avoid problems.

FunctionTeensy Pins UsedShareable
Audio9, 11, 13, 18, 19, 22, 2318, 19 (other I2C chips)
Volume Pot15 (A1)-
SD Card7, 10, 12, 147, 12, 14 (other SPI chips)
Memory Chip6, 7, 12, 147, 12, 14 (other SPI chips)

The line in/out header uses a pinout compatible with the AC97 audio header on PC motherboards. The front panel cables from most PCs can be connected, or wires can be soldered directly to the pins.

Schematic, Version 2

In January 2015, small improvements were added. The 1.0 µF capacitors were increased to 2.2 µF, to improve performance for sub-audible and extremely deep base sounds. 10K pullup resistors were added to pins 6 and 10.

Solder pads were added to the I2S transmit and receive lines, and the I2C address configuration pin. Teensy 3.1 & 3.2 are theoretically capable of quad channel I2S audio. These pads are intended to allow a second audio board to be used, for 4 channel audio input and output! (TODO: 4 channel support has not yet been tested with Teensy 3.5 or 3.6)

Update: the Teensy Audio Library now supports quad channel output. For details, see File > Examples > Audio > HardwareTesting > SGTL5000 > QuadChannelOutput.

Sparkfun has great wiring instructions for 4 channel audio.

Schematic, Version 1

Optional Memory Chip(s)

An W25Q128FV flash memory chip may be added on the bottom side. The Teensy Audio Library can play audio clips from this memory, using the SerialFlash library. This flash memory has much lower access latency than SD cards, which allows many sounds to be played simultaneously.

Future versions of the audio library may also use this low latency flash memory for wavetable synthesis.

Alteratively, a 23LC1024 RAM memory chip may be added. The Teensy Audio Library can use the RAM chip for a multi-tap delay line, up to 1.5 seconds. See this demo video for details.

Recommended SD Card

Most SD cards are optimized for sequential access, where a camera or camcorder reads or writes a single large file. All SD cards work well for playing a single WAV file at a time.

For simultaneous playing of 2, 3 or 4 stereo WAV files, many common "class 10" cards perform poorly. Even though they can support many megabytes per second in sequential access, they have high latency for non-sequential access.

PJRC has tested several brands of SD cards. We recommend SanDisk Ultra for projects where multiple WAV files will be played at the same time. SanDisk Ultra is more expensive, but its non-sequential speed is much faster.

The Arduino SD library supports up to 32 GB size. Do not use 64 & 128 GB cards.

The audio library includes a simple benchmark to test SD cards. Open it from File > Examples > Audio > HardwareTesting > SdCardTest.

Front SideBack Side