Track trigger timing
 
PST User Forum
Home       Members    Calendar    Who's On
Welcome Guest ( Login | Register )
        



Track trigger timing Expand / Collapse
Author
Message
Posted 12/15/2010 5:44:02 PM
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Forum Members
Last Login: 12/8/2011 1:01:58 PM
Posts: 19, Visits: 200
Hi,

I am creating a TMS experiment where a trigger is sent to TMS at some point during a sequence of stimuli. I have inline code to trigger TMS but I do not know how to time the onset of the trigger and the number of times the trigger was used. I imagine there's some code I could use but I'm not sure where to find it. Thank you!

Evelina

Post #5109
Posted 1/3/2011 4:54:38 PM
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Forum Members
Last Login: 12/8/2011 1:01:58 PM
Posts: 19, Visits: 200
I've been working on this for a while and have made some progress but I still need help so any input is appreciated

Experimental design: (1) InLine script to randomize the onset of the trigger;  (2) Instructions;  (3) List with stimulus parameters (vary on trial-by-trial basis);  (4) Trial sequence - Fixation, target, blank slide

I want to be able to log in the .edat file the onset and offset of the trigger together with other variables (target onset etc.). For that purpose I have declared 2 global variables "PulseOn" and "PulseOff" under the User tab in the Script window. In my InLine code right after trigger is executed (and I know that the trigger works just as it should) I have added

PulseOn = Clock.Read
c.SetAttrib "PulseOnset", PulseOn

and similar code is placed after the port is turned off for trigger offset time stamp. However, when I run this code, the variables PulseOnset/Offset are not saved in the data file. I have also tried to use c.Log in this InLine but then only one line of data (one trial) is saved and although trigger onset/offset are marked, there is no more any data about the objects presented during the trial.

In the documentation I have found that "a variable must be set as an attribute of the context object in order to be logged in the data file" so I assume that the issue here is that PulseOn/Off aren't really "attached" to any object in the experiment... Is there a way around that?

THANK YOU!

Evelina


 

Post #5139
Posted 1/5/2011 1:38:53 PM
Junior Member

Junior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior MemberJunior Member

Group: Forum Members
Last Login: 12/8/2011 1:01:58 PM
Posts: 19, Visits: 200
If anyone else runs into a similar issue and is looking for a solution, check Google Groups post below. Happy programming!

http://groups.google.com/group/e-prime/browse_thread/thread/61940a2d9d021fe0/ef7a4f4ffbe213c2#ef7a4f4ffbe213c2

Post #5145
« Prev Topic | Next Topic »


Permissions Expand / Collapse

All times are GMT -5:00, Time now is 3:21am

Powered By InstantForum.NET v4.1.4 © 2012
Execution: 0.141. 11 queries. Compression Disabled.
 
Privacy | Terms of Use | Terms and Conditions | Legal Trademarks | Authorized Use | Quality Policy
Copyright 2012 Psychology Software Tools, Inc. All Rights Reserved
Email: Info@pstnet.com | Telephone: 412.449.0078 | Fax: 412.449.0079