diff --git a/site_ansto/hardsup/Monitor/Pulser.c b/site_ansto/hardsup/Monitor/Pulser.c index c465353b..bcd92ef3 100644 --- a/site_ansto/hardsup/Monitor/Pulser.c +++ b/site_ansto/hardsup/Monitor/Pulser.c @@ -162,7 +162,10 @@ int main(int argc, char* argv[]) /*********************************************/ DAQmxErrChk (DAQmxStartTask(taskHandle)); - sleep(sleep_time); + do { + sleep(sleep_time); + } while (range == 0); + DAQmxStopTask(taskHandle); DAQmxClearTask(taskHandle); taskHandle = 0;