LabVIEW Channel Wires

Solved! Go to solution

Using Channel Wires with Dynamic Data

I'm working with a vi that uses the producer/consumer parallel loops architecture. Currently, I'm using a queue to pass data from the producer loop to the consumer loop. But I'd like to use a channel wire for this since it's cleaner and easier to follow. I'm using DAQ Assistant to acquire data but it does not appear that I can use a channel writer with dynamic data. When I go to Create>>Channel Writer, the option is grayed out. Is dynamic data simply not compatible with channel wires? Or is there something else I'm missing?

 

I know many people aren't fans of DAQ Assistant or the dynamic datatype but this is how we've got things set up for now.

 

Thanks for the help.

0 Kudos
Message 1 of 7
(419 Views)
6 REPLIES 6
Highlighted

Re: Using Channel Wires with Dynamic Data

What version of LabVIEW?

 

Well I just tried it in LV 2019 and Channel Wires do not appear to support the Dynamic Data type.

 

Easy enough to drop in a convert from Dynamic Data type for the transfer if needed.

Ryan Vallieu
Senior Systems Analyst II
NASA Ames Research Center
0 Kudos
Message 2 of 7
(411 Views)
Highlighted

Re: Using Channel Wires with Dynamic Data

Yes LV2019. I'm trying to pass a dynamic data wire that has four channels in it. So I'd have to split the wire to the individual channels, build an array, channel wire it, and index the array in the parallel loop. That will be more cluttered than the queue I'm currently using and I'd lose the timing data. Bummer.

0 Kudos
Message 3 of 7
(293 Views)
Highlighted
Solution
Accepted by topic author Mike0311

Re: Using Channel Wires with Dynamic Data

I don't think you'd have to do all that, but I could be wrong.  The Convert Dynamic Data function would allow you to rearrange to a standard LabVIEW data - the datatype with built-in timing information is the waveform...would the 1D Array of Waveform conversion in the Dynamic Data conversion express VI work for your need?

Ryan Vallieu
Senior Systems Analyst II
NASA Ames Research Center
0 Kudos
Message 4 of 7
(266 Views)
Highlighted
Solution
Accepted by topic author Mike0311

Re: Using Channel Wires with Dynamic Data

This issue should be fixed in the next LabVIEW release. In the meantime, if you want to patch your LabVIEW installation, unzip the LLB in the attached zip file (for your LabVIEW version) into the following folder, making sure to backup the existing LLB just in case:

 

[LabVIEW 20xx]/resource/plugins/PopupMenus/edit time panel and diagram

DNatt, LV R&D
Message 5 of 7
(93 Views)
Highlighted

Re: Using Channel Wires with Dynamic Data

Yeah I forgot you can convert to an array of waveforms. I did that which cleans up the producer loop a bit but now everything else is more difficult. Trying to read the last value of each waveform requires me to get the waveform Y component and then index the array that results from that. This is more cluttered than the dynamic datatype which just coerces the the data into the last value. Or if I need to I can convert from dynamic data to single scalar in a single function rather than the two required to do this with a waveform.

 

I want to use the waveform because everyone says it's better than dynamic data but it seems less intuitive. Am I going about this wrong?

Download All
0 Kudos
Message 6 of 7
(77 Views)
Highlighted

Re: Using Channel Wires with Dynamic Data

Well without knowing exactly what you're trying to do, I can't suggest much.

 

Are you using ALL of the timing data in other places?  Seems a bit overkill for that section of code.  Have you thought about breaking the data down to include meta data, such as min, max, last...?

 

You might benefit from encapsulating your functions into reentrant, or at least shared subVIs so you aren't cluttering up your main block diagram as well.

Ryan Vallieu
Senior Systems Analyst II
NASA Ames Research Center
0 Kudos
Message 7 of 7
(63 Views)
Reply
This is an open group. Sign in and click the "Join Group" button to become a group member and start posting.