Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

Reading Configuration Files using Labview RT in a Compact RIO

Solved!
Go to solution

 

Hello,

 

I am very new to the Labview RT/Compact RIO development platform and happen to have a question. I will be developing an application in Labview RT/ FPGA that will perform several simulations. However some of these simulations can produce different results based on configuration parameters. Usually our systems run in a Windows app, were there is a configuration file (typically in XML) which the application reads and parses the given parameters. I was wondering if there is something similar I can do, in which I have a configuration file that can be read prior to initializing my Labview RT/FPGA application, to change the simulation.

 

Thanks

 

Mario

 

0 Kudos
Message 1 of 5
(4,558 Views)

Hi Mario,

 

There is unfortunately no native XML support on real time targets, they use a Windows specific XML parser.  However, there is native .ini file support, and it is also possible to write your own XML parser if necessary.

Regards,

Jeremy_B

Applications Engineer
National Instruments
0 Kudos
Message 2 of 5
(4,539 Views)

Hello Jeremy,

 

My files don't need to be in XML, however I should be able to read a configuration file and use the values there to perform calculations. From what you say it should be possible to do this using .INI file and native support for them, correct?

 

Thanks,

 

Mario

0 Kudos
Message 3 of 5
(4,536 Views)
Solution
Accepted by topic author Mario Benitez

Hi Mario,

 

That is correct, there are VIs for .ini files on real time targets.

Regards,

Jeremy_B

Applications Engineer
National Instruments
0 Kudos
Message 4 of 5
(4,533 Views)

Hi Mario,

 

One thing that might not be clear to people new to LV Real-Time (hopefully it is already clear for you), is that the Real-Time controllers have an internal storage with a file system that you can access using many of the FIle I/O primitives in LabVIEW, including the INI file primitives that Jeremy_B mentioned (they are under the "Configuraiton File VIs" subpalette). Also, you can access that file system through an FTP server that is built-into LabVIEW Real-Time, so you can use regular FTP transactions to communicate with the controller's file system.

 

Regards, 

 

JMota

0 Kudos
Message 5 of 5
(4,528 Views)