Skip to content

serenial/Asynchronous-System-Exec

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

41 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Asynchronous System Exec

An alternative to LabVIEW's native System Exec.vi with asynchronous access to standard input, output and error.

Similar to the .NET System Exec from 💖JKI💖 - see comparison table for more

Features

✨ Flexible LabVIEW Event based API

✨ Cross Platform support for 32-bit/64-bit Windows and 64-bit Linux (RHEL, CentOS, openSUSE & NI-RT)*

✨ Non-blocking - multiple executables can run without blocking each other or any LabVIEW threads

✨ Regular Expression powered end-of-line matching for Standard Out and Standard Error

✨ Built for the LabVIEW Community with LabVIEW 2020 Community Edition but supports saving for LabVIEW 2015

✨ Available under the Boost License v1.0 - an Open Source Initiative approved license similar to the MIT/BSD licenses without the attribution requirements for binary files

* Arm based NI-Linux-RT and Apple Mac OSs are mostly supported by C++/LabVIEW code but presently there is no build tooling for these platforms*

An animation showing a console example VI running commands with the shell on a NI-Linux-RT target


Version 3.0.1 Released 🎉

Whats New?

  • Boost (C++ Libraries) boost::process V1 has been deprecated so this updates to use V2. The ability to use the "cmd" of Start Call.vi has been removed in-line with the boost::process API changes. However, this library now includes a "Lookup Executable Path.vi" which will find the full path of an executable from the system's PATH with just the executable's name to allow for similar behavior if required.

  • The On-Exit event now includes any data from the Standard Output and Standard Error pipes that had not yet regex-matched and been generated as Std-Out/Std-Err events.

  • Configuration has been simplified to a cluster to avoid custom configuration classes being required.

  • The conversion on Windows platforms from UTF-16 can now be specified to be either UTF-8 or the ACP or OEM code page character encoding.


Installation on Windows and Linux-x64

The VIPM Package can be found on VIPM.io or a zipped copy of the VIPM contents can be found in the releases page of this repository.

Installation on NI-Linux-RT x64

Once this library is installed on the host machine, copy serenial.io-ase_64-3.so from the serenial-io.ase/ase/bin directory (from vi.lib/Serenial if installed with VIPM) into the targets usr\lib\

See this guide for methods to transfer the file, alternatively, if the target is setup for ssh access and your host machine has the scp utility then this can be used as follows to copy the package file to the target's /tmp directory.

scp <path-to-file-on-host>/libserenial.io-ase_<X.Y.Z>_x64.ipk admin@<NI-RT-SYSTEM-IP>:/tmp

Alternatively, you can use a "Source Distribution" Build under a Real Time Target to deploy files across to the RT Target easily.

Getting Started

Please see the using the Asynchronous System Exec documentation for getting started using the library.

If you would like to build the binaries for your platform or develop either the LabVIEW or the C++ code, please see the building from source documentation and developing documentation.

For information on contributions, look no further than the contributing document.


Comparison with JKI's .NET System Exec

Feature .NET System Exec This Library
Write To Std In Yes Yes
Std Out & Error User Events Yes Yes
Exit User Event Yes Yes (with exit code)
Send Terminate Signal No Yes
Max Simultaneous Instances Limited by System Resources Limited by System Resources
OS Support Windows Windows (32 and 64-bit), Linux and NI-Linux-RT (64-bit)
Made by a LabVIEW Community OG Most Definitely 😰

Contributors

John Medland

About

Mirrored from https://gitlab.com/serenial/asynchronous-system-exec and used for CI only

Resources

License

Contributing

Stars

Watchers

Forks