I was thinking along the lines of what instead of what Tachyon wroteAdding a new voltage reading every second to calculate a new mean voltage over thirty seconds
But, perhaps you want to look at rolling averages...a for/next shift, how about a in-place overwrite. (instead of shifting the data, shift the index variable.)
http://www.pbpgroup.com/modules/wfse...hp?articleid=7
http://www.picbasic.co.uk/forum/showthread.php?t=12183
http://www.picbasic.co.uk/forum/showthread.php?t=8046
http://www.picbasic.co.uk/forum/showthread.php?p=41702
http://www.picbasic.co.uk/forum/cont...ith-hysteresis
Bookmarks