#include <Audio.h>
// GUItool: begin automatically generated code
AudioInputUSBOct usb_oct1; //xy=189,160
AudioOutputTDM tdm1; //xy=508,157
AudioConnection patchCord1(usb_oct1, 0, tdm1, 0);
AudioConnection patchCord2(usb_oct1, 1, tdm1, 2);
AudioConnection patchCord3(usb_oct1, 2, tdm1, 4);
AudioConnection patchCord4(usb_oct1, 3, tdm1, 6);
AudioConnection patchCord5(usb_oct1, 4, tdm1, 8);
AudioConnection patchCord6(usb_oct1, 5, tdm1, 10);
AudioConnection patchCord7(usb_oct1, 6, tdm1, 12);
AudioConnection patchCord8(usb_oct1, 7, tdm1, 14);
AudioControlCS42448 cs42448_1; //xy=337,337
// GUItool: end automatically generated code
void setup() {
AudioMemory(200);
Serial.begin(9600);
}
void loop() {
}
if (cs42448_1.enable() && cs42448_1.volume(0.8)) {
Serial.println("configured CS42448_1");
} else {
Serial.println("failed to config CS42448_1");
}
Not sure what you intended to say here, but you definitely should make sure you have the latest version.Also I don't think I should downloaded the latest repo from alex since it worked for all you guys.
sorry I re-edited my question.Works for me, here, on Windows 11, with a version of your sketch from post #127 modified to initialise the CS42448 properly. I played back an 8-channel WAV file using GoldWave, and got the expected outputs. Your screenshot is very pretty, but the actual code you ran would be more useful.
Not sure what you intended to say here, but you definitely should make sure you have the latest version.
Yeah, so far so good, tried on a couple different Macs and it's all working perfectly!Haven't checked your video: don't think it was part of the original post, and in any case I don't do Instagram so no way of seeing it. To be honest, apart from confirming that you have an issue, it's unlikely that it would help resolve things.
I've never run the plotter test before, but I tried that, too, just in case. That works for me, as well.
If you can, it would be good for you to try on a Windows PC (I said Windows 11 but since edited it to 10; either should be fine). If that works then there's something about your Mac environment that's at issue, but whether it's OS settings or something needs fixing in @alex6679's code, I couldn't say. We do have one Mac user (@toyosm) who I believe has it working OK.
#include <Audio.h>
#include <Wire.h>
#include <SPI.h>
#include <SD.h>
#include <SerialFlash.h>
// GUItool: begin automatically generated code
AudioSynthWaveformSine sine2; //xy=87,87
AudioSynthWaveformSine sine1; //xy=89,45
AudioSynthWaveformSine sine3; //xy=89,126
AudioSynthWaveformSine sine4; //xy=90,166
AudioSynthWaveformSine sine5; //xy=93,207
AudioSynthWaveformSine sine6; //xy=95,248
AudioSynthWaveformSine sine8; //xy=97,333
AudioSynthWaveformSine sine7; //xy=99,292
AudioOutputUSBOct usb_oct2; //xy=328,165
AudioConnection patchCord1(sine2, 0, usb_oct2, 1);
AudioConnection patchCord2(sine1, 0, usb_oct2, 0);
AudioConnection patchCord3(sine3, 0, usb_oct2, 2);
AudioConnection patchCord4(sine4, 0, usb_oct2, 3);
AudioConnection patchCord5(sine5, 0, usb_oct2, 4);
AudioConnection patchCord6(sine6, 0, usb_oct2, 5);
AudioConnection patchCord7(sine8, 0, usb_oct2, 7);
AudioConnection patchCord8(sine7, 0, usb_oct2, 6);
AudioControlCS42448 cs42448_1; //xy=334,306
// GUItool: end automatically generated code
void setup()
{
AudioMemory(1000);
if (cs42448_1.enable() && cs42448_1.volume(0.8)) {
Serial.println("configured CS42448_1");
} else {
Serial.println("failed to config CS42448_1");
}
sine1.frequency(1200);
sine1.amplitude(0.3);
sine2.frequency(1200);
sine2.amplitude(0.3);
sine3.frequency(500);
sine3.amplitude(0.3);
sine4.frequency(600);
sine4.amplitude(0.3);
sine5.frequency(800);
sine5.amplitude(0.3);
sine6.frequency(1100);
sine6.amplitude(0.3);
sine7.frequency(1300);
sine7.amplitude(0.3);
sine8.frequency(1500);
sine8.amplitude(0.3);
}
void loop()
{
}
//activate one of the four options
//#define PLOT_SIGNAL //use Arduino Serial Plotter -> comment out this line
//#define PLOT_BUFFER //use Arduino Serial Plotter
//#define PLOT_REQUEST_FRREQ //use Arduino Serial Plotter
#define PRINT_USBINPUT_STATUS //prints information like number of buffer over and underruns -> activate this line
AudioOutputTDM tdm1; //xy=524,345
buffer overrun: 0
buffer underruns: 142
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.19
buffer overrun: 0
buffer underruns: 143
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.39
buffer overrun: 0
buffer underruns: 143
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 0
bInterval [uS] : 500
buffered samples (smooth): 78.47
buffer overrun: 0
buffer underruns: 144
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 0
bInterval [uS] : 500
buffered samples (smooth): 78.57
buffer overrun: 0
buffer underruns: 146
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 0
bInterval [uS] : 500
buffered samples (smooth): 116.68
buffer overrun: 0
buffer underruns: 147
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 77.81
buffer overrun: 0
buffer underruns: 149
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 77.33
buffer overrun: 0
buffer underruns: 150
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.51
buffer overrun: 0
buffer underruns: 152
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.06
buffer overrun: 0
buffer underruns: 153
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.26
buffer overrun: 0
buffer underruns: 155
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.43
buffer overrun: 0
buffer underruns: 157
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.95
buffer overrun: 0
buffer underruns: 159
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.19
buffer overrun: 0
buffer underruns: 161
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 77.69
buffer overrun: 0
buffer underruns: 162
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.87
buffer overrun: 0
buffer underruns: 164
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.38
buffer overrun: 0
buffer underruns: 166
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 77.54
buffer overrun: 0
buffer underruns: 167
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 79.10
buffer overrun: 0
buffer underruns: 168
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.27
buffer overrun: 0
buffer underruns: 169
memory underruns: 0
buffer target number of samples : 79.38
number of transmitted channels : 8
size of ring buffer : 3
size of usb receive and transmit buffers : 576
currently receiving data : 1
bInterval [uS] : 500
buffered samples (smooth): 78.86
#include <Audio.h>
#include <Wire.h>
#include <SPI.h>
#include <SD.h>
#include <SerialFlash.h>
// GUItool: begin automatically generated code
AudioInputUSBOct usb_oct1; //xy=348,409
AudioOutputTDM tdm1; //xy=671,411
AudioConnection patchCord1(usb_oct1, 0, tdm1, 0);
AudioConnection patchCord2(usb_oct1, 1, tdm1, 2);
AudioControlCS42448 cs42448_1; //xy=369,601
// GUItool: end automatically generated code
void setup() {
AudioMemory(200);
if (cs42448_1.enable() && cs42448_1.volume(0.8)) {
Serial.println("configured CS42448_1");
} else {
Serial.println("failed to config CS42448_1");
}}
void loop() {
}
74.00 77.43
59.00 77.36
15.00 102.25
59.00 79.08
69.00 78.90
79.00 78.73
67.00 78.61
77.00 78.43
15.00 122.96
75.00 78.16
59.00 78.33
69.00 78.17
79.00 77.98
64.00 78.12
64.00 78.12
44100.0508
44100.0117
44100.0195
44100.0313
44100.0703
44100.0000
44100.0820
44100.0898
44100.0977
44100.1055
44100.0000
44100.0000
44100.0273
44100.0313
44100.0430
44100.0352
44100.0430
44100.0547
44100.0625
44100.0703
44100.0000
44100.0273
44100.0352
44100.0469