psychopy.org | Reference | Downloads | Github

Missing parallel port triggers for subset of event codes


#1

Hi all,

I’m having a bizarre issue with parallel port triggers and I’m hoping someone has an idea for how to fix it.

I’m using PsychoPy 3.03 on Windows with an experiment created in Builder View and sending triggers to a BioSemi EEG system via the parallel port.

Most of my triggers are being sent fine, but when the event code is set to some particular numbers, they sometimes don’t show up.

Specifically, the code sent via the parallel port is determined by a column in my input file for each trial. When that column indicates the codes 141-143 or 151-153 the trigger is sent fine. But the exact same p_port component sometimes—around half the time—does not send the trigger when the code is supposed to be 161-163.

Another p_port component that sends 121-123 and 131-133 also has problems with missing codes. However, p_port components sending other codes (1-108, 210-212, 220-225, and many others) work fine.

Things I have checked/considered:

  1. The codes are not missing in my input file.
  2. The 161-163 codes do not appear to be in a different format in my input file. The input files are .csv, so it’s not like some weird formatting could be hidden deep in the file, and all the codes look the same both in Excel and in a plain text editor.
  3. The 161-163 codes get recorded correctly in the .csv file PsychoPy outputs, suggesting they are read in correctly.
  4. There is no aspect of trial behavior that differs for the trials with these specific codes. These codes simply indicate that the picture was not shown in a priori memory test, but all aspects of timing and presentation are the same for these trials (vs. the ones with the codes that work correctly) other than a different number being sent via the parallel port.
  5. The codes are truly missing: that is, they are not showing as another number, there is simply not a trigger where there should be.
  6. The missing triggers are random: when I re-run the same list (which is deterministic because I don’t have the trials set to present in random order) it is not the same trials that have missing triggers each time, except that it only happens on 161-163, and never the other codes that this p_port component sends.
  7. One thought I had was a hardware problem. Perhaps there is some pin on the parallel port hardware involved in the codes that are missing? However, looking at the binary representation, I can’t see any pin that is systematically involved in 161-163 and not the other codes. Also, for other events in my study I have many other event codes (e.g., all the codes 1-108) that send fine, and surely a broken pin would affect a much larger set of codes?
  8. I also don’t think this is a timing issue (i.e., the triggers not being presented for long enough or another trigger overlapping). They are present for 50 ms (60 Hz monitor refresh rate), which has never been a problem for me before, and no other trigger is sent within hundreds of ms. More to the point, I can’t see how this would only happen for the specific codes that are missing when the exact same p_port component with the same timing never fails for other codes.

I am baffled. Thoughts?

UPDATE 3/19/19

I created a simple Psychopy script that just sends the triggers 1 through 255 20 times each. This works fine: no missing event codes. Then, when I re-run my original script . . . no missing event codes! But then a few days later, I’m back to missing event codes.

So then I tried replacing all the codes 161-163 with another code (253). This worked: there were no missing instances of 253. So I then I reverted to the original input with 161-163, and, again, there were no missing event codes: all the 161-163 codes were present. But then a few days later they went missing again.

It seems that doing anything or running anything different than the original script temporarily fixes the problem, but that could just be an illusory correlation borne of a randomly intermittent issue.

I can’t make sense of any of this.


#2

Can you try using a different cable?