1) LabView 8.0 (not sure about .0 or .1)
2) WinXP Pro
3) Running the functions in the UI thread
4) The attached .zip file contains everything needed to test this. The VI "MSTick Bad Behavior.vi" should reproduce the problems I've been talking about. Change the third argument of the CLFN from 123456789 to the Tick Count and my problem should show up. Or, you can just place the tick count inside the loop without even wiring it to anything and it will slow down. The attached "MSTick fine behavior.vi" is the same function being implemented purely in LabView. Finally, the attached "olfactometer_functions.dll" has the required function in it. The calling procedure is (C calling convention):
unsigned int shift_2d_and_average_2nd(unsigned int *array_start, int loa, unsigned int new_entry, int average)
where array_start is a pointer to the (0,0) entry in an array with 2 columns, loa is the total length of the space required by that array (2xlength), new_entry is the entry you want placed at the end of the first column, and average is just a flag indicating whether or not to compute the average of the 2nd column. What the function does can be seen quite easily in "MSTick fine behavior.vi".
If this is something really easy to correct that I have just overlooked, my apologies as I'm quite inexperienced with LabView. Also, if there is a better way (most likely is!) to do what I'm doing in "MSTick fine behavior.vi" then by all means let me know.
Thanks for your help with this!
-Aaron