From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.
We appreciate your patience as we improve our online experience.
03-19-2012 12:55 PM
Being a novice to LabVIEW, I'm not sure how to convert a 1-D array of double to double to display. I'm trying to display a time stamp from a waveform to a double precision display.
I would appreciate any help!
Thank you!!!
03-19-2012 01:07 PM
If it is a waveform data type, you use the Get Waveform Components to extract t0. You would need to use a To Double Precision Float to convert the timestamp.
03-19-2012 01:08 PM - edited 03-19-2012 01:09 PM
You can't "convert" a 1D array to a single value. You can index out an element to a single value. Or you can perform some mathematical operation, like the average value. However, you said you have a waveform, so it sounds to me like what you really should be looking at are the waveform-related functions. Specifically, Get Waveform Components. This will allow you to get the starting time for the waveform, and wire it directly to a timestamp indicator. Is this what you need?
EDIT: Dennis posted while I was, so you got a double answer.
03-19-2012 01:35 PM
Hi!
Thank you for the quick reply!
I've tried converting the time array, but I can't seem to display it on the standard double precision display.
I've attached the error.
Thank you for your help!!!
03-19-2012 01:40 PM
Interesting attempt with Flatten To String, but ditch all of that. After you convert the Time Array to DBL, simply Right-click on the thick orange wire (Array of DBL) and Choose Create->Indicator.
03-19-2012 01:50 PM
And why are you doing all of that instead of just getting t0?
03-19-2012 02:58 PM
Your idea to "dump the idea" led me to try another approach. I used the "time stamp" vi, and that did what I wanted to do all along!
Thank you for your help!!
This is a great forum. I really appreciate your help!
03-19-2012 03:03 PM
Your suggestion to "ditch all that" was a great one. I tried a different approach, that of using the "elapsed time" vi, and that did the trick! It's doing exactly what I wanted it to do.
Thanks so much for your help! This is a great forum!!!