SPUC::cic< Numeric > Class Template Reference
[SPUC templatesFIR filtersInterpolation filters]

class for CIC digital filter More...

#include <cic.h>

Collaboration diagram for SPUC::cic< Numeric >:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 cic (char n=3)
 Constructor.
void reset ()
 Reset.
void num_stages (char n)
 To change the number of stages dynamically.
Numeric interpolate (Numeric in=0, signed char dump=0)
 For CIC interpolation, non-zero dump implies new input.
Numeric decimate (Numeric in, signed char dump)
 For CIC decimation, non-zero dump implies output required.

Protected Attributes

smart_array< Numeric > diff
smart_array< Numeric > nacc
 Differentiators.
smart_array< Numeric > prev
 Accumulators.
char stages
 Previous values.

Detailed Description

template<class Numeric>
class SPUC::cic< Numeric >

class for CIC digital filter

Implementation for cascaded integrator comb filters This implementation provides for both decimation and interpolation filtering. Registers are signed long and the default number of stages is 3.

Author:
Tony Kirke
cic.gif


Constructor & Destructor Documentation

template<class Numeric>
SPUC::cic< Numeric >::cic ( char  n = 3  )  [inline]

Constructor.


Member Function Documentation

template<class Numeric>
Numeric SPUC::cic< Numeric >::decimate ( Numeric  in,
signed char  dump 
) [inline]

For CIC decimation, non-zero dump implies output required.

template<class Numeric>
Numeric SPUC::cic< Numeric >::interpolate ( Numeric  in = 0,
signed char  dump = 0 
) [inline]

For CIC interpolation, non-zero dump implies new input.

template<class Numeric>
void SPUC::cic< Numeric >::num_stages ( char  n  )  [inline]

To change the number of stages dynamically.

template<class Numeric>
void SPUC::cic< Numeric >::reset ( void   )  [inline]

Reset.


Member Data Documentation

template<class Numeric>
smart_array<Numeric> SPUC::cic< Numeric >::diff [protected]

template<class Numeric>
smart_array<Numeric> SPUC::cic< Numeric >::nacc [protected]

Differentiators.

template<class Numeric>
smart_array<Numeric> SPUC::cic< Numeric >::prev [protected]

Accumulators.

template<class Numeric>
char SPUC::cic< Numeric >::stages [protected]

Previous values.


The documentation for this class was generated from the following file:
Generated on Mon Jun 9 19:40:34 2008 for DSPTemplates by  doxygen 1.4.7