bmillier
Well-known member
I am feeding the SPDIF output (thru the proper electronic circuit) to the Coax SPDIF input of my Moto 828MK3 digital mixer. The output is completely quiet if I am not sending any signal through. However, as soon as I send a high pitched (2500 Hz for example) sine signal through, there is a pronounced, steady clicking noise at a rate of around 3-5 Hz. This doesn't show up at lower frequencies. The problem isn't really apparent if I send out a music file using the SDcard port on the Teensy, but I think the clicks are just being masked by the nature of the music itself.
I thought it was my code but I can reduce the program to just the sinewave audio block feeding directly into the SPDIF output block (2500 Hz amplitude 0.5). It does this on both a T3.2 and T3.5 board. I tried powering the Teensy with a 5V USB adapter (instead of just plugging it into USB socket on the computer) to eliminate any ground loop that might be occurring. This made no difference.
I can 'scope the SPDIF output and see that the waveform is clean and at the right SPDIF amplitude of 500 mv PP, but can't analyse the data using just a scope.
I thought that the SPDIF routines might be getting interfered with by the audio routines running in my program, but this isn't the case as I am now only using one sinewave and SPDIF out blocks for this test.
I assume my Moto 828MK3 SPDIF input is working OK, but I don't have another SPDIF source to try out.
I recorded a sample of this in a .WAV file, but the forum upload routine won't accept it.
Anyone else experienced this? Thanks.
I thought it was my code but I can reduce the program to just the sinewave audio block feeding directly into the SPDIF output block (2500 Hz amplitude 0.5). It does this on both a T3.2 and T3.5 board. I tried powering the Teensy with a 5V USB adapter (instead of just plugging it into USB socket on the computer) to eliminate any ground loop that might be occurring. This made no difference.
I can 'scope the SPDIF output and see that the waveform is clean and at the right SPDIF amplitude of 500 mv PP, but can't analyse the data using just a scope.
I thought that the SPDIF routines might be getting interfered with by the audio routines running in my program, but this isn't the case as I am now only using one sinewave and SPDIF out blocks for this test.
I assume my Moto 828MK3 SPDIF input is working OK, but I don't have another SPDIF source to try out.
I recorded a sample of this in a .WAV file, but the forum upload routine won't accept it.
Anyone else experienced this? Thanks.
Code:
#include <Audio.h>
#include <Wire.h>
#include <SPI.h>
#include <SD.h>
#include <SerialFlash.h>
// GUItool: begin automatically generated code
AudioSynthWaveformSine sine1; //xy=270,276
AudioOutputSPDIF spdif1; //xy=510,278
AudioConnection patchCord1(sine1, 0, spdif1, 0);
AudioConnection patchCord2(sine1, 0, spdif1, 1);
// GUItool: end automatically generated code
void setup() {
// put your setup code here, to run once:
AudioMemory(8);
sine1.amplitude(0.5);
sine1.frequency(2500);
}
void loop() {
// put your main code here, to run repeatedly:
}