from ophyd.userapi.scan_api import Scan, AScan, DScan, Count scan = Scan() ascan = AScan() ascan.default_triggers = [] ascan.default_detectors = [d1, s2_1] dscan = DScan() # Use ct as a count which is a single scan. ct = Count()
theta = EpicsMotor('XF:23ID1-ES{Dif-Ax:Th}Mtr', name = 'theta') sx = EpicsMotor('XF:23ID1-ES{Dif-Ax:X}Mtr', name = 'sx') sy = EpicsMotor('XF:23ID1-ES{Dif-Ax:Y}Mtr', name = 'sy') sz = EpicsMotor('XF:23ID1-ES{Dif-Ax:Z}Mtr', name = 'sz') nptx = EpicsMotor('XF:23ID1-ES{Dif:Lens-Ax:TopX}Mtr', name = 'nptx') npty = EpicsMotor('XF:23ID1-ES{Dif:Lens-Ax:TopY}Mtr', name = 'npty') nptz = EpicsMotor('XF:23ID1-ES{Dif:Lens-Ax:TopZ}Mtr', name = 'nptz') npbx = EpicsMotor('XF:23ID1-ES{Dif:Lens-Ax:BtmX}Mtr', name = 'npbx') npby = EpicsMotor('XF:23ID1-ES{Dif:Lens-Ax:BtmY}Mtr', name = 'npby') npbz = EpicsMotor('XF:23ID1-ES{Dif:Lens-Ax:BtmZ}Mtr', name = 'npbz') # Setup auto logging olog_handler = OlogHandler(logbooks='Data Acquisition') olog_handler.setLevel(logging.INFO) session_mgr._logger.addHandler(olog_handler) # Setup Scans scan = ScanND() ascan = AScan() ascan.default_triggers = [sclr_trig] ascan.default_detectors = [sclr_ch1, sclr_ch2, sclr_ch3, sclr_ch4, sclr_ch5, sclr_ch6] dscan = DScan() dscan.default_triggers = ascan.default_triggers dscan.default_detectors = ascan.default_detectors