sound capturing


For Arduino addicts only


Previous post on same subject

Understand PlainDAC functions which allow analog signals sampling and PlainFFTfunctions which allow Fast Fourier Transform. Make sure to use the latest versions of these libraries (Check in the download area)

The purpose of the next coming posts is to exemplify the combined use of PlainDACand PlainFFT for acquiring and managing signals. Many applications result from this combination, from the most artistic up to the most scientific ones. The sophistication of these applications is mainly limited by the amount of memory from Arduino: 1 Kb on the ATMEAGA 168 and 2 Kb on the ATMEGA328. The most advanced applications will have to be executed off line on a PC or so after downloading the raw signal. Any way, the aim of this blog is to get to the limits of Arduino, so that we will restrict our applications to the processor’s specifications.

The idea here is to detect one specific tone from ambient noise. As music is played in front of the interface microphone, the user presses a button at a certain time (and tone) so that MicroTUN (this is the corny application’s name, standing for micro tune) will record the actual frequency spectrum. Once the button is released, MicroTUN will listen to the music and turn a status Led ON as soon as it will recognize the reference tone.

Next is a rough description of the process:

Within the setup:

  • Setup the data acquisition parameters
  • Set up the FFT parameters
  • Set up the serial comm. Port (for diagnostics)
  • Set user interface (Button and Led)
  • Within the loop

  • Acquire raw data (10 bits wide ad conversions)
  • Compute FFT
  • Clean up frequency spectrum
  • If the button is pressed, copy the actual spectrum buffer in the reference spectrum buffer
  • Compare actual spectrum to the reference spectrum
  • If the matching is above quality criteria, blink status led
  • So simple!

    In the next posts, I will describe the different steps in more details. This series of posts will end up with the publication of MicroTUN code in the download area.

    Dieser Beitrag wurde unter eLab veröffentlicht. Setze ein Lesezeichen auf den Permalink.

    Ein Kommentar zu “sound capturing

    Kommentar verfassen

    Trage deine Daten unten ein oder klicke ein Icon um dich einzuloggen:

    Du kommentierst mit Deinem Abmelden /  Ändern )

    Google+ Foto

    Du kommentierst mit Deinem Google+-Konto. Abmelden /  Ändern )


    Du kommentierst mit Deinem Twitter-Konto. Abmelden /  Ändern )


    Du kommentierst mit Deinem Facebook-Konto. Abmelden /  Ändern )


    Verbinde mit %s