NNL Syncbox for MRI Trigger input

We have been using the parallel port to input our MRI trigger signal into Psychopy. However, we need to switch to using a NNL (NordicNeuroLab) Syncbox, which sends the trigger signal to the PC via USB port, as a Human Device Interface (the Syncbox send the letter ‘s’ for each MRI trigger pulse). We are using a PC win8 64-bits and PsychoPy v1.79.00

Does anyone here use this kind of Syncbox? Do you think there is any accuracy timing problem for using the USB port instead of the parallel port?

Any advices will be very appreciated.

Thanks,
Fernanda

There will be some sort of lag and possibly some more variable temporal noise as well compared to the parallel port. But remember that regardless of the source of the signal, there will be some sort of variable delay between receiving it and actually updating the screen (depending upon the random time during the current screen refresh interval it is detected). Also bear in mind that all of these delays are in the milliseconds to tens of milliseconds range, but the TR of your MRI is likely in the 2-3 second range. So given the temporal resolution of your scanner, the trigger timing issues are really just not something you need to worry about (as opposed to an EEG study, for example).

Thanks, Michael.

Hi Fernanda,

How did you get on with the NNL trigger box via usb?

I’m trying to do a similar setup but using a MacBook Air.

Would you mind sharing your set up process?

Thanks,
Kunal

Hello,

I am also in the process of setting up the NNL sync box and experiencing issues with the trigger. We have included the sync box code at the beginning of our task, however, the routine does not advance beyond our initial “wait for trigger” screen. Any tips for setting up the sync box would be appreciated.

Nicole

Dear Nicole,

Please find attached the code I used to run a GO-NOGO task using the NNL sync box. Maybe you are using the wrong letter to code the trigger. Try using ‘s’.

Hope this helps you.

Best wishes,
Fernanda

go_nogo_lastrun.py (31.8 KB)

go_nogo.psyexp (26.9 KB)

Fernanda thank you for sharing both files. Our task is setup for the synch box is a bit different, although we do use the same trigger character ‘s’. We have found that the the task works in simulation mode but not sync mode with the scanner.
If you have any advise, our team would appreciate it.

Hi Nicole,

We’re running into similar issues with the NNL Syncbox. I was wondering, did you manage to get the task working with your scanner eventually?

Best,
Pauline

Hi Pauline,

So, we put the project on hold, so it’s been quite a while since I’ve used the task and scanner. Using PsychoPy with NNL was entirely new to the research team I was working with, so we may have experienced more issues just due to lack of experience. I do remember running into several issues when configuring PsychoPy to communicate with the scanner. All the suggestions in the manuals, online resources, and NNL folks didn’t seem to provide adequate solutions.

I believe that the syncbox code worked in simulation mode, but not in sync mode. For some reason, our trigger “S” was not being recorded as a keypress, so the task would not proceed. I believe the issue was that the trigger was not being recorded as a keypress. So, we created an in-house work around using some python script that converted the trigger into a keypress. We tried to embed this script in the PsychoPy task using the code component, but if I recall correctly, it didn’t work. So, we created a separate python script “serial2keyboard.py” to be used with the PsychoPy task. It was not ideal, but it I believe it worked.

I hope this helps. Of course, if your team finds a simpler solution we would appreciate sharing materials.

Nicole

(attachments)

RunA_MRI.psyexp (51.9 KB)
serial2keyboard.py (2.18 KB)

Hi Nicole,

This is going to be a wonderful help for our project! Thank you for your incredibly detailed reply and for sharing your code. If we find a simpler fix at some point we will definitely let your team know as well! :slight_smile:

Pauline