def move(): yield Msg("checkpoint") grp = _short_uid("set") for motor, pos in step.items(): if pos == pos_cache[motor]: # This step does not move this motor. continue yield Msg("set", motor, pos, group=grp) pos_cache[motor] = pos yield Msg("wait", None, group=grp)
def inner_scan(): for i, step in enumerate(steps): logger.info("\nStep {0}: Moving to {1}".format(i+1, step)) grp = _short_uid('set') yield Msg('checkpoint') # Set wait to be false in set once the status object is implemented yield Msg('set', motor, step, group=grp, *args, **kwargs) yield Msg('wait', None, group=grp) yield from trigger_and_read([motor]) if return_to_start: logger.info("\nScan complete. Moving back to starting position: {0}" "\n".format(start)) yield Msg('set', motor, start, group=grp, *args, **kwargs) yield Msg('wait', None, group=grp)
def move(): grp = _short_uid('set') yield Msg('checkpoint') yield Msg('set', motor, step, group=grp) yield Msg('wait', None, group=grp)