Vicon Local File Write [Python]

Using Python on Windows to access the Vicon output stream and log directly to a file

Code author: Original author unknown but this version was developed by Lee Whitcher.

Direct repo link: https://github.gatech.edu/GT-AE-Indoor-Flight-Laboratory/Python-Vicon-Local-File-Write

Access the Vicon output stream on a local machine (or any other Windows machine on the IFL network) and save to a file.

This code, of unknown origin, uses a Python wrapper to use a C library written for what is believed to be the Vicon DataStream SDK. This is a really useful tool for running on the IFL PC to shorten the workflow of logging a tracking mission offboard and saving it directly to the format you want. Otherwise, you would have to log a mission in Tracker, load it, then export to CSV.

Download all files locally to the machine where you want to make a log file. You will need to edit ViconFileWrite.py to contain the name of the Vicon object you care about, spelled as it is in Vicon Tracker (case sensitive). You will also need to make sure the connection settings are correct for the Tracker settings.

As long as Tracker is Live and your object is being actively tracked, running ViconFileWrite.py from the command line will log the stream into the file, f. This code uses a unique time string as a filename that is a useful technique for keeping track of which file was logged when. To stop logging, ctrl-C out of the terminal.

Last updated