Teensy Audio — Overview
The single largest module family in NodeBlue is the Audio library — over 70 modules wrapping the Teensy Audio Library, Paul Stoffregen's exceptional real-time audio framework for Teensy 3.x / 4.x boards. With it you can build effects pedals, polyphonic synthesisers, multichannel mixers, audio analysers and full-blown DSP processors entirely on a USB-powered board.
This page is an overview — what's in the family, what each sub-group does, where to start. Each module deserves its own deep dive that this batch can't fit; the goal here is to make the lay of the land clear.
Hardware prerequisites
The Teensy Audio Library runs on Teensy boards only — concretely Teensy 3.2 / 3.5 / 3.6 (older, still supported) and Teensy 4.0 / 4.1 (current). Audio I/O typically goes through one of the supported codec shields / breakouts:
| Codec / hardware | Notes |
|---|---|
| SGTL5000 (Teensy Audio Shield) | The most common — small breakout that mates with Teensy 3.x or 4.x. Stereo line in / out, headphone amp. |
| CS42448 | 8 in / 6 out (or 6 in / 8 out) multichannel codec — used for surround-sound work. |
| WM8731, AK4558, CS4272 | Other studio-grade codecs supported by the library. |
Boards without these (Arduino, SAMD21, nRF52) can't run the Teensy audio library — pick a Teensy and a codec board.
The seven families
The audio modules group into seven logical families. The category name in the palette starts with the family name so they're easy to scan:
| Family | Category prefix | Examples | What it does |
|---|---|---|---|
| Input | AudioInput-* | I²S, USB, ADC, analog | Audio coming into the board from a microphone, line-in, USB host, ADC, etc. |
| Output | AudioOutput-* | I²S, USB, DAC, PWM | Audio going out to the codec, USB host, internal DAC, PWM. |
| Synth | AudioSynth-* | Waveform, Sine, NoiseWhite, KarplusStrong, Wavetable | Sound-generating sources (oscillators, noise, plucked strings, sample-based synths). |
| Effect | AudioEffect-* | Reverb, Chorus, Flange, Delay, Bitcrusher, Envelope, Fade, Granular | Process audio — modulation, time-based effects, dynamics, distortion. |
| Mixer | AudioMixer-* | 4-channel mixer | Combine several audio streams into one, with per-input gain. |
| Analyze | AudioAnalyze-* | RMS, Peak, FFT256, FFT1024, NoteFrequency, ToneDetect | Inspect a signal — peak level, RMS, spectrum, dominant note, specific-tone presence. |
| Control | AudioControl-* | SGTL5000, CS42448, WM8731 | Configure the codec chip itself (volume, input selection, line gain). |
| Play / Record | AudioPlay-*, AudioRecord-* | SD card playback, raw recording | Streaming from / to storage (SD card, memory). |
Signal flow
An audio NodeBlue project always has at least one Input or Synth (something producing samples) and at least one Output (somewhere to send them). Everything in between is optional shaping — Mixers, Effects, Analyzers.
A minimal example:
AudioSynthWaveformSine (oscillator at 440 Hz) → AudioOutputI2S (route to the codec) → headphones.
A guitar pedal-ish example:
AudioInputI2S (mic / line in from the codec) → AudioEffectBitcrusher → AudioEffectFreeverbStereo → AudioOutputI2S.
The patches you build with these modules look identical in shape to the GUI Patcher distributed by Teensy — same blocks, same wires, same DAC under the hood — except they live alongside the rest of your NodeBlue project (control logic, MIDI, NRF24, dashboard) on a single canvas, not in two parallel tools.
Codec configuration
The codec is a separate chip from the audio path; it needs its own configuration block. Drop in the matching AudioControl module (e.g. AudioControlSGTL5000 for the Teensy Audio Shield) and set:
| Parameter | Effect |
|---|---|
| Input source | LINE_IN or MIC. |
| Mic gain / line level | Analog input gain (some codecs have a per-input PGA). |
| HP volume | Headphone output level. |
| Line volume | Line output level. |
You only need one control module per codec — every AudioInput / AudioOutput module that talks to that codec uses its current settings.
A handful of practical patches to crib
- AudioTest — basic sine → output sanity check.
- Test_2ch_PassThru — stereo input straight to stereo output (gain stage / cable test).
- Test_6ch_PassThru — same but multi-channel (CS42448 codec).
- USB_DC_Filter_Out — USB audio in → DC-blocking filter → output.
- AudioNodeBlue — a richer NodeBlue + Audio combined project.
Further reading
The Teensy Audio Library has excellent first-party documentation at pjrc.com/teensy/td_libs_Audio.html, including a per-module reference. NodeBlue's modules wrap that library directly, so the underlying behaviour and tuning notes there apply verbatim to the NodeBlue versions — only the visual presentation changes.
From here the tutorials branch into the user-facing peripheral families: HID devices (keyboards, gamepads, joysticks), Motors and motor drivers, and Sim-racing wheels. SimHub integration and the FFB engine — also large, deep topics — have dedicated tutorials still to come.