Jump to content

Timestamps & Waveforms: No distinction in variants?


Recommended Posts

So I'm working on making a generic algorithm for some sorting code of mine, using variants. Came across this little diddy:

post-11742-125735423442_thumb.png

When examining the output, I get: 0x 001C 0054 ...

The fourth byte (54) shows the type, but according to the documentation 0x54 is a waveform type. So I went ahead and wired up a waveform and I also get 0x54. Is this a bug? The two data types appear to not be equivalent (you can't wire up a waveform to a timestamp terminal, for example). Is there a way to differentiate between a waveform and a timestamp when using a variant?

It now occurs to me I've run into this before but didn't dig deep enough...I recall running into unexpected waveform types when using EasyXML

-michael

Link to comment

The fourth byte (54) shows the type, but according to the documentation 0x54 is a waveform type. So I went ahead and wired up a waveform and I also get 0x54. Is this a bug? The two data types appear to not be equivalent (you can't wire up a waveform to a timestamp terminal, for example). Is there a way to differentiate between a waveform and a timestamp when using a variant?

You need to look at the next I16 value after the base type. 0x03 is a waveform; 0x06 is a timestamp. The current version of OpenG LVData/Variant tools don't catch this. But the NI tools (...\LabVIEW xx\vi.lib\Utility\VariantDataType\...) will catch it.

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.