OS (e.g. Win10): Win11
Standard Standalone? yes
What are you trying to achieve?: I am setting up an experiment on a monitor. I want to get the trial nr on my own laptop that is attached to the monitor.
What did you try to make it work?: I have tried to simply print the trial number in the runner while executing the experiment, but this lags and therefore not accurate. Now I am trying to use my laptop as a second window and show the trial number as text there. I have used the following code in a code component:
laptop_win = visual.Window(size=(400, 200), units=âpixâ, fullscr=False, pos=(100, 100))
trial_number_text = visual.TextStim(laptop_win, text=ââ, pos=(0, 0), height=30, color=âwhiteâ)
total_trials = 168
for trial_number in range(total_trials):
trial_number_text.text = fâTrial {trials_conditions.thisTrialN}â
trial_number_text.draw()
laptop_win.flip()
What specifically went wrong when you tried that?: In principle, it seems to work but I am running into issues with the timing of my experiment. It results in about a 1 sec lag when trying to continue to the next trial. I believe it might be due to the laptop_win.flip(), because without this line, the timing is good again (but the trial nr is not displayed).
I am sorry if anything is unclear, I am a beginner in psychopy so I hope I explained it understandable. Thanks in advance!