Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

Incorrect data file saved to CRIO

I have a programme deployed to a CRIO 9014 controller and wish to save data for later retrieval.  However, to use C:\ as the data directory leads to incorrect data being stored on the data file directory.
0 Kudos
Message 1 of 6
(4,481 Views)

Hi Stan,

 

Hope you are doing well today! Can you explain the issue in a little more detail? How exactly are you logging the data; is it possible for you to post a screenshot? And, how are you viewing the data? Are you copying the file over to your computer using an FTP client or are you viewing the file through a browser? If it's through a browser, have you turned caching off? If you change the name of the file or create a new file (when you are saving data), do you get correct data? Also, can you give us an idea of what values you are getting and how it is different from the ones you are expecting?

Adnan Zafar
Certified LabVIEW Architect
Coleman Technologies
0 Kudos
Message 2 of 6
(4,466 Views)

The data comes from a 9215 analogue input module.  I am viewing the file via. an FTP client and get the same incorrect data when I update the filename.  I am expecting to save data at a rate (related to the scan rate on the 9215) and for a duration determined by the user.  The voltage data is scaled during acquisition (just after the FPGA acquire) to give Engineering Units.  Data file header is set up in the file writing VI deployed to the CRIO and is supposed to be user-controlled.  What I am getting is:

*  10 seconds worth of data irrespective of the time entered.

*  Constant data file headers (as far as I can remember they are the "dummy" ones I set initially to test the programme, before putting user-controls in.

*  My file writing routine stays active for the correct amount of time and when I look at probes it seems the VIs are processing the correct data up to and including the actual file write VI itself (My VIs are modular, passing information from one to the next).  I.e. the engineering units appear in the probes but it is the voltage values that end up in the data file.

 

At first I thought I must have still got my original test version deployed to the CRIO controller but when I change the file path to U: and write data to a memory stick plugged into the CRIO USB port everything is as it should be!!!

 

1.  Should I copy the file to my PC then look at it, instead of opening via FTP?  I cannot see how this would alter the contents.

2.  Can you also tell me how to remove VIs from the CRIO so I can be sure that only the ones I need are deployed?

 

I should add that at present I am running this application "live"  on the CRIO and viewing the screens on the Host PC in development mode rather as a run time.  However, I wouldn't have thought this would make a difference to the content, just the response.

 

Thanks

Stan

0 Kudos
Message 3 of 6
(4,450 Views)

Hi Stan,

 

Is it possible for you to post some code so we can have a look?

Adnan Zafar
Certified LabVIEW Architect
Coleman Technologies
0 Kudos
Message 4 of 6
(4,441 Views)
Here is the application in its entirety.  It is written in LabVIEW 8.5.1 and uses NI-RIO 2.4.1 drivers.  The particular VIs are in the project under Remote Main Panel.vi.  It reads the 9215 module, scales the data using the "A/D Zeroes and Gains" Control and passes data to the "DATA FILE CONTROL.vi" at intervals.  Data File Control is a general-purpose vi for writing data to file that I have adapted for use in this application.  It contains features that are not necessarily of use for what I want to do but was expedient for getting something working (or so I thought!).  The "Recording Rate" control value is set at 1Hz for now.  Eventually I will tidy this up so that it will accept data from the CRIO module at various scan rates and take an appropriate average to save at the desired intervals.
0 Kudos
Message 5 of 6
(4,436 Views)

Hi Stan,

 

It's a little difficult for me to diagnose without getting to look at an isolated piece of code that highlights the issue. Is it possible for you to run the following attachment (LV 8.6) on your cRIO target. I have a included a snapshot of the code as well. Have a look at it and let me know if that works on your controller. Hopefully, it will make it easier for you to diagnose the issue and answer some of the questions that you have. If you have any other questions, please be sure to let me know.

Adnan Zafar
Certified LabVIEW Architect
Coleman Technologies
Download All
0 Kudos
Message 6 of 6
(4,401 Views)