Millisecond Forums

Getting inquisit to communicate to Power Lab

https://forums.millisecond.com/Topic13346.aspx

By dk57 - 5/21/2014

Hi there, 

I don't understand the port definitions and use of binary numbers for inquisit scripting . I am designing a fear conditioning experiment and require Powerlab to automate electrical stimuli for particular trials. 

So in terms of putting this into my script, I am unsure of what the binary numbers indicate (under items). I have been given a demo script with these port definitions, however I don't quite understand what they mean. here are a few examples:

<port prestimulus_habit>
/ port = lpt1
/ subport = data
/ items = ("00011000")
/ erase = "00000000"
</port>

<port stimulus_onsetred>
/ port = lpt1
/ subport = data
/ items = ("00001000")
/ erase = "00000000"
</port>

<port stimulus_onsetblue>
/ port = lpt1
/ subport = data
/ items = ("00010000")
/ erase = "00000000"
</port>

Hope that makes sense. 

Any help appreciated :)

Dk57
By seandr - 5/21/2014

Hi there,
The binary strings are numbers written in base 2 rather than the standard base 10. For port signals, each bit maps to a pin, so with binary you can tell which pin is set high.
However, you can also present stimuli as standard 10-base digits. For example:
<port prestimulus_habit>
/ port = lpt1
/ subport = data
/ items = (20)
/ erase = "00000000"
</port>

Perhaps that helps?
-Sean
By Dave - 5/21/2014

Also see the "How to Present TTL Signals Through the Parallel Port" and "How to Use the Parallel Port Monitor Tool" topics in the Inquisit documentation (How To-section), as well as the language reference for the <port> element.