Undosa is a Rust library that provides waveform synthesis for no_std environments meant for eventual ouput over I2S.
let generator = SawtoothWaveGenerator::new(44800, 440)
.quantize(tempo, note_duration, detachment)
.envelope(attack, decay, sustain, release);
let sample_0: i16 = generator.next().unwrap();
Setup:
- STM32F4 Discovery Board
- PCM5102 I2S Board
- 48K Sample Rate, 16 bit audio