通过
LabPython
将
Python
引入到
LabVIEW
中
本文介绍如何使用
OpenG
中的
LabPython
模块来将
Python
引入到
LabVIEW
中,可以加快
LabVIEW
的编程。
一、安装环境
通过
VIPM
安装
OpenG
后,即可使用
LabPython
模块。
本机运行环境为
Win64
,
Python
为
2.7.9
。
安装的
LabPython
模块为
4.0.0.4
,
需要的支持环境为
【
This
package was tested with Python
2.5 on both Windows 7 x86 and Windows XP x86
】可以继
续使用,只是需要设置一下。二、编写写程序,运行报错程
序在
PYTHON New Session_ogtk.vi
时就报错:
error code is the 1046 "LabVIEW
cannot initialize the script server.
Ensure the server
software is installed."
表明未安装
Python
服务。解决方法如下:
新建一个
VI
,重新设置
Python
的服务路径:注:
在
64
位