FieldPoint Family

cancel
Showing results for 
Search instead for 
Did you mean: 

cFP Real Time database query

I want to do a fairly simple thing.  I want my cFP to read in data, and send it to a MySQL database on a server.  The reading in of the data is easy.  The hard part is getting it to the database.
 
The attached .vi works fine when running on my Windows PC.  When I try to download it to the cFP, it aborts and I get the message "Failed to download DB Tools Open Schema.vi".  Now I know the cFP probably doesn't have the ODBC drivers to make this .vi work on the cFP like it does on my PC, but I was hoping that during the download, a translation would take place that would make it work.  It doesn't.
 
Could someone take a look at the .vi and make some suggestions on how I could get MySQL queries to work on my Compact FieldPoint?
 
Thanks for your help; this is a make-or-break deal for the project I am working on.  Even if you don't know the answer, suggestions are appreciated!
 
Synap
0 Kudos
Message 1 of 7
(3,833 Views)

Here's one option:  You obviously are running your MySQL on a PC... so, you can have a LabVIEW App on there too which communicates with your cFP VIs (via TCP/IP, for instance) and then writes that data to the MySQL Server. 

-Khalid

0 Kudos
Message 2 of 7
(3,823 Views)

No, I'm running Labview on my PC, but the MySQL database is on a Linux(LAMP) server.

I know there's got to be a solution other than wasting a windows PC as a go-between in the middle of my cFP and database.

0 Kudos
Message 3 of 7
(3,818 Views)
I am pretty sure you cannot write to mySQL directly from cFP.  There has to be an intermediate entity. 
 
By the way, LabVIEW VIs / EXE can run on Linux too.
 
-Khalid
0 Kudos
Message 4 of 7
(3,811 Views)

Thanks for your replies Khalid.  I guess I'll start looking into having a host as an intermediary.  I'll also have to test out some .exe's on our linux machines!

 

0 Kudos
Message 5 of 7
(3,808 Views)
Synap,

I think Khalid has presented the best option here. I'm not sure what a LAMP server is, but I'd try getting LabVIEW to run on it. If this is not one of NI's supported distributions, would switching be a possibility?

Regards,
Ryan Verret
Product Marketing Engineer
Signal Generators
National Instruments
0 Kudos
Message 6 of 7
(3,798 Views)

Ryan,

LAMP just stands for Linux-Apache-MySQL-PHP, and has nothing to do with Labview.  It is a popular configuration for non-corporate web/database servers because all four components are free!  These are server applications, so the machine never 'logs in' to be able to run Labview .exes.  That's why I'm introducing a PC inbetween.

If I discover a way to run .exe as a server application, than I may revisit the system configuration.

Jake

0 Kudos
Message 7 of 7
(3,793 Views)