%==========================================================================
%===== Design of An FIR BAND PASS Filter, With PASS BAND To Be Centered ===
%===== Around A Frequency Less Than Fs/4 (Fs/8 is OK). As No Window     ===
%===== Has Been Specified In The Line 'b=fir1(n,wn,window)' fir1        ===
%===== Employs A Hamming Window.                                        ===
%==========================================================================

Fs=400;
wn=[.1 .3];
n=70;
[b]=fir1(n,wn);
[H,w]=freqz(b,1,n);

figure(1);
plot(w*Fs/(2*pi),abs(H));
title('FIR BAND PASS Filter With Hamming Window');
xlabel('Frequency (Hz)');
ylabel('Magnitude of Frequency Response');
grid on