LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Steps to Use or Call python functions and statements under Labwindows CVI

Hi everyone!!

 

I have problems to use the Python.h from lab windows CVI  I have those erros: io.h was not found, sys\stat.h, was not found and wchar.h was not found, do you know how to fix it?  Im using labwindows CVI 2012 and python 3.4.. all under Windows 7

 

 

0 Kudos
Message 1 of 6
(5,599 Views)

I rarely use Python and I've never tried coupling it with CVI, but I've recently run across a way to do what you want in a simple way, with Swig: http://www.swig.org/tutorial.html

Note: Things like Python and language coupling are always easier to do on Linux (CVI uses gcc there).

0 Kudos
Message 2 of 6
(5,570 Views)

In fact I have found many samples using python from C program but all those samples are under Linux, I'm looking for a solution to use Python from CVI (c programming) using the library python.h, Thanks for your help gdargaud .

 

I will be finding for another solution without SWING, because Im not familiar with SWING...

 

Or if anyone can share a solution I will appreciate it.

 

 

 

0 Kudos
Message 3 of 6
(5,560 Views)

FAAR,

 

This previous forum thread might be of interest to you. It looks like these users were able to run an example after modifying the pyconfig.h file. The file is attached to Alex D's answer. Hope it helps!

0 Kudos
Message 4 of 6
(5,515 Views)

I have used the file provided by Alex D's and also I have added the python27.lib and the it seems fixed thanks!! I will try to execute some different statements in python from CVI...

0 Kudos
Message 5 of 6
(5,508 Views)

hello 

 

did you find a solution ? 

 

0 Kudos
Message 6 of 6
(1,222 Views)