Forum Rule: Always post complete source code & details to reproduce any issue!
-
-
I was going to suggest you use my Dynamic Audio Objects library, which allows creation or deletion of AudioStream and AudioConnection objects on the fly, but then noticed you're using a Teensy 3.2 and I've only (so far) implemented it for 4.x. I don't have a 3.x to test on, and not much motivation as I don't think anyone else is using it...
Anyway ... would something like this work?

For audio output you set mixer3.gain(0,1.0f), mixer3.gain(1,0.0f), mixer3.gain(2,0.0f); for CV either 0.0, 1.0, 0.0 and call dc2.amplitude() to set the level (a bit crude), or 0.0,0.0,1.0 and queue1.getBuffer() and queue1.playBuffer() to create sample-accurate output at the cost of a bit more processing in your code.
Cheers
Jonathan
-
Thanks for that. I did try the dc option with some success. I didn't think of using a queue, so I'll try that too. There seemed to be some glide in the steps so maybe the queue option will be cleaner.
I'm also a bit confused by the levels. I know what voltage I need to appear on the DAC to get the 1V/octave output from the little amplifier that follows it, but I don't know what the AudioAnalogOutput object does to the incoming signal.
Is it simply an input of 0 maps to 0V, and 1 maps to the analog reference voltage?
I assumed that at first but it wasn't in tune. It was late though and I could easily have muddled something while exploring options. I need to keep plugging into the rack to get the voltages for the op-amp, so there's only so much I can easily test using the computer. :-)
I'll have another go today.
-
Must have been just working too late. :-)
It's all good now - and proving a lot of fun.
I must say I'm very happy with my first use of the T3.2. Small, fast, and with a DAC! Glad to be able to avoid the audio shield for this little project.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules