3

TL;DR: My Arduino is injecting a lot of noise into an analogue audio circuit, even when not physically connected.

I'm experimenting with using an Arduino as a low-frequency oscillator in audio circuits (modular synths, guitar effects etc). I'm using an Arduino Uno powered with a USB + mains plug.

As a test I set up a simple circuit -- I don't believe the circuit matters much in this case but I'm including it here anyway:

schematic

simulate this circuit – Schematic created using CircuitLab

The Arduino is set up with one PWM pin supplying 0-5v, varying in a triangle wave (i.e. ramping slowly up, then slowly down again). This is connected to the JFET, which acts as a variable resistor. I have tested the analogue part of the circuit manually and it works as expected.

With the Arduino connected, however, the circuit produces a very loud "squishing" noise that swamps the audio signal passing through it, not unlike someone tuning an old short-wave radio. The noise "squishes" in time to the oscillation of the voltage. It's not unlike the sound in this video associated with the PC power supply: https://youtu.be/lXPJvSU8MwI?t=10m52s.

This happens even if I physically disconnect the PWM pin from the circuit -- the closer its wire is to the circuit, the louder the noise, but it's clearly audible even when they're separated by are a foot or more of air.

Things I've tried:

  • Tying the Arduino ground to the analogue circuit ground, and also keeping them separate.
  • Adding power filtering caps to both circuits.
  • Putting the Arduino in an aluminium box, grounded to either its own ground or the analogue circuit's, or both.
  • Powering the Arduino from my laptop instead of plugged directly into the mains.

The analogue circuit is on breadboard right now so some noise is expected, but this is far outside anything I've experienced before even with very badly-behaved circuits.

I'm FAR from knowledgeable about Arduino so my hope is that I'm doing something stupid and easily fixed. I would happily accept an answer that proposes an entirely different way to achieve the desired result.

helveticat
  • 133
  • 4

1 Answers1

1

Arduino PWM signal is about 500Hz, so it will be audible (read: noise) by itself. You could implement a low-pass filter between the PWM pin and your J-FET. A simple RC filter tuned to 5Hz would attenuate a 500Hz signal to -40dB, which probably won't be enough for high quality audio. There are filters with better rejection properties which usually require active components to build. One of the simplest of such filters is the Sallen-Key topology, which can practically double the rejection ratio using a signle active component (opamp).

Another option is to use a simple RC filter, but increase the the PWM frequency (as described here) to achieve high rejection ratio. Eventually, increasing the frequency past the audible range (about 16kHz) will ultimately resolve the noise problem, though I would still use an RC filter to keep the J-FET in linear mode. Apparently, the highest frequency you can achieve at full resolution is 62.5KHz, which is more than enough.

Dmitry Grigoryev
  • 1,288
  • 11
  • 31