Hi all,
Just downloaded the latest Teensyduino v1.52 beta #2, and I'm trying to get USB output working. I've modified the code below from the PT8211 sine example, and I'm trying to work out how to monitor the output.
1) Should this code work?
2) If so, how can I successfully monitor it? So far I've tried using Logic Pro X, with a channel strip taking Teensy as input and built-in speakers as output.
I'm on MacOS 10.14, with my Teensy 4.0 set to Audio+Serial+MIDI
Thanks for any help.
Cheers,
Matt.
Just downloaded the latest Teensyduino v1.52 beta #2, and I'm trying to get USB output working. I've modified the code below from the PT8211 sine example, and I'm trying to work out how to monitor the output.
1) Should this code work?
2) If so, how can I successfully monitor it? So far I've tried using Logic Pro X, with a channel strip taking Teensy as input and built-in speakers as output.
I'm on MacOS 10.14, with my Teensy 4.0 set to Audio+Serial+MIDI
Code:
#include <Audio.h>
#include <Wire.h>
#include <SPI.h>
#include <SD.h>
#include <SerialFlash.h>
// GUItool: begin automatically generated code
AudioSynthWaveform waveform1; //xy=110,75
AudioOutputUSB usb1; //xy=303,78
AudioConnection patchCord1(waveform1, 0, usb1, 0);
AudioConnection patchCord2(waveform1, 0, usb1, 1);
// GUItool: end automatically generated code
void setup() {
AudioMemory(15);
waveform1.begin(WAVEFORM_SINE);
waveform1.frequency(440);
waveform1.amplitude(0.99);
}
void loop() {
}
Thanks for any help.
Cheers,
Matt.