How to start stimuli at different times as set in the conditions excel file?

Hi everyone,

I’m completely new to Psychopy Builder and I’m trying to build an experiment where I play sounds either to the right or left ear with a variable delay before they start, either 500 or 1500 ms.

In my conditions file I have two parameters in_dur with either 0.5 or 1.5 values and soundfile left.wav or right.wav. I can use $soundfile for my sound object, but I don’t get the variable start when I try to use $in_dur in the start parameters of my sound object. How can I get this to work?

Any help will be greatly appreciated :slight_smile:

OS (e.g. Win10): Win 8.1 Enterprise, 64bit
PsychoPy version : 2021.1.2
**What are you trying to achieve?: I want my stimulus, a sound, to start either at 0.5 or 1.5 seconds depending on the trial.
**What did you try to make it work?: In my conditions excel file, along with other parameters, I have 1 parameter called in_dur with either 0.5 or 1.5 for the different trials. So, in the sound properties I tried to use $in_dur, so it would draw either 0.5 or 1.5 depending on what’s on the file.

**What specifically went wrong when you tried that?: I get this message

if Sound1.status == NOT_STARTED and tThisFlip >= asarray($int_dur)-frameTolerance:
SyntaxError: invalid syntax

And the experiment doesn’t run.

Try upgrading to 2021.1.3. I think this is a known bug in the early 2021 releases.

Thanks for your reply. I have updated to 2021.1.3, but I’m still having the same issue.