Hi,

I’m trying to measure reactive energy with MSP430F47187 and its SD16_A module. To calculate reactive energy I need a 90 degree phase shifter known as hilbert filter. If I use FIR filter, matlab says It requires 106 tabs(Transition Width 35 Hz, Passband Ripple 0.02dB/0.1% and Sampling Frequency 1024). I don’t know MSP430 can do this job at that frequency by using Q1.15 style fixed point arithmetic for each phase which is totally three.

Here are my questions:

1. In SLAA409A software code there are some coefficients for 90 degree phase shift. But they are for 4096 Hz sampling frequency and totally 128 tabs. In that C file (emeter-fir-table.c), it is written “This file was generated automatically by generate-fir-table”. Where can I find this “generate-fir-table” software? (I think it is software¿)

2. Can I do same job by using IIR filter instead of FIR which requires too much processing power?

3. Does TI have a filtering library for MSP430 series?

4. In same application note, there is a dc filter function which I didn’t understand how it works.

// A routine to filter away the DC content from an AC mains waveform

// signal. It does this my using a heavily damped integrator to estimate

// the DC level. The current DC level is then subtracted from the signal.

int16_t dc_filter**(**register int32_t *****p**,** register int16_t x**)**

**{**

*****p **+=** **((((**int32_t**)** x **<<** 16**)** **-** *****p**)** **>>** 14**);**

x **-=** **(***p **>>** 16**);**

**}**

I think it was designed for 4Khz sampling frequency, because for me it becomes stabile after 40 seconds. I need something faster, is it possible?

Regards,

BP.