12-21-2011 01:23 PM
I have a cRio-9073. I am writing a file to the "c:" drive. The file is to be a number tab description carriage return line feed.
6 settings1
3 settings2
LabView 8.6 no problem. LabView 2011 it won't write the carriage return only the line feed. I rewrote the function to use the modern function off the File I/O palettes, file open, write text, and close file. Through much pain I found the Convert EOL and turned it off. This fixed the problem during testing. I then compiled the code and loaded it to the cRio. The problem seems to still be there in the compiled version. I them punted and rewrote the function to use the write binary file. Converted the txt to binary pushed it to the file. I still had the same result, worked in development mode and didn't work in compiled version.
12-21-2011 03:08 PM
Hi John,
what is the difference between your string input and the "serialized string" data (without prepended string length)? Have you checked that?
For me those function is just RubeGoldberg - correct me, if I'm wrong.
So it comes to a plain file write call. You definetely have different results when using this VI in the development environment and in the RunTimeEngine?
You really talk about using this on the cRIO in a "compiled" and deployed RTEXE? And really writing to the local C drive of the cRIO?
12-21-2011 04:07 PM
This is a function that is part of a larger program. But YES I am deploying a RTEXE and I am writing to the local C drive of the cRio.
I have attached the original file based on 2011 function blocks.
12-27-2011 09:30 AM
Hi FarmerJohn,
For your string control, make sure you've got the display mode set to '\' Codes Display, that way the \r carriage return code will hopefully be recognized correctly. Here's a bit more info on it: Entering a Carriage Return into a String
Tim W.
Applications Engineering
National Instruments
12-27-2011 10:21 AM
I should have included what I was doing before the function.
This is the default file I am writing. I will then open the file in notepad and change the settings. Next time the unit is rebooted, the software will read in the new settings. The problem is the cRio will not write /r and when I open the file in notepad the file will not look correct. It works good on a PC and in development mode but not in complied (.exe) mode.
12-27-2011 01:52 PM
Given that your program works in development, but not in the cRIO, there are a couple things you should check. First, make sure you're using the proper version of the RIO driver (Compatibility Chart Link). After that, when you're building the executable try disabling SSE2 Optimization (this checkbox can be found on the Advanced tab when doing your build specs).
Tim W.
Applications Engineering
National Instruments
12-27-2011 02:23 PM
RIO driver looks good. I have a newer driver than on the chart. The SSE2 did not seem to change anything.
Thanks for the help, do you have any other ideas?