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.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

consumer loop not synced with producer? getting less data than I should

Don't know why I am struggling so much with this. At least the event time stamps are correct so I have decided to just remove the continous stream of event numbers and only write the marker/description which has an event number in it at least. still open to suggestions but, moving the queue, consolidating the queue, using no procuder/consumer architecture, using a million tdms writes, none of it has given me equal event numbers as data.

0 Kudos
Message 11 of 15
(397 Views)

Hello LabVIEW 12110,

 

Could you please post the most recent revision of your code and a description of the current architecture you want to implement?  Did you scrap the producer/consumer loop?

 

Regards,

Tom

Thomas C.
FlexRIO Product Support Engineer
National Instruments
0 Kudos
Message 12 of 15
(367 Views)

The one in this vi is pretty close to it. I made the changes indicated by the pictures attached a few comments in. Also I moved the record event button event, and timing to the consumer loop. So the only thing in the consumer loop now are my graphs, the daq blocks and a single enqueue element block as indicated by the screenshots I posted.

Im away from my labview computer now, sorry I cant post the actual vi.

0 Kudos
Message 13 of 15
(363 Views)

Hi labview12110,

 

Could you post the latest version of your code? You said on Monday that you had changed it to use only one queue, but the last VI you have uploaded still uses two.

 

Have you considered a different architecture than the consumer-producer loop? A state machine might be appropriate here. You could have an initialization, measurement, calculation, and logging state that feed into one another. 

 

Regards,

Siana

0 Kudos
Message 15 of 15
(329 Views)