Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

[open] Neulog GSR

edited April 2014 in OpenSesame

I am trying to create an experiment for my thesis using OpenSesame. Part of the experiment requires me to get skin conductance (GSR/SCR/EDA) readings. I am using the Neulog GSR logger but I am having trouble figuring out how to get the GSR to feed into the OpenSesame GUI. Fortunately I have found someone who wrote python code for the specific GSR logger (https://github.com/thearn/pyneulog/tree/b9846dcd8d468f9d141c9dc519b5b1a325cd8d94) but because of my limited knowledge of code I am not able to figure out how to put it into OpenSesame (I spoke with the developer who does not have the time right now to help me).

Is there any one who can help me turn this code into a plug in?

Thanks!

Comments

  • edited 4:46PM

    Continued from #888.

    As we discussed in the thread above, you really need someone who is familiar with the device, and who can give you concrete advice about how to use the NeuroLog in Python (and by extension OpenSesame). But, to start, you mention that the developer asked you to try import serial and that this gives an error message. That's weird, because serial is a standard module that you should be able to import with no trouble. Could you please describe what you have done exactly and post the full error message (from the debug window).

    In general, make sure that you describe your problem in sufficient for people to be able to help you. What do you want to do exactly? What have you tried so far, and why doesn't it work? What operating system and distribution of OpenSesame are you using? Etc.

    Cheers!
    Sebastiaan

  • edited 4:46PM

    Good Morning Sebastiaan,

    I apologize for any frustration I am causing you, as I had mentioned (as is probably clearly evident) I am as new to the world of coding/python as they come.

    I actually tried to input serial again in the general script editor and did not receive any error messages today. However, after I hit apply changes that line disappears.

    Im Running OpenSesame 0.27.4 on Mac OS X 10.9.2

    Sebastiaan- do you want me to write what my end goal is? Or what I want the code to do?
    Also, I'm not sure how to describe what I have already tried, but I will attempt to explain it later in another post on this thread

    Thanks again for working with me,
    Michael

  • edited 4:46PM

    Hi Michael,

    I actually tried to input serial again in the general script editor and did not receive any error messages today. However, after I hit apply changes that line disappears.

    The 'general script' contains the definition of the experiment. It uses a special, simplified syntax called 'OpenSesame script', which it is not Python. To use Python code, you need to use the inline_script item. See also:

    Im Running OpenSesame 0.27.4 on Mac OS X 10.9.2

    Right, I suspected as much. I would develop the experiment under Windows, using the latest version of OpenSesame. That way you know for sure that you're not dealing with problems that are specific to the (less mature) Mac OS package.

    Sebastiaan- do you want me to write what my end goal is? Or what I want the code to do? Also, I'm not sure how to describe what I have already tried, but I will attempt to explain it later in another post on this thread

    Yes, try to be as specific a possible.

    It sounds like you're pretty much on your own on this one, because there's no-one who's both familiar with the NeuroLog and willing to share this knowledge (which is disappointing). But you'll be able to figure this out yourself with a basic knowledge of Python. So I would start by walking through one of the tutorials:

    Afterwards, you can install the neulog module in OpenSesame, simply by copying the neulog folder to the OpenSesame folder. And then see if you can adapt some of the demo functionality that is listed in experiment.py (part of pyneulog) for your specific experiment. By the looks of it, it's a pretty straightforward module (but obviously I cannot test it).

    It's not all easy, but with some persistence you will get there!

    Cheers,
    Sebastiaan

  • edited 4:46PM

    Sebastiaan, long time no speak... I had taken a break for a while and was going over what your last post, I was just curious- where would i put the neulog.py file in the opensesame folder?

  • edited 4:46PM

    Assuming that you're running the official OpenSesame distribution, you can simply drop this file into the OpenSesame program folder, and it will be automatically recognized as a module (i.e. it's in the Python path).

    Cheers!
    Sebastiaan

Sign In or Register to comment.