/* -*- c++ -*- */
/*
- * Copyright 2006,2010 Free Software Foundation, Inc.
+ * Copyright 2006,2010,2011 Free Software Foundation, Inc.
*
* This file is part of GNU Radio
*
d_goertzel(rate, len, freq)
{
d_len = len;
+ d_rate = rate;
+ d_freq = freq;
}
int gr_goertzel_fc::work(int noutput_items,
return noutput_items;
}
+
+void
+gr_goertzel_fc::set_freq(float freq)
+{
+ d_freq = freq;
+ d_goertzel.gri_setparms(d_rate, d_len, d_freq);
+}
+
+void
+gr_goertzel_fc::set_rate(int rate)
+{
+ d_rate = rate;
+ d_goertzel.gri_setparms(d_rate, d_len, d_freq);
+}
/* -*- c++ -*- */
/*
- * Copyright 2006 Free Software Foundation, Inc.
+ * Copyright 2006,2011 Free Software Foundation, Inc.
*
* This file is part of GNU Radio
*
gr_goertzel_fc(int rate, int len, float freq);
gri_goertzel d_goertzel;
int d_len;
+ float d_freq;
+ int d_rate;
public:
int work(int noutput_items,
gr_vector_const_void_star &input_items,
gr_vector_void_star &output_items);
+
+ void set_freq (float freq);
+ void set_rate (int rate);
};
#endif /* INCLUDED_GR_GOERTZEL_FC_H */
/* -*- c++ -*- */
/*
- * Copyright 2006 Free Software Foundation, Inc.
+ * Copyright 2006,2011 Free Software Foundation, Inc.
*
* This file is part of GNU Radio
*
{
private:
gr_goertzel_fc();
+
+public:
+ void set_freq (float freq);
+ void set_rate (int rate);
};