10-30-2009 10:05 AM
Hello Mathan,
if you increase the positioning step size to 500 it works fine. The distance between the data points in your waveform is 500 and the cursor is set to snap on them. But still, I would like to know why it works for the first few data points even with a step size of 250. Hmmmm?
Regards,
Thomas
10-30-2009 10:16 AM
ThHagel wrote:if you increase the positioning step size to 500 it works fine.
Are you sure. No if the step size is increased to 500, it stops at 2.48 only and not near to 2.7 (which is required one - i tried in range and coerce but same problem). Very strange.
10-30-2009 10:21 AM
Is it a bug or am i missing something. Anybody else seeing the same behavior?
What i need to measure is i need to know the value of time at which Amplitude (Y axis) reaches 2.7V
Any alternate ideas?
Mathan
10-30-2009 10:21 AM - edited 10-30-2009 10:22 AM
10-30-2009 10:26 AM
ThHagel wrote:
... that is the first sample that is less than 2.7 (you stop condition is Y less or equal 2.7). So it works correct.
Ok so i reduced the step size to catch almost the value near to 2.7. But the behavior of the cursor is not as expected. It stays freezed at a single edge.
10-30-2009 10:30 AM
the y value 2.7 is not availble in that waveform. If you want to know the X position for y = 2.7 you have to interpolate it.
10-30-2009 10:33 AM
10-30-2009 10:38 AM
ThHagel wrote:If you want to know the X position for y = 2.7 you have to interpolate it.
Interpolate? Can you please explain more about this one. There is one function available interpolate 1D array. Are you saying about that? If so what is the input i have to give to 1D array input?
Thanks a lot for all your great support.
Mathan
10-30-2009 10:44 AM
ThHagel wrote:
Can you please send that vi containing your modified waveform...
Hai Thomas i was so confused now. I changed cursor type from single plot to free dragging. Don't know what exactly to use. I did some modifications in the code. Please go through and suggest me how to measure the value of x axis when y=2.7
Thanks,
Mathan
10-30-2009 11:07 AM
If you are able to increase the number of samples per time, you might get close enough to 2.7 and you can avoid interpolation. In this case, to make your VI work for any sample rate you should wire your waveforms dt-value as the step size for the cursor movement. This will make the cursor always stop at the first sample less or equal 2.7.
---- OK, writing this I received your VI ----> now slow down take it easy... Let's restart this
Do you want to use the cursor for visualization of the search process or was it just your first approach and you don't really need that cursor? If you only want to get a time value for that specific position in your waveform you can solve it in a more simple way.
If you want to stay with your method (for visual effects) you should use an free cursor and move it programmatic along the waveform samples. As soon as it reaches the "less or equal 2.7" point it stops at an interpolated x position for the y 2.7 value.
Please answer my question and I will try help you with a test vi.