Skip to content

NIVeriStandAdd-Ons/Real-Time-Sequence-to-Python-Script-Converter

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

Real-Time-Sequence-to-Python-Script-Converter

Description

NOTE: THIS IS NOT AN OFFICIALLY SUPPORTED UTILITY. YOU ARE WELCOME TO DOWNLOAD THE CODE AND USE IT. IT WILL NOT BE MAINTAINED BY NI.

This code is intended to help customers convert existing NI VeriStand RT Sequence files to Python scripts using the VeriStand Python API:

https://niveristand-python.readthedocs.io/en/1.0.0/index.html

This code will help with 95% of the conversation but is not expected to convert every sequence and corner case without any user correction.

All that said, the utility should convert most RT sequences and functions, saving significant time in converting from NI veriStand RT Sequences to the Python. Each resulting Python file should be reviewed, tested by the user, and corrected (if needed).

Help

  • Download the source code
  • Open the LabVIEW project named: "RT Sequence to Python Utility.lvproj"
  • Open the LabVIEW VI named: "Convert Folder of RT Sequences to Python Scripts.vi"
  • Browse to the folder containing your RT sequences
  • Run the VI.

The utility will iterate through every sequence in the folder, convert it a Python script, and save it to disk.

The utility does not convert sequences in subFolders. The user would need to browse to that folder and re-run the utility.

Note: The converter will create a python file per RT sequence file but will "import" any referenced subsequences.

By default, the python sequence will comment out the run_deterministic() function so that the test runs natively in Python on Windows. To convert, comment out the run_non_determinstic() functions and enable run_deterministic().

Section to update based:

if __name__ == "__main__":

	#realtimesequencetools.save_py_as_rtseq(MyTest, "C:\\Projects\\Real-Time-Sequence-to-Python-Script-Converter\\SavedRTScripts")
	run_non_deterministic()
	print("Finished non-deterministic")
	#run_deterministic()
	#print("Finished deterministic")

Built Availability

Built Dependencies

NI VeriStand 2025

Quality, Limitations

IP has been tested by developer. No known issues but please consider the code Alpha.

Source Version

LabVIEW 2025

Source Dependencies

License

This repository and any materials provided by NI therein are provided AS IS. NI DISCLAIMS ANY AND ALL LIABILITIES FOR AND MAKES NO WARRANTIES, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY WARRANTIES OF MERCHANTABILITY, FITNESS FOR PARTICULAR PURPOSE, OR NON-INFRINGEMENT OF INTELLECTUAL PROPERTY. NI shall have no liability for any direct, indirect, incidental, punitive, special, or consequential damages for your use of the repository or any materials contained therein.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published