Real-Time Measurement and Control

cancel
Showing results for 
Search instead for 
Did you mean: 

compactrio

I have a compactRIO system.  Right now I have an FPGA vi that runs and reads Analog inputs.  I have a real time vi that reads the FPGA vi's analog inputs and converts them to a voltage.  Now I would like to take those values and write them to a database.  Can I do the database insert from the RT vi ? Or must I use an LV8 vi on the PC?  Ideally, the database insert would run from the RT vi on the CompactRIO controller.  I have been trying to write a simple LV8 program on the PC that reads the RT vi and writes the data to a database.  to this point I have not been able to read the RT vi into the LV8 vi.  Can anyone help?
0 Kudos
Message 1 of 7
(4,996 Views)


JFMoynihan,
                      Within the RT part we cant write into a data base as for I know. So, you have to communicate the PC from the compact rio through RS232 or Ethernet  connectivity. After acquiring the data you can archieve it.

Labview Lovers.
0 Kudos
Message 2 of 7
(4,965 Views)
JFMoynihan,

Shivkumar is correct; the database toolkit does not work on the Real Time platform. That is because the toolkit was written in ActiveX to take advantage of Microsoft's powerful database features.  Unfortuantely, these features are resource intensive and would be memory and processor prohibitive to put on Real Time targets.  Your best bet would be to acquire the data into Shared Variables, then have a host VI that simply takes the shared variable and INSERTs them into the approrpiate database.
--Paul Mandeltort
Automotive and Industrial Communications Product Marketing
0 Kudos
Message 3 of 7
(4,935 Views)
Thanks Shivkumar and Paul.  I have set the programs as you suggested and I have data flow into the database.  We were hopeful that we could do this without dedicating a PC to the system.  Fortunately, NI has the small touch screen device that runs Windows CE and we are looking at using one of those for this application.  They are quite reasonable priced.  We would still prefer a system that could communicate to the database independantly of a PC.  Perhaps NI would consider this idea for future improvements to the compactrio brand.  Thanks again.

John

0 Kudos
Message 4 of 7
(4,931 Views)
You might consider storing the data locally in a file on cRIO flash drive in a comma separated format.  You can then programatically push the file with ftp commands to the database computer.  Using a stored procedure in the database, you can then have the database itself read the file and put it in the right table, etc.  In this way, you do not need a LabVIEW program anywhere else. 
Preston Johnson
Solutions Manager, Industrial IoT: Condition Monitoring and Predictive Analytics
cbt
512 431 2371
preston.johnson@cbtechinc
0 Kudos
Message 5 of 7
(4,924 Views)
I was thinking about that possibility, too.  the limitation for this project would be that we want to be able to select a database for the data to go to. 
There are multiple databases available because testing requests come from different groups, who maintain there own databases.  Not the best setup, but that's what we have to work with.  thanks.

John

0 Kudos
Message 6 of 7
(4,919 Views)

JFMoynihan,

I work in the Product Strategy group at National Instruments. We focus on determining what our customers' challenges are and how we might address them with future products and services. Specifically, I am responsible for our LabVIEW Real-Time product line.

I am interested in learning more about your application, specifically your data logging and database requirements for cRIO. Please contact me directly at your convenience.

     Email:  jenifer.loy@ni.com               Work:  512-683-6970

I look forward to speaking with you.

Jenifer Loy

 
Jenifer Loy
Director of Software Product Design
NI
0 Kudos
Message 7 of 7
(4,901 Views)