취소
다음에 대한 결과 표시 
다음에 대한 검색 
다음을 의미합니까? 

Display returns latest data value rather than maximum data value.

I have requested the Maximum value using the Statistics VI.  The display returns the latest value rather than the maximum.  I think it may have to do with specifying the sample size or data packet size but I don't know how to do that.
0 포인트
1/7 메시지
3,203 조회수
What do you have wired to the input? Is it an array or scalar? It would have to be an array to work. What is generating the data? Can you post the code that demonstrates the problem?
0 포인트
2/7 메시지
3,189 조회수
The data is generated by a NI SCC-68 I/O Connector Block that is hooked up to a strain gauge.  The output from the DAQ Assistant is dynamic data.  It feeds the Signals input of the Statistics VI.  Output from the Statistics VI feeds a floating point, double precision display icon.  The display changes with every sample received which is near zero when there is no force being exerted on the strain gauge.  I would like to be able to specify a data/sample/time range over which the maximum value is captured and displayed until it is reset.
 
Also, I do not know how to post the code.  Can you offer a hint on how to do that?  Thanks.
0 포인트
3/7 메시지
3,172 조회수

You probably are only taking a single reading with the DAQ Assistant and the Statistics function expects an array to determine the max value in that array. There are a couple ways to do what you want. One way is to use the Array Min & Max Single Point function (Signal Processing>Point by Point>Other Functions). This has a sample length input and a reset input. Another way is to create an array with a shift register and use the Statistics function or just the Array Min & Max function. You could limit the size of the array with Array Subset for example.

To attach a file to your post, look below the message body. There is a Attachment field with a browse button.

 

Message Edited by Dennis Knutson on 06-29-2007 09:41 AM

0 포인트
4/7 메시지
3,165 조회수
I have attached my block diagram.  I will pursue your ideas, but I wanted to let you see my code in case you wanted to make further comments before I get back with you on my results.  Thanks again.
 
 
0 포인트
5/7 메시지
3,155 조회수
What makes it a bit tricky is getting the time stamp of the max value. I've modified your VI to use the waveform data type. A couple of shift registers is used to hold the y array and a timestamp array. I only did this for the first channel so you would need to duplicate it for the second channel. Please note that using the build array in while loop is not very efficient and if you run this for a long time, you will have performance problems.
0 포인트
6/7 메시지
3,134 조회수
Thank you very much.  You have been a great help.  We are only planning on running the trials for a few seconds (at most a couple of minutes) at a time, so the efficiency is probably not that important at this time.  Thanks again.
0 포인트
7/7 메시지
3,131 조회수