Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

sketchpad does not wait for the keypress

edited August 2020 in OpenSesame

Hi! me again. Long time no see :)


I have a problem again. I am posting the simplified experiment here, I deleted everything but for the parts which are involved inthe problem.

There is loop 1 and loop 2, even participants get shown in the order 2121 (so two times) and odd 1212.

In between there is an interblock sketchpad (break). It worked fine till the moment I THINK I added the sleep inline in the the middle loop. If I remove all and just let the loops show the ITI for say 2 sec, it works.

Bug: The interblock sketchpad should wait till keypress which it does for the VERY FIRST block (either1 or 2, depending on the ID, but always the very first) and then it shows the Break! text for a second and does not wait for a keypress. I changed the keypress to mouseclick, DID NOT help. When I fix the time (say, 50000 ms) it DOES wait for the 50000 ms. I cant's get what is interfereing. I would be very helpful for your help. many thanks!


Comments

  • HI Katherina,

    I couldnt find out what exactly is causing this weird behaviour (there are multiple aspects at work to produce such behaviour), but in any case, the attached script should solve your issues.

    Hope this is somewhat useful.

    Eduard


    Buy Me A Coffee

  • Thank you very much, @eduard

    I was thinking that the keyboard response is somehow stored somewhere and interfers.

    The problem is that it is even more complicated as it is in the Test :) I have larger loops, with the blocks within.

    If it's too much work I will just leave it to be a fixed time. Thank you!

  • edited August 2020


  • edited August 2020

    I answered @Katharina 's problem on another forum but just so it's listed here as well - the issue was that in the timeout_script (and in the timeout for her keyboard response), she had put/accessed timeout as a var.

    When logging (either using dict from items, or accessing _timeout) for the interblock sketchpad, you can see that after the first instance, it uses the new timeout value (timeout changes from None to an actual integer value).

    Literally naming that variable something else so it doesn't conflict (like timeout2) will stop the conflict and allow the interblock sketchpad to work with duration 'keypress'.

    Attached example here.

  • wow, that easy! Many thanks!

Sign In or Register to comment.