Analog Filter Help

We are a rookie team this year and we were wondering how we would set up an analog filter on labview for our gyro so we can filter out some of the noise.

Analog filter? Once the data is in labView, it’s all digital, I’m not sure what you mean by “Analog” in this case. To me, an analog filter is made of things like real-life resistors, capacitors, inductors, amplifiers, etc.

If you just want to filter out some noise out of your signal in labView, you’d be using a digital filter. LabView has some pretty advanced filter tools but I think there is a “PID Control Input Filter” in the PID Palette that’s pretty handy and easy to use: hook up your noisy signal to the input, and you should get an output signal with less noise.

You can use the PID Control Input Filter even if you are not using any other PID features.

good luck!
David

Are you sure you need to? The FPGA has dedicated accumulators for the gyro, and the analog breakout has a single-pole low-pass filter at ~1600Hz. If you are interested in angular position, this should be good enough.

As Darist said, it is pretty easy to do the filtering digitally in LabVIEW. Pull up the filter pallette, drop a few filters and a few graph indicators, and tweak parameters until you are happy.

However, learning how to do analog filters is a great learning experience and is pretty easy if you have the right tools on hand. You will want at least one person who already knows how to solder (or at least one person who doesn’t mind a few learn-burns).

First you need to figure out where the line is between noise you want to remove and signal you want to keep. LabVIEW makes it easy to take the FFT of your signal and watch it on a graph in real time. Or, pick something a few times faster than your effective sample rate. If you are making decisions at 50Hz, put it at ~300Hz.

Next, translate that line (in Hz) to values for your filter. The internet is better at describing the math than I am, so I’ll leave this step to google. Your resistance should be in the 5k-50kish range.

Then, solder it up and put it in line.

Last, compare your newly cleaned signal to your old dirty signal. Is it still dirty? Did you clean it up so aggressively that you lost signal? Iterate!