LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

I'm trying to execute and possibly terminate a PERL script from Labview.

I am currently using the system exec.vi to run my perl script. I would like to be able to terminate it as well. Any suggestion?


I'm running from windows xp.
0 Kudos
Message 1 of 4
(2,755 Views)
Are you looking for a clean termination or a brute-force method, similar to the "End Process" that you can do from Task Manager? If it's the latter, do a search in this forum for "kill process" and you'll come across a number of solutions. If it's the former, then I don't know because it sort of depends on whether the script can "listen" to stop commands.
0 Kudos
Message 2 of 4
(2,747 Views)
When I run the perl script from a windows command shell I can do a ctrl-C and exit the script. I was hoping to do something similar from labview.
0 Kudos
Message 3 of 4
(2,740 Views)
 
The download (LabPerl) gives you comms between Labview ' Perl and viceversa.
 
And doesn't take too long to fathom out how it all works.
 
The perl program is set running (manually or by labview command window - don't wait for completion) followed by labview control etc.
 
N.B.
Each labview write string requires a Linefeed - then chomp at perl end
The secret is to  have a good handshake method - each LabView read returns to perl an "ok"
 
0 Kudos
Message 4 of 4
(2,719 Views)