Howdy, Stranger!

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

Supported by

[open] how to flush responses on serial response box

edited September 2014 in OpenSesame

Hi,

I'm having a problem with using the serial response box (the one from psychology software tools) in OpenSesame:
I designed a simple experiment in which two stimuli are shown in a subsequent order with a blank screen in between. After every stimulus (projected using a sketchpad item) a response on the response box is collected using the following script in Inline:

exp.srbox.start()
buttonlist, timestamp=exp.srbox.get_button_press(allowed_buttons=1,5], timeout=3000)
exp.srbox.stop()

For some reason, if you would press a button twice during the first stimulus, the second response is used as the response for the second stimulus. I know with the keyboard you can flush responses and this has worked in previous version of this task, but I don't know how to solve this for the response box.

Any ideas?

thanks in advance!
Tamara

Comments

  • edited 5:40PM

    Hi Tamara,

    The SRBox plug-in flushes automatically when you call the start() function, so that is unlikely to be the problem here. What comes to mind is that the first button may, on occasion, still be pressed when the script is executed, thus triggering a response. The SRBox plug-in doesn't require a new button to be pressed, but will also respond to buttons that were already pressed when get_button_press() was called.

    Could that be it?

    Cheers,
    Sebastiaan

  • edited 5:40PM

    Hi Sebastiaan,

    Thanks for your quick reply!
    Your explanation makes sense. However, I would very much like the SRBox plug-in to respond only to button presses that are started after the script is executed. Is that possible?

    thanks,
    Tamara

  • edited 5:40PM

    Hi Tamara,

    You could pause the experiment while any button is pressed, at some point before you collect the response. This will require a bit of Python inline_scripting. I don't have an SRBox here to test, but something like this should do the job:

    # Loop until no button is pressed
    while True:
        t, l = exp.srbox.get_button_press(timeout=1)
        if l == []:
            break
    

    See also:

    Note that any delay due to waiting for a button release will not be taken into account in the response time as determined by the srbox plug-in!

    Cheers,
    Sebastiaan

Sign In or Register to comment.

agen judi bola , sportbook, casino, togel, number game, singapore, tangkas, basket, slot, poker, dominoqq, agen bola. Semua permainan bisa dimainkan hanya dengan 1 ID. minimal deposit 50.000 ,- bonus cashback hingga 10% , diskon togel hingga 66% bisa bermain di android dan IOS kapanpun dan dimana pun. poker , bandarq , aduq, domino qq , dominobet. Semua permainan bisa dimainkan hanya dengan 1 ID. minimal deposit 10.000 ,- bonus turnover 0.5% dan bonus referral 20%. Bonus - bonus yang dihadirkan bisa terbilang cukup tinggi dan memuaskan, anda hanya perlu memasang pada situs yang memberikan bursa pasaran terbaik yaitu http://45.77.173.118/ Bola168. Situs penyedia segala jenis permainan poker online kini semakin banyak ditemukan di Internet, salah satunya TahunQQ merupakan situs Agen Judi Domino66 Dan BandarQ Terpercaya yang mampu memberikan banyak provit bagi bettornya. Permainan Yang Di Sediakan Dewi365 Juga sangat banyak Dan menarik dan Peluang untuk memenangkan Taruhan Judi online ini juga sangat mudah . Mainkan Segera Taruhan Sportbook anda bersama Agen Judi Bola Bersama Dewi365 Kemenangan Anda Berapa pun akan Terbayarkan. Tersedia 9 macam permainan seru yang bisa kamu mainkan hanya di dalam 1 ID saja. Permainan seru yang tersedia seperti Poker, Domino QQ Dan juga BandarQ Online. Semuanya tersedia lengkap hanya di ABGQQ. Situs ABGQQ sangat mudah dimenangkan, kamu juga akan mendapatkan mega bonus dan setiap pemain berhak mendapatkan cashback mingguan. ABGQQ juga telah diakui sebagai Bandar Domino Online yang menjamin sistem FAIR PLAY disetiap permainan yang bisa dimainkan dengan deposit minimal hanya Rp.25.000. DEWI365 adalah Bandar Judi Bola Terpercaya & resmi dan terpercaya di indonesia. Situs judi bola ini menyediakan fasilitas bagi anda untuk dapat bermain memainkan permainan judi bola. Didalam situs ini memiliki berbagai permainan taruhan bola terlengkap seperti Sbobet, yang membuat DEWI365 menjadi situs judi bola terbaik dan terpercaya di Indonesia. Tentunya sebagai situs yang bertugas sebagai Bandar Poker Online pastinya akan berusaha untuk menjaga semua informasi dan keamanan yang terdapat di POKERQQ13. Kotakqq adalah situs Judi Poker Online Terpercayayang menyediakan 9 jenis permainan sakong online, dominoqq, domino99, bandarq, bandar ceme, aduq, poker online, bandar poker, balak66, perang baccarat, dan capsa susun. Dengan minimal deposit withdraw 15.000 Anda sudah bisa memainkan semua permaina pkv games di situs kami. Jackpot besar,Win rate tinggi, Fair play, PKV Games