MATLAB: Bandpass filter with FDA tool

filterMATLABsignal processing

Hello,
Can I know how to design a bandpass filter with range of 0.5 to 3Hz and needed gain is 80 (if possible 100) which will be used instead of a analog with digital filter.Coming to the sampling freq I have acquired a analog signal(having 1Hz) using a 200Hz sampling rate so I am not sure of what should be perfect sampling frequency is needed. I need the perfect bandpass filter as I will use these filter coefficients generated from fda tool in the microcontroller to design the bandpass with this matlab filter coefficients.
So,for this reason I want to be sure to have a better(perfect) filter implementation so that it won't be problem on the microcontroller filter design. Thanks.

Best Answer

Hi Stefan, yes I'll assume that you downsampled to 50 Hz (using an anti-aliasing filter)
d = fdesign.bandpass('Fst1,Fp1,Fp2,Fst2,Ast1,Ap,Ast2',0.5,1,3,4,80,0.5,80,50);
Hd = design(d,'butter');
Or using the butter() function
[z,p,k] = butter(30,[(2*0.5)/50, (2*3)/50],'bandpass');
sos = zp2sos(z,p,k);
fvtool(sos)