Zapit-Optostim / zapit

General purpose optostimulation system
GNU Lesser General Public License v2.1
6 stars 1 forks source link

Sending samples again whilst Zapit is waiting to present will result in an error #130

Open raacampbell opened 11 months ago

raacampbell commented 11 months ago

Running send samples once with a hardware trigger puts the DAQ into a waiting mode. If the send samples command is run a second time, an error is generated. It is not clear to the user what has happened. There should be some way of stopping this. Two options

  1. Ideally it is possible to read back from the DAQ that it's waiting for a trigger and we do not run sendSamples if this is the case.
  2. Alternatively we implement this in software. Setting a bool to true after sendSamples runs and false when stopOptoStim is run. The downside here is the user can't switch between stimuli quickly, which possibly they will want to do.
raacampbell commented 11 months ago

3af409ddd5c1407bea2e73085f2055e5ca563ed8 makes this the case for finite stimuli. For continuous it will switch from one stimulus set to the other with out warning. Maybe this is OK?