1/24/2013 6:45 PM | |
Joined: 7/7/2010 Last visit: 9/6/2024 Posts: 15152 Rating:
|
The OSCAT library has an FT_AVG function that seems to do most of the heavy lifting you might need. It relys on a ring buffer of a size you determine. If you run a periodic OB every 10ms that calls FT_AVG to generate your running average, then another OB every 100ms to grab your periodic FT_AVG result, you should have what you are after. FT_AVG uses a couple FBs, "INC1", &"DELAY_" I've attached images of the3 FBs in SCL. AttachmentFT_AVG.scl.zip (1356 Downloads) |
science guy |
|
This contribution was helpful to
1 thankful Users |
1/29/2013 10:00 AM | |
Posts: 19 Rating:
|
Thanks, Is there some kind of sample program for this?
|
1/30/2013 7:34 AM | |
Posts: 19 Rating:
|
I tried this, but this is not as stable as i expected. So maybe I do something wrong. |
Follow us on