LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can't Create Dynamic Data Constant for Obtain Queue Function

Thanks... I did get that far... But I still need a constant for the write to file to work after dequeuing in another loop...

0 Kudos
Message 11 of 19
(221 Views)

Yes, I take your point... The .vi I am working on is quite a few years old and acquires data using the DAQ Assistant... I don't have time to re-write it using DAQmx functions and "better" coding...

0 Kudos
Message 12 of 19
(221 Views)

Hi jcannon,

 


@jcannon wrote:

Thanks... I did get that far... But I still need a constant for the write to file to work after dequeuing in another loop...


It looks like there is such a constant at the upper left corner of your truncated image…

 


@jcannon wrote:

I don't have time to re-write it using … "better" coding...


Well, you could atleast cleanup the loop to follow style guide.

And you could reduce Rube-Goldbergs: why do you need two ArrayMinMax functions to determine the min and max of the very same array???

Why do you need to clear ALL ERRORS when the error wire is used to stop a loop upon error???

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 13 of 19
(216 Views)

@pincpanter wrote:

I guess that Dynamic Data are too... dynamic for queues. You need to convert DD to a well defined type (Express -> Data manipulation palette).


Let's stop guessing!  A simple experiment will uncover a truth.  

 

Experiment NULL hypothesis: the LabVIEW memory manager cannot fully support all Data flowing on a DDT wire without using To/FromDDT Express.vis.

 

Method find a method that breaks dataflow using a DDT wire.

 

TRY

  • Queues,
  • Dynamic Events
  • Value Properties Methods or Events
  • Notifiers
  • Local Variables
  • Global.vis 

Did we find any evidence to reject the null hypothesis or, must we accept it?


"Should be" isn't "Is" -Jay
0 Kudos
Message 14 of 19
(214 Views)

Hi jcannon,

 


@jcannon wrote:

The dequeue element in the consumer loop cannot be wired to the write-to-file function if a DDT constant is not wired into the obtain queue element data type input (see the Data Queue).


Wrong.

You can have a queue of 1D-array elements and still wire to WriteMeasurementFile:

LabVIEW will automatically place a ToDDT before the WriteMeasurementFile function!

 

Again: there's most often no need to use DDT wires at the data source…

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 15 of 19
(208 Views)

Yes, it's a mess... 😂

0 Kudos
Message 16 of 19
(128 Views)

Agreed... Thanks...

0 Kudos
Message 17 of 19
(126 Views)

Thank you everyone for your replies...

 

I've decided I will create a new vi for this application using appropriate style guides etc...

 

Given the time this will take, I may regret this decision, but my OCD will be much happier with the outcome... 😂  

0 Kudos
Message 18 of 19
(102 Views)

Thanks...

0 Kudos
Message 19 of 19
(99 Views)