Digital Bandpass Filter

Post details of your projects here.
Post Reply
danlee58
Posts: 210
Joined: Thu Jan 17, 2013 2:29 am

Digital Bandpass Filter

Post by danlee58 » Wed Sep 07, 2016 12:56 am

I need a digital bandpass filter. There is a single channel input signal of ~5.6kHz embedded in noise. I want to filter the noise & amplify the signal. When the signal amplitude exceeds a threshold, I'll set an output bit.

I need a good A/D converter & reasonable sampling rate to prevent aliasing. Most of all I am looking for some 'C' code for a Bandpass Filter.



basicchip
Posts: 837
Joined: Fri Oct 19, 2012 2:39 am
Location: Lake Tahoe, CA
Contact:

Re: Digital Bandpass Filter

Post by basicchip » Wed Sep 07, 2016 6:32 am

You can find some source at sourceforge, do you need better than 12 bit a/d?

danlee58
Posts: 210
Joined: Thu Jan 17, 2013 2:29 am

Re: Digital Bandpass Filter

Post by danlee58 » Thu Sep 08, 2016 1:08 am

A 12 Bit A/D should be OK. The A/D Sample Rate needs to be 20kHz. The Coridium ProPlus should be OK.

I have a Digital Filter Design Program from Iowa Hills Software. I have already generated 32 Coefficients for a 5.6kHz FIR Bandpass Filter. I only need code to sample the A/D, and fill a 32 word array. Then Multiply & Add to get an output. Then increment the array address for the next sample. The output should peak, when the selected frequency signature matches the coefficients.

danlee58
Posts: 210
Joined: Thu Jan 17, 2013 2:29 am

Re: Digital Bandpass Filter

Post by danlee58 » Thu Sep 08, 2016 2:46 pm

The signal that I want to sample is about 27 mVolts. I think that 12 bits should give me enough resolution.

danlee58
Posts: 210
Joined: Thu Jan 17, 2013 2:29 am

Re: Digital Bandpass Filter

Post by danlee58 » Sat Sep 10, 2016 10:33 am

I have code written in 'C' for a Coridium Super Pro. I think that processor is overkill for this application. How much do I need to change in my setup to use a Pro Plus?

basicchip
Posts: 837
Joined: Fri Oct 19, 2012 2:39 am
Location: Lake Tahoe, CA
Contact:

Re: Digital Bandpass Filter

Post by basicchip » Sun Sep 11, 2016 3:19 pm

Well the sales of SuperPROs to PROpluses have been 10:1 so the prices now reflect that now(ie, we don't save much in low volume sales). Yes a FIR filter probably won't tax the CPU much, but to be able to do multiple things you will need to use DMA and or interrupts to keep up.

With a 27 mV signal a 50 cent quad op amp and a few Rs and Cs might be a better front end for a filter.

Post Reply