LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Not enough memory to complete this operation

Hello,

 

I am using labview2018, I am acquiring data from a VI running on Crio 9047 and writing data on csv file on another VI running on my Computer through variable

 

acquistion (rate is 50k)is proper but when writing data in csv file, a single writing is only possible, if I try to write more number of files, ist showing error : not enough Memory to complete this Operation.

sometime even my LabVIEW gets close after this error.

 

my VIs are attached

Download All
0 Kudos
Message 1 of 20
(2,361 Views)

Why do you have a timeout on your dequeue in your save VI? I don't see a need for this. You can also skip the Wait in the upper loop in the save VI since the queue itself will provide the wait functionality. I would avoid writing single elements to your file. File I/O is the bottle neck. Change your processing to write data once per second but write all the data that has been queued during that time in a single write. To do this you flush the queue once a second, process the array of elements from the flush and then call a single writ e to the file. I would use a single stop button to stop your processing. I prefer to use actual messages for communications with queues so you can have an explicit stop message which would stop your consumer. Why are you calling the queue status? It servers no purpose in your code.

 

 



Mark Yedinak
Certified LabVIEW Architect
LabVIEW Champion

"Does anyone know where the love of God goes when the waves turn the minutes to hours?"
Wreck of the Edmund Fitzgerald - Gordon Lightfoot
Message 2 of 20
(2,315 Views)

thanks for Input but,

How would i flush the Queue after 1 seconds ?

I did some changes but now after every saving of 4-5files (can save data for around 30 seconds only) my LabVIEW gets closed.

0 Kudos
Message 3 of 20
(2,287 Views)

STOP USING THE NETWORK PUBLISHED SHARED VARIABLE!!!  I actually deem them evil, especially in this situation where you need a Stream communication, not a Tag.  What you really should have here is a Network Stream or TCP/IP connection to stream the data from the cRIO to your PC, which then saves the data.  It would eliminate one of your loops (the Network Stream/TCP connections would act as the queue).


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 4 of 20
(2,261 Views)

hello,

actually I am new to the LabVIEW, can you please  tell how to use Network streams in this application?

 

 

0 Kudos
Message 5 of 20
(2,220 Views)

Hello Vishal

 

You can find more about Network Stream in the links given below.

https://www.ni.com/en-in/innovations/white-papers/10/lossless-communication-with-network-streams--co...

http://www.ni.com/documentation/en/labview-comms/latest/g-prog/streaming-data-using-network-stream/

Refer examples as well.

 

-Rahul

Hit KUDOS for Thanks

Message 6 of 20
(2,210 Views)

hello 

 

I created writre and read Network streams for my application but my writer is not taking the data in acquire VI please have a look

Download All
0 Kudos
Message 7 of 20
(2,200 Views)

Your Write To Stream needs to be inside of your acquisition loop.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 8 of 20
(2,178 Views)

even i did some chnages but the Network stream write loop ,it is not taking the data 

please have a look in this code

0 Kudos
Message 9 of 20
(2,174 Views)

hello crossrulz thanks for your Reply i did the required changes as told by you

but reading of sampling is not Happening . 

do the Reader has to respond ? so that the while loop will run and reading of the sampling will be done

0 Kudos
Message 10 of 20
(2,165 Views)