arduino / arduino/ArduinoCore-API

AudioStream API

Open
#10 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
306
Forks
150
PR merge metrics
No merged PRs in 30d

Description

Hi @PaulStoffregen,

We're exploring adding an AudioStream API to Arduino that extends the current Stream type. The draft interface can be found here: [api/Audio/AudioStream.h](https://github.com/arduino/ArduinoCore-API/blob/master/api/Audio/AudioStream.h). We would appreciate any feedback you have on it.

We've taken a look at the Teensy Core's [AudioStream type](https://github.com/PaulStoffregen/cores/blob/master/teensy3/AudioStream.h) and noticed it doesn't have any public interfaces to access the raw sample data. Was this done for performance reasons?

Uses cases we are thinking about include:
- [reading a file from SD card and playing back via I2S or DAC](https://github.com/arduino/ArduinoCore-API/blob/master/api/Audio/examples/WaveToI2S/WaveToI2S.ino)
- [reading data from a I2S or ADC microphone and saving to SD card](https://github.com/arduino/ArduinoCore-API/blob/master/api/Audio/examples/I2SToWave/I2SToWave.ino)

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reading api/Audio/AudioStream.h and the Audio examples WaveToI2S/WaveToI2S.ino and I2SToWave/I2SToWave.ino, then compare the linked Teensy AudioStream type. The issue asks for feedback on a draft interface and the reasons behind an existing design, so completion would require an agreed API direction rather than a clearly defined code change.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
api, audio-video-rtc, embedded-iot
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.