Unable to optain response from cedrus button box

Description of the experiment: Our MRI experiment requires the use of the blue and yellow buttons of the cedrus button box (LS-PAIR) to have a slider component move up and down. This is done in order to continuously rate pain over the experiment.

Description of the problem: When polling for a response from the button box nothing is added to the response queue. As below:

            print(len(buttonBox.response_queue))             <- - - this prints 0 (even when pressing the button box)
            while len(buttonBox.response_queue):
                evt = buttonBox.get_next_response()

Has anyone encountered this issue?

Hello rrr

is your Cedrus-box detected at all? This utility by Cedrus allows you to check whether the os knows your box.

Best wishes Jens

1 Like

Hi JensBoelte,

Thank so much for the advice!

The unity software did recognise the cedrus box but said that it was an older addition, and had most features disabled:

It advised us that we could change the features only if we updated the firmware, which it did not allow us to do.

Conclusion is that the box is being recognised but there may be something wrong with it. We tried with two different cedrus but had the same result.

Have you had this issue before?


no; I never had issues with my Cedrus-box but given that it is mine everything is enabled. There were two bug fixes (2017, 2019) which “should” be installed depending on how you control the box. 2021 there was a fix to how a delay was measured.

I had never problems with firmware update on the Cedrus-box. But that doesn’t help you when you are not allowed to update. I see a lot of labs that do not update their soft- and hardware because everything is running. Well, at the same time they might be missing a lot of new features. Given that there are three boxes you might convince them to update one box.

Did you try the sample code provided by Cedrus? Their approach looks different than the one you used.

How do others address the Cedrus-box? Do they use PsychoPy as well or another software?

Best wishes Jens


I do recommend you update the firmware, but that’s not what is causing your issue.

The response queue is empty because poll_for_response() is what puts responses in there. Basically, poll_for_response() is meant to be called in a loop, not just once.

We have sample demo code on GitHub:

1 Like