title: Arduino whooping siren sound
body: <p>I am trying to make an alarm system using Arduino. I would like to have the siren connected to the system be able to output two different types of sounds. A low "beep beep" kind of sound which I know how to do, but I can't figure out how to get the Arduino to emit a "whoop whoop" sound using the tone command or a variant of the tone command or a similar command.</p>
  
  <p>Also on this topic, how would I go about driving a higher power siren/horn using an Arduino? Can I do so using a mosfet transistor the same way I would drive a 12v led?</p>
  
  <p>Any help is greatly appreciated. Thanks :-)</p>
  
  <p>EDIT:</p>
  
  <p>This is my main loop that emits the noise:</p>
  
  <pre><code>void loop() {
    int i = 200; // The starting pitch
    while(i &lt; 800) {
      i++;
      tone(buzzer, i); // Emit the noise
      delay(5);
    }
    delay(100); // A short break in between each whoop
  }
  </code></pre>
  
  <p>Every time the noise emits it make a few (about 3-4) small 'crackles', like distortion. Its not really noticeable with a small piezo directly connected to the Arduino but I suspect when I use a larger sounder and an amplifier it will be more noticeable. </p>