Millisecond Forums

Insert Function

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

By sarahlynmart@gmail.com - 10/23/2016

Hello,

I'm having trouble with inserting a fixation cross as its own trial to signify the beginning of the experimental task (fixation cross presented for 500ms).  Can you tell me if I need to do anything additional?  I have copy/pasted relevant trial, block, and experiment code for your reference.  Thank you for your help!

<text fixationcross>
/ items = ("+")
/ position = (50%, 50%)
/ fontstyle = ("Arial", values.fixationcross_height, false, false, false, false, 5, 1)
</text>

<trial fixationcross>
/ ontrialbegin = [text.fixationcross]
/ trialduration = values.fixationduration
</trial>

<block fixationcross>
/ trials = [1 = fixationcross]
</block>

<expt >
/preinstructions = (learninginstructions)
/postinstructions = (end)
/blocks = [1 = fixationcross; 2 = learning; 3 = test]
/onexptend = [values.completed = 1]
</expt>
By Dave - 10/23/2016

<trial fixationcross>
/ ontrialbegin = [text.fixationcross]
/ trialduration = values.fixationduration
</trial>

needs to read

<trial fixationcross>
/ stimulustimes= [0=fixationcross]
/ trialduration = values.fixationduration
</trial>

/ontrialbegin is for executing *logic* (updating variables, etc.) at the start of the trial. It doesn't not display stimuli. In fact, anything in /ontrialbegin is excuted before any stimuli are ever presented.

The attributes for actually displaying stimuli are /stimulustimes and /stimulusframes (you only ever use one of the two in a given <trial> element). /stimulustimes (and -frames) indicate when to display which stimulus elements.