Stop sampler after participant finishes action
Hello!
I'm trying to make my experiment OSweb friendly so I'm converting my python scripts into inline_javascripts.
I have the following setup:
- Sampler (duration: 0)
- Sketchpad (duration: 0)
- Keyboard_response
- inline_script (python)
In the inline script i have the following code:
items['my_sampler'].sampler.stop()
This works as intended, making the Sampler stop playing after the Sketchpad is 'dismissed' by pressing a key. Any timing solution would not work as the participant has to read the content of the sketchpad and only then stop the sampler.
How can I convert the script to an inline_javascript? I tried multiple ways but everything failed.
Thank you in advance!
Comments
Hi Josh,
Stopping a sound file is indeed tricky in OSWeb, so I don't see an easy solution for your issue. Sorry about that...
Cheers,
Lotje
Did you like my answer? Feel free to
