LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Write To Datafile

Hi all,

 

I'm a new user and have a very basic quetion.  I am trying to collect thermocouple data and I seem to be unable to write to a text file or any other filetype.  I've attached my vi for review.  Any help would be greatly appreciated.  Thanks.

 

 

0 Kudos
Message 1 of 5
(2,408 Views)

Your program is running on a cRIO.  A cRIO is its own computer.  It actually runs a RealTime operating system.   Therefore, it will not be saving the data to your computer.  It is saving it to itself.  It would be like me running your VI here on my computer and expect it to save the file to your comptuer.

 

One trick you could try is to set up a network shared folder on your computer and have the cRIO write to that location using the network address.

 

The other option is to develop a Windows application that your cRIO can communicate with and have that application write your data file.


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
0 Kudos
Message 2 of 5
(2,395 Views)

I have the cRIO in scan mode, my understanding of this is that the cRIO will not save to itself if it is in scan mode.  Is this correct?  I have the filepath in the write VI specified to the desktop and I still get nothing.

0 Kudos
Message 3 of 5
(2,380 Views)

More information.

 

I downloaded the untitled_12 example here (4th post.  Written by Van_L):

https://forums.ni.com/t5/LabVIEW/cRIO-write-to-measurement-file/td-p/350351

 

And it works! This simple VI does save the data to my desktop.  

 

However, when I create a copy of this VI from the downloads folder and open it in my project schematic, then run it, it doesn't write a data file.   So it does write a file when run as a simple VI by itself from the downloads folder, but it does not write a file when I open it from within my project as a project VI and run it from there.

 

Thanks for any help.

0 Kudos
Message 4 of 5
(2,368 Views)

msaldana,

 

When you run the VI in your project, does it save the data to your cRIO controller? The VI is written to write the file to the C drive of whatever target it is on. If you open the file when saved on your computer, it will write to your computer's C drive. But I'm guessing that when you open it up in your project it is writing to the C drive of the cRIO.

0 Kudos
Message 5 of 5
(2,320 Views)