Forum Rule: Always post complete source code & details to reproduce any issue!
Results 1 to 5 of 5

Thread: DSP Noise File Filter

  1. #1
    Junior Member
    Join Date
    Aug 2020
    Posts
    5

    DSP Noise File Filter

    Hi Paul & Everyone,

    Is there a way to capture(record) an audio noise file and use it to remove the same background noise from a communications channel, thereby cleaning the quality and improving the S/N ratio?

    If that capability exists, what is the process?

    Thanks,
    Dave

  2. #2
    Senior Member
    Join Date
    Nov 2012
    Posts
    1,492
    The Goldwave audio editor has a filter which it just calls "Noise Reduction". To use it, you select a small segment of your audio file which contains only the noise and copy this to the clipboard. The filter does an FFT on the clipboard sample to develop a profile of the noise. It then uses this as the basis for a filter which is applied to the whole file. I've only used it a couple of times and didn't find it useful in the cases I was trying. I presume the best results would be obtained when the spectrum of the noise is quite distinct from the signal.
    What "communications channel" are you using?

    Pete

  3. #3
    Junior Member
    Join Date
    Aug 2020
    Posts
    5
    Hi Pete,

    Thank you. With all the work that went into this audio file processor, I thought that someone would have addressed this very common issue.

    Lots of comm's channels have background noise. Aircraft intercom systems, AM radio, or doing a recording with a beating fan in the background. Everything from high freq hiss to an annoying beat that wasn't noticed during the recording (or thought not to be an issue and it turns out to be one).

    I just picked up a couple Teensy 3.2's. Going to grab an audio breakout board, do the workshop and then trying the technique you mentioned. Would be nice if there were some parameters to manipulate the noise file to help it filter.

    Anyway, thanks,
    Dave

  4. #4
    Senior Member
    Join Date
    Oct 2015
    Location
    Vermont, USA
    Posts
    265
    Quote Originally Posted by DaveC284 View Post
    I just picked up a couple Teensy 3.2's. Going to grab an audio breakout board, do the workshop and then trying the technique you mentioned. Would be nice if there were some parameters to manipulate the noise file to help it filter.
    If you're going to try to implement frequency-domain noise reduction, be aware that the Teensy 3.2 will probably not be fast enough to do a round-trip FFT->IFFT in order to do the frequency-domain processing. Even if it is fast enough, it'll be using 16-bit fixed-point math operations, for both the FFT and IFFT. That round trip is going to sound really bad. You loose a lot of effective bit depth with the fixed-point math operations, which greatly reduces your dynamic range (ie, greatly raises the noise flow).

    So, I recommend that you simply code up the FFT -> IFFT round trip with no actual processing. Just hear the results of converting into the frequency domain and then back again. Do the test using a clean signal. You'll learn a ton doing this, but I think that you'll be disappointed with the audio quality.

    To have it sound good, you'll have to do floating-point FFT and IFFT, which are not natively supported by the T3.2. Instead, you'll need the Teensy 3.5 or 3.6. When you make that jump, you can also make the jump to a floating-point version of the Audio library, as offered by a number of folks. My (closely-related) versions are here:

    * Open Audio Library (https://github.com/chipaudette/OpenAudio_ArduinoLibrary)
    * Tympan Library (https://github.com/Tympan/Tympan_Library)

    In these two libraries, you can use these frequency-domain examples as a starting point:

    * Open Audio: https://github.com/chipaudette/OpenA...ssFilter_FD_OA
    * Tympan: https://github.com/Tympan/Tympan_Lib...requencyDomain

    There are probably other floating-point libraries, too.

    Chip

  5. #5
    Junior Member
    Join Date
    Aug 2020
    Posts
    5
    Thank you, Chip. I'm still waiting for the expansion brd to arrive from Tall Dog and will order the Audio Expansion Brd from you folks and begin playing with the 3.2. Lot's of exploration to do.

    Right now, my immediate task is to integrate the Teensy 3.2 where a Nano used to sit. I'm investigating the 74HC125 3.3-to-5V-to-3.3v level translators.

    All the best,
    Thanks,
    Dave

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •