Use plugins in inline scripts
in OpenSesame
hello Everybody,
I'm using a plugin (https://github.com/imnotamember/Pynetstation-Plug-In) to send triggers to an EGI EEG device. It works correctly when I drag the plugin in the experiment overview. What I'm trying to do now however is use the plugin in an inline script since I have programmed most of my paradigm using inline scripts. Is there any tutorial on how one should do this?
Thanks in advance!
Comments
Hi,
I am not sure whether you can import a plug-in just like that, and use it right away. @sebastiaan is something like that possible?
Anyhow, the plugin is based on code that you can find here: https://code.google.com/archive/p/pynetstation/
On that website you can also find examples how to use the library to interact with the EGI system. I don't think it is terribly complicated, so I would suggest you give a try and if you get stuck, we can try to help you figuring out what went wrong.
Good luck,
Eduard
Hi @gvh and @eduard ,
Once a plugin is added to the experiment, you can execute it using the
itemsobject, like so:items.execute('my_plugin')A plugin can also register objects in the Python workspace. For example, the
pygaze_initplugin registers aneyetrackerobject that you can subsequently use ininline_scriptitems. But this depends on the implementation of the plugin.So yes, you can interact programmatically with plugins. But what is possible and what makes sense all depends on the specifics of the plugin!
— Sebastiaan
Check out SigmundAI.eu for our OpenSesame AI assistant!
Dear @eduard and @sebastiaan ,
I got it working in the meantime. I'll make a post about it the coming days.
Thanks for the help!