Word display and Parallel port signals


Author
Message
gmd2014
gmd2014
Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)
Group: Forum Members
Posts: 11, Visits: 66
Hi
I need an app that can:
1.  Display a single word on the screen (from one of three lists - randomly).
2.  Send a signal through the parallel port to an external device (EEG)
3.  Keep the image on the screen for, say 3000 ms
4.  Repeat (until all the words on the three lists have been displayed)

Can anyone suggest whether Inquisit is a good solution?  And if so, how I would script it (very limited scripting knowledge).

Thanks in advance
Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 104K
This should be no problem to set up with Inquisit. All you need is a bunch of <trial>, <text> and <port> elements for the EEG-signaling.

gmd2014
gmd2014
Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)
Group: Forum Members
Posts: 11, Visits: 66
Thanks.  Can you recommend a good starting point (web, book, etc) to learn the coding?  
Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 104K
Start with the tutorials included in the Inquisit documentation:

https://www.millisecond.com/support/docs/v4/html/tutorials/tutorials.htm

The basics you learn there should suffice to implement your (relatively simple) procedure.

gmd2014
gmd2014
Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)
Group: Forum Members
Posts: 11, Visits: 66
Thanks again Dave, that was very helpful.

One last q if I may:  I've created a very simple script which displays a word from a list, sends an EEG signal, then awaits an input from the user before going to the next word display.

I need it to do this instead:
1.  Select the word from the list. and display it, and send EEG signal
2.  Keep displaying it for say 10000 ms
2.  Show another prompt saying "Press a key when ready"
3.  Accept input from user
4.  Go to next word display and repeat until done.

the amended script is below:


<item insects>
/ 1 = "   ANT   "
/ 2 = "   LOCUST   "
/ 3 = "   BEE   "
</item>

<text pleasant>
/ items = insects
/ position = (50, 50)
/ txcolor = (0, 0, 255)
/ fontstyle = ("Courier New", 44pt)
</text>

<trial fungoolo>
/ pretrialpause = 10
/ stimulusframes = [1=pleasant, EEGsignal]
/ validresponse = ("a", "5")
/ posttrialpause = 1000
</trial>

<block up_practice>
/ trials = [1 -3 = noreplace(fungoolo)]
/ preinstructions = (intro)
</block>

<expt>
/ preinstructions = (intro)
/ postinstructions = (end)
/ blocks = [1=up_practice]
</expt>

<instruct>
/ nextkey = ("5")
/ prevkey = ("a")
</instruct>

<defaults>
/ screencolor = (175, 175, 255)
/ fontstyle = ("Courier New", 14pt)
</defaults>

<page intro>
^^Implicit Association Test
^^This tutorial builds a simplified Implicit Attitude Task (IAT). A number of standard IAT procedures have been been omitted for the sake of illustrating basic Inquisit programming concepts. The script produced by this tutorial is provided for instructional purposes only and should not be used for research. To learn how to create a standard IAT, please see the Standard IAT Tutorial.
</page>

<port EEGsignal>
/ port = lpt1
/ subport = data
/ items = ("10101010")
</port>


<page end>
^^Implicit Association Test
^^This tutorial builds a simplified Implicit Attitude Task (IAT). A number of standard IAT procedures have been been omitted for the sake of illustrating basic Inquisit programming concepts. The script produced by this tutorial is provided for instructional purposes only and should not be used for research. To learn how to create a standard IAT, please see the Standard IAT Tutorial.
</page>

Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 104K
You simply add

<trial spacebar>
/ stimulusframes = [1=pressspacebar]
/ validresponse = (57)
</trial>

<text pressspacebar>
/ items = ("Press the spacebar for the next trial...")
</text>

and change <trial fungoolo> to

<trial fungoolo>
/ stimulusframes = [1=pleasant, EEGsignal]
/ validresponse = (noresponse)
/ trialduration = 10000
/ branch = [trial.spacebar]
</trial>


gmd2014
gmd2014
Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)
Group: Forum Members
Posts: 11, Visits: 66
Thanks heaps Dave - greatly appreciated.  It's all working perfectly, and I'll shortly be buying my license!

cheers
gmd


Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 104K
Great! Let me know if anything else comes up!

gmd2014
gmd2014
Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)Expert (1.1K reputation)
Group: Forum Members
Posts: 11, Visits: 66
Well two things have now emerged:

1.  My laptop has no LPT1, and I've purchased a USB device, which is described in the Device Manager (Windows 7) as
Port_#0002.Hub_#0004.  Not sure how address this port, as the manual refers only to LPT1 and 2.  If this is impossible, no problem, I'll just have to install the sware on a desktop with an inbuilt LPT1.

2.  Instead of sending "10101010" through to the LPT1, I want to send a specific string, based on what images I have displayed to the participant.  Is there some way of allocating variables based on say, which element in the "text" array has been presented?  If so, I would then send that variable to the port.

Cheers





Dave
Dave
Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)Supreme Being (1M reputation)
Group: Administrators
Posts: 13K, Visits: 104K
#1: USB-to-parallel adapters usually will not work. Those devices do not provide a "true" parallel interface, they merely implement just about enough functionality to drive a legacy printer. Thus, for laptop usage, get a LPT-interface card for the machine's PC-card slot.

#2: Yes, you can tie different signals to different items -- pairing them works the same as with any other (two or more) stimulus elements and you will find this covered in the "How to Present Stimulus Pairs" topic in the documentation. You cannot send arbitrary *strings*, though, signals must be either 8-bit binary or the corresponding integers in decimal.

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Reading This Topic

Explore
Messages
Mentions
Search