# The timing between turning laser on and stimulus on

**URL:** <https://mworks.discourse.group/t/the-timing-between-turning-laser-on-and-stimulus-on/951>\
**Category:** Support\
**Created:** [March 1, 2024, 8:43pm UTC](https://mworks.discourse.group/t/the-timing-between-turning-laser-on-and-stimulus-on/951 "2024-03-01T20:43:48Z")\
**Posts on this page:** 1\
**Showing post:** 37

<div class="post-metadata">

**Author:** ![cstawarz](https://yyz1.discourse-cdn.com/flex031/user_avatar/mworks.discourse.group/cstawarz/32/3_2.png) [@cstawarz](https://mworks.discourse.group/u/cstawarz)\
**Post date:** [April 8, 2024, 1:52pm UTC](https://mworks.discourse.group/t/the-timing-between-turning-laser-on-and-stimulus-on/951/37 "2024-04-08T13:52:07Z")

</div>

Hi Taylor,

The QCUALOR changes we discussed are now in the MWorks [nightly build](https://mworks.github.io/downloads/). 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](https://mworks.github.io/documentation/latest/components/qcualor_device.html#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

---

_[View the full topic](https://mworks.discourse.group/t/the-timing-between-turning-laser-on-and-stimulus-on/951)._
