i2s2 brings noise into analog inputs T4.0

emmanuel63

Well-known member
Hello,

I can't get rid of noisy analog input when using i2s2 bus (same problem with i2s1 bus)

Here is my test :
I have a single pot hooked on Gnd - 3V3 - A9
I have attached a UDA1334A I2S Stereo DAC. It's working.

When i2s is on, my pot values are very noisy (+- 30).
When i2s is off (I just comment out the lines in my sketch), my pot values are just fine, no noise.
The funny thing : if I unplug my DAC but let some wires connected to teensy, I still have some noise (see photo). So my DAC is not the problem.
I tried with other T4.0, with or without breadboard. Same.

This drives me crazy... Help please !

Emmanuel

Code:
#include <Audio.h>


// GUItool: begin automatically generated code
AudioSynthWaveformModulated waveformMod1;   //xy=223,197
AudioOutputI2S2          i2s2_1;         //xy=427,198
AudioConnection          patchCord1(waveformMod1, 0, i2s2_1, 0);
AudioConnection          patchCord2(waveformMod1, 0, i2s2_1, 1);
// GUItool: end automatically generated code



void setup() {

  AudioMemory(10);
  waveformMod1.begin(0.1, 400, WAVEFORM_SINE);

}

void loop() {
  Serial.println(analogRead(A9));
  delay(50);
}

IMG_20221021_202644_resized_20221021_083129475.jpg
 
Back
Top