Revela y conserva secretos, reformulándolos para su transmisión. Construye un medio que activa y enfoca la energía sonora. No hay dogma ni géneros aislados. La comunicación depende de la multiplicidad de mensajes en el océano sonoro. La ausencia de fronteras permite la asimilación, el reproceso y la recombinación del sonido hasta obtener nuevos significados. La música se libera del ciclo de producción-comercialización y adopta a la mutación como estructura y forma.

la música es materia el proceso es composición

17/12/18

Arduino Noise Generator

Do you want to make a big noise but don't have much money for gear. Maybe your "sound art" cousin doesn't let you play with his eurorack noise gen he got selling his soul to a government grant. Too bad. I understand you. If have few coins to spare I can teach you how make some harsh, ugly, damaging, digital noise. You can use an Arduino as a noise generator passed through a Low Pass filter with resonance. Think something like Noiseduino or else...

First: I really wanted to write a nasty report like the old metasonix press releases, but even they have cleaned their act so I will stay as civil as possible. Anyway, I only talk to consenting adults. So,  I have to tell you that this project has the real posibilities of damaging your speakers, your gear and your hearing (if you are not careful). So, you've been warned: you are the only responsible of what you do to your gear. Fear not: I will tell you how to stay on the safe corner. And, please: be consensual if you plug this on someone else's gear -this is not your standard"classic tone" fx box. If you don't fully trust someone's inputs don't plug in your junk (more of this later).

Second. If you are a "modular-analog-warmth" guy, some tidy "my-projects-will-survive-me" soldering iron wizard that recoils with the abominatios published here, please show us the way. Publish your designsand tell us the way to do a safe, well behaved, noise generator on the cheap. We will follow your directions. Please use #ABetterNoiseduino tag so we can find your designs.

Now, let me tell you what I did. It was the summer of 1947, we were walking through the desert when... jajaja. Nah...

Parts you need -

Hardware first. I got the following pieces:

  • Arduino UNO. Elegoo copy. Fully compatible, as far as I know. I believe you can use any current Arduino that runs at 17MHz. It depends on the Mozzi library.
  • Three 220k pots. In all the tutorials I've seen they use 10k pots, but 220k were the ones I had, so were the ones I used. Two are to control the LP the other one is to dim the output.
  • 1/4 jack. I want to plug into a self powered speaker and into a Yamaha MagicStomp, so that is what I need for output. You can use a 3.5 jack for direct earphones output but please, always use the dimmer pot at the output.
  • USB cable.
  • i3 PC.
  • male-male dupont patch cables. You can buy these at the same spot you got the Arduino.
  • copper wire. I salvaged the wires from an ethernet cable.
  • One small protoboard. I used this to make the connections between the dupont cables and my components. If you know what you're doing you can make the connections directly to the arduino.
For the software:
  • Win 10. 
  • Elegoo Arduino IDE. Probably I believe I could have used the oficial arduino IDE, but I wanted to follow the maker instructions this time.
  • Mozzi Audio Synthesis Library For Arduino. https://sensorium.github.io/Mozzi/ This is the coolest thing for arduino. This project uses this exclusively.
 Construction -

Set up your IDE:

  • Download Arduino IDE. Install or unpack the IDE. I don't think I installed anything else.
  • Set up Mozzi library. Download a zip file, start Arduino IDE, Sketch -> Include library -> Add ZIP Library.
  • Check if Mozzi is installed. File -> Examples -> Mozzi -> 06.Synthesis -> Brown_Noise_Realtime
Set up your arduino:
  • Mozzi uses pin ~9 for output and you need a way to control the volume of the output: 
  • For the knobs connect two pots following the Mozzi Introductory Tutorial to pins A1 and A2 on the Arduino.
Programming -

  • Connect your arduino to the PC.
  • Start the Arduino IDE.
  • Paste this sketch:
#include < mozziguts.h >
#include < mozzi_rand.h >
#include < lowpassfilter.h >
#define CONTROL_RATE 50
#define FILTER_SHIFT 6

byte knob_1 = 124;
byte knob_2 = 124;
LowPassFilter lpf;

void setup()
{
  startMozzi();
}


void updateControl()
{
  int sensor_value_1 = mozziAnalogRead(1);
  knob_1 = map(sensor_value_1, 0, 1023, 0, 255);
    lpf.setCutoffFreq(knob_1);
  int sensor_value_2 = mozziAnalogRead(2);
  knob_2 = map(sensor_value_2, 0, 1023, 0, 255);
    lpf.setResonance(knob_2);
}


int updateAudio()
{
  static int filtered;
  char whitenoise = rand((byte)255) - 128;
  filtered = filtered - (filtered>>FILTER_SHIFT) + whitenoise;
  int asig = filtered>>3;
asig = lpf.next(asig);
return asig;
}


void loop(){
  audioHook(); // required here

  • Close the loop() loop with the correct bracket. Did you think it would be a copypasta job? You are wrong... jajaja. Check the Brown Noise sketch above if you have problems.
Warnings -

You can use this project as it is on a very controlled setting -if you know what you're doing. If you want to use it in a larger setup I have some warnings to tell you before you fry your gear or your body.

  • If you want to plug something to hear the noise be sure you set your volumes to the minimal setting and be cautious when fiddling the knobs.
  • If you want to connect standard audio gear I would add a coupling capacitor to the output. 
  • The Arduino Uno uses a center-positive plug for DC power. That makes it incompatible with most guitar pedal 9V DC adaptors. If you didn't understood this just use a USB charger to power your device to be on the safe side.
  • Be aware that, if you want to use this as a plataform for further experimentation with pro audio gear, you are responsible for adding the correct isolation, shielding and power that can work fine with you other gear.
  • Stay on the safe side and always check for floating grounds before pluging anything to an unknown amp. The imput might look clean and tidy but can never know if "Filament Bob" made the chasis live with some hack. 
  • Stay safe: plug all your gear to your own power strip, use one of these yellow things to check the outley you plug into and use a multimeter to check if there is AC voltage between your leads and the mixer or amp.