The timing between turning laser on and stimulus on

Hi Taylor,

The QCUALOR changes we discussed are now in the MWorks nightly build. Just to recap how things now work:

  • When the experiment loads, all channels are configured to “off”.

  • When start_io_device is called, only channels with non-“off” modes and channels going from a non-“off” mode to “off” are configured. No configuration commands are sent for channels with mode “off” that are already off.

  • When stop_io_device is called, all channels that are currently in non-“off” modes are configured to “off”. No configuration commands are sent for channels with mode “off” that are already off.

As was previously the case, it’s OK to invoke start_io_device without invoking stop_io_device first. However, regardless of whether you call stop_io_device or not, if the MEG line is high when start_io_device executes, you still need to set it low and then back to high in order for the configuration change to take effect.

Also, I added a new parameter: log_commands. If set to true, MWorks will print to the MWServer console the serial commands sent to and received from the device. This could be useful if you (or Karim) want to know exactly when and what data is being exchanged between MWorks and the device. (It was also very helpful to me when testing these changes.)

When you have a chance, please give the new build a try, and let me know if you run in to any issues.

Cheers,
Chris