X-Git-Url: http://sraa.de/git/?a=blobdiff_plain;f=aesa%2Fsrc%2FFIR.h;fp=aesa%2Fsrc%2FFIR.h;h=12ea76504136cbc88c163d50c2040a65eaef44f1;hb=3e585a14456b930a77ea0ac81bed4c69a4a032ac;hp=0000000000000000000000000000000000000000;hpb=2bc58585fc542a6e5819eeecaee1f4820185149f;p=jump.git diff --git a/aesa/src/FIR.h b/aesa/src/FIR.h new file mode 100644 index 0000000..12ea765 --- /dev/null +++ b/aesa/src/FIR.h @@ -0,0 +1,33 @@ +#ifndef FIR_H +#define FIR_H + +#include +#include +#include +#include "global.h" + +#define FIR_LENGTH 4 // to be changed, as needed + +#define PORT_DATA_IN "data_input" +#define PORT_DATA_OUT "data_output" + +typedef struct _local_states +{ + ComplexNumber Coeffs[FIR_LENGTH]; + ComplexNumber Samples[FIR_LENGTH]; + // int bin_counter; + int pulse_counter; + int n_iterations; + + int excount; + +} FIR_State; + +void FIR_init(DOLProcess*); +int FIR_fire(DOLProcess*); + +void FIR_reset_samples(DOLProcess*); +void FIR_insert_sample(DOLProcess*, ComplexNumber); +void FIR_compute(DOLProcess*, ComplexNumber*); + +#endif