Plugins#
In the TMSiPlugins/ folder, code to combine the TMSi Python Interface with other libraries or external devices is provided. Every plugin has a separate folder, which is explained below.
External devices#
This folder contains example code to use external devices that are supported by TMSi to use with SAGA and/or APEX.
usb ttl device |
This file contains the class to write triggers to SAGA or APEX via the USB-TTL module, using the device-specific trigger cable sold by TMSi. With this class, it is possible to initialize and find the USB-TTL module and write triggers to the SAGA/APEX TRIGGER interface. Please note that the USB-TTL module is specified per TMSi device. |
---|
PsychoPy#
This folder contains example code to show how to combine sending triggers to SAGA or APEX while running a pre-coded PsychoPy experiment (only possible with Python version 3.8). TMSi has not tested other examples with Python version 3.8.
Using TMSiPlugins/PsychoPy
To use the PsychoPy plugins that are provided in TMSiPlugins, a few preparatory steps are required. First, Python version 3.8 needs to be installed, as PyschoPy currently relies on this version of Python. Next, a dedicated virtual environment has to be created on this Python version, which can be done by double-clicking the provided installer_PsychoPy file. This installs all required libaries to use the provided examples.
After completing the installation steps above, the example can be used with the virtual environment that has just been created (see Installation for configuring the virtual enviornment).
ERP Training Routine |
This class is used to familiarize a subject with the protocol, without requiring interaction with a TMSi device. |
---|---|
Example ERP analysis |
This example shows how to post-process Poly5 data of an auditory oddball experiment, with MNE. The example is detailed, containing various post-processing steps to locate P300 peaks. Please ensure that the scikit-learn library is installed in the virtual environment (to apply ICA). |
Experiment PsychoPy |
This class demonstrates how to create an auditory oddball experiment with the PsychoPy Python Library. It also shows how to simultaneously provide stimuli to the subject and send triggers to SAGA’s or APEX’ TRIGGER port with the USB-TTL module. |
Example PsychoPy ERP experiment SAGA |
This example shows how to simultaneously run an auditory oddball PsychoPy experiment and view and save the signals during the experiment with SAGA. |
Example PsychoPy ERP experiment APEX |
This example shows how to simultaneously run an auditory oddball PsychoPy experiment and view and save the signals during the experiment with APEX. |
WaveX#
This folder contains example code to show how to set up an experiment with Cometa’s WaveX device and SAGA. The example shows how to configure the devices and how to set up an LabStreamingLayer-stream for both, so that they can be synchronized in post-processing.
The folder contains an example, as well as the used PlotterHelper. To use the example, the wavex folder is required, containing the WaveX SDK files as well as the Python-wrapper to harmonise the SDK with the TMSi Python Interface. More information on the installation procedure can be read here.
More information on the use of the integration can be found in the accompanying tutorials.