Dual monitor set up

Hi Jon,

We would like to make this easier but at the moment this is possible with a code snippet in your Builder experiment.

For example add a code snippet to the first routine in your task.

In the Begin Routine set up the second Monitor

win2 = visual.Window(
    size=[1920, 1080], fullscr=True, screen=0, 
    winType='pyglet', allowStencil=False,
    monitor='MySecondMonitor', color=[-1,-1,-1], colorSpace='rgb',
    blendMode='avg', useFBO=True, 
    units='height', pos = [-200, -200])

Then you can make a text component to draw in the second window (specifying win as win2. For example:

second_screen_text = visual.TextStim(win=win2, name='intro_text',
    text='Examiner Screen \n\nNot seen by participant',
    font='Arial',
    pos=(0, 0.3), height=0.05, wrapWidth=None, ori=0.0, 
    color='white', colorSpace='rgb', opacity=None, 
    languageStyle='LTR',
    depth=0.0);

To draw the stimulus on the second screen add this to your Begin Routine tab:

second_screen_text.setAutoDraw(True)

Then this at the end of the routine to stop drawing it

second_screen_text.setAutoDraw(False)

If you are calculating accuracy you can pipe that into the text e.g.

accuracy = 80# here I made a random value - you are probably calculating this somewhere
second_screen_text.text = 'accuracy is ' + str(accuracy)

Before drawing the second screen text.

Hope this helps,
Becca

2 Likes