diff options
author | Josh Blum <josh@joshknows.com> | 2011-03-16 15:36:36 -0700 |
---|---|---|
committer | Josh Blum <josh@joshknows.com> | 2011-03-28 10:28:53 -0700 |
commit | 3ff8f7a5545592a9dac201a27d18bfdae4cdcb7b (patch) | |
tree | 95c893ecab4ed532726da8c434a4c1e18137089a /gnuradio-core/src/lib/general/gr_throttle.i | |
parent | a111deb45559296d6eadded9226df68af21c0477 (diff) |
throttle: cleanup conditional code and reimplement with boost posix time
This greatly cleans up gr_throttle and moves the implementation into the .cc file.
The implementation uses boost's posix time library so it will work on all systems.
Also added set_sample_rate() method and support for callback in grc.
Diffstat (limited to 'gnuradio-core/src/lib/general/gr_throttle.i')
-rw-r--r-- | gnuradio-core/src/lib/general/gr_throttle.i | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/gnuradio-core/src/lib/general/gr_throttle.i b/gnuradio-core/src/lib/general/gr_throttle.i index 21f7703eff..0b1ec165f5 100644 --- a/gnuradio-core/src/lib/general/gr_throttle.i +++ b/gnuradio-core/src/lib/general/gr_throttle.i @@ -1,6 +1,6 @@ /* -*- c++ -*- */ /* - * Copyright 2005 Free Software Foundation, Inc. + * Copyright 2005-2011 Free Software Foundation, Inc. * * This file is part of GNU Radio * @@ -20,11 +20,10 @@ * Boston, MA 02110-1301, USA. */ -GR_SWIG_BLOCK_MAGIC(gr,throttle); +%{ +#include <gr_throttle.h> +%} -gr_throttle_sptr gr_make_throttle (size_t itemsize, double samples_per_sec); +GR_SWIG_BLOCK_MAGIC(gr,throttle); -class gr_throttle : public gr_sync_block -{ - gr_throttle (size_t itemsize, double samples_per_sec); -}; +%include <gr_throttle.h> |