dls-dodal 1.62.0__py3-none-any.whl → 1.64.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {dls_dodal-1.62.0.dist-info → dls_dodal-1.64.0.dist-info}/METADATA +3 -3
- {dls_dodal-1.62.0.dist-info → dls_dodal-1.64.0.dist-info}/RECORD +89 -76
- dls_dodal-1.64.0.dist-info/entry_points.txt +3 -0
- dodal/_version.py +2 -2
- dodal/beamlines/__init__.py +1 -0
- dodal/beamlines/adsim.py +5 -3
- dodal/beamlines/b21.py +3 -1
- dodal/beamlines/i02_2.py +32 -0
- dodal/beamlines/i03.py +9 -0
- dodal/beamlines/i07.py +21 -0
- dodal/beamlines/i09.py +11 -4
- dodal/beamlines/i09_1.py +10 -4
- dodal/beamlines/i09_2.py +30 -0
- dodal/beamlines/i10.py +7 -69
- dodal/beamlines/i10_1.py +35 -0
- dodal/beamlines/i10_optics.py +231 -0
- dodal/beamlines/i15_1.py +5 -5
- dodal/beamlines/i17.py +60 -1
- dodal/beamlines/i18.py +15 -9
- dodal/beamlines/i19_1.py +3 -3
- dodal/beamlines/i19_2.py +2 -2
- dodal/beamlines/i19_optics.py +4 -1
- dodal/beamlines/i21.py +31 -1
- dodal/beamlines/i24.py +3 -3
- dodal/cli.py +7 -7
- dodal/common/visit.py +4 -4
- dodal/devices/aperturescatterguard.py +6 -4
- dodal/devices/apple2_undulator.py +225 -126
- dodal/devices/attenuator/filter_selections.py +6 -6
- dodal/devices/b07_1/ccmc.py +1 -1
- dodal/devices/common_dcm.py +63 -16
- dodal/devices/current_amplifiers/femto.py +4 -4
- dodal/devices/current_amplifiers/sr570.py +3 -3
- dodal/devices/fast_grid_scan.py +4 -4
- dodal/devices/fast_shutter.py +19 -7
- dodal/devices/i02_2/__init__.py +0 -0
- dodal/devices/i03/dcm.py +4 -2
- dodal/devices/i03/undulator_dcm.py +1 -1
- dodal/devices/i04/murko_results.py +35 -14
- dodal/devices/i07/__init__.py +0 -0
- dodal/devices/i07/dcm.py +33 -0
- dodal/devices/i09/__init__.py +1 -2
- dodal/devices/i09_1_shared/__init__.py +3 -0
- dodal/devices/i09_1_shared/hard_undulator_functions.py +111 -0
- dodal/devices/i10/__init__.py +29 -0
- dodal/devices/i10/diagnostics.py +37 -5
- dodal/devices/i10/i10_apple2.py +125 -229
- dodal/devices/i10/slits.py +38 -6
- dodal/devices/i15/dcm.py +7 -46
- dodal/devices/i17/__init__.py +0 -0
- dodal/devices/i17/i17_apple2.py +51 -0
- dodal/devices/i19/access_controlled/__init__.py +0 -0
- dodal/devices/i19/{shutter.py → access_controlled/shutter.py} +7 -4
- dodal/devices/i22/dcm.py +3 -3
- dodal/devices/i24/dcm.py +2 -2
- dodal/devices/oav/oav_detector.py +1 -1
- dodal/devices/oav/oav_parameters.py +4 -4
- dodal/devices/oav/oav_to_redis_forwarder.py +4 -4
- dodal/devices/oav/pin_image_recognition/__init__.py +3 -3
- dodal/devices/oav/pin_image_recognition/utils.py +1 -1
- dodal/devices/oav/snapshots/snapshot.py +1 -1
- dodal/devices/oav/snapshots/snapshot_image_processing.py +12 -12
- dodal/devices/oav/snapshots/snapshot_with_grid.py +1 -1
- dodal/devices/oav/utils.py +2 -2
- dodal/devices/pgm.py +3 -3
- dodal/devices/robot.py +5 -5
- dodal/devices/tetramm.py +9 -5
- dodal/devices/thawer.py +0 -4
- dodal/devices/util/lookup_tables.py +8 -2
- dodal/devices/v2f.py +2 -2
- dodal/devices/zebra/zebra_constants_mapping.py +2 -2
- dodal/devices/zocalo/__init__.py +4 -4
- dodal/devices/zocalo/zocalo_results.py +4 -4
- dodal/log.py +9 -9
- dodal/plan_stubs/motor_utils.py +4 -4
- dodal/plans/configure_arm_trigger_and_disarm_detector.py +2 -2
- dodal/plans/save_panda.py +7 -7
- dodal/plans/verify_undulator_gap.py +4 -4
- dodal/testing/fixtures/__init__.py +0 -0
- dodal/testing/fixtures/run_engine.py +46 -0
- dodal/testing/fixtures/utils.py +57 -0
- dls_dodal-1.62.0.dist-info/entry_points.txt +0 -3
- dodal/beamlines/i10-1.py +0 -25
- dodal/devices/i09/dcm.py +0 -26
- {dls_dodal-1.62.0.dist-info → dls_dodal-1.64.0.dist-info}/WHEEL +0 -0
- {dls_dodal-1.62.0.dist-info → dls_dodal-1.64.0.dist-info}/licenses/LICENSE +0 -0
- {dls_dodal-1.62.0.dist-info → dls_dodal-1.64.0.dist-info}/top_level.txt +0 -0
- /dodal/devices/areadetector/plugins/{CAM.py → cam.py} +0 -0
- /dodal/devices/areadetector/plugins/{MJPG.py → mjpg.py} +0 -0
- /dodal/devices/i18/{KBMirror.py → kb_mirror.py} +0 -0
- /dodal/devices/i19/{blueapi_device.py → access_controlled/blueapi_device.py} +0 -0
- /dodal/devices/i19/{hutch_access.py → access_controlled/hutch_access.py} +0 -0
dodal/beamlines/i09_2.py
CHANGED
|
@@ -2,6 +2,11 @@ from dodal.common.beamlines.beamline_utils import (
|
|
|
2
2
|
device_factory,
|
|
3
3
|
)
|
|
4
4
|
from dodal.common.beamlines.beamline_utils import set_beamline as set_utils_beamline
|
|
5
|
+
from dodal.devices.apple2_undulator import (
|
|
6
|
+
Apple2,
|
|
7
|
+
UndulatorGap,
|
|
8
|
+
UndulatorPhaseAxes,
|
|
9
|
+
)
|
|
5
10
|
from dodal.devices.i09.enums import Grating
|
|
6
11
|
from dodal.devices.pgm import PGM
|
|
7
12
|
from dodal.devices.synchrotron import Synchrotron
|
|
@@ -22,3 +27,28 @@ def synchrotron() -> Synchrotron:
|
|
|
22
27
|
@device_factory()
|
|
23
28
|
def pgm() -> PGM:
|
|
24
29
|
return PGM(prefix=f"{PREFIX.beamline_prefix}-MO-PGM-01:", grating=Grating)
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
@device_factory()
|
|
33
|
+
def jid_gap() -> UndulatorGap:
|
|
34
|
+
return UndulatorGap(prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-01:")
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
@device_factory()
|
|
38
|
+
def jid_phase() -> UndulatorPhaseAxes:
|
|
39
|
+
return UndulatorPhaseAxes(
|
|
40
|
+
prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-01:",
|
|
41
|
+
top_outer="PUO",
|
|
42
|
+
top_inner="PUI",
|
|
43
|
+
btm_inner="PLI",
|
|
44
|
+
btm_outer="PLO",
|
|
45
|
+
)
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
@device_factory()
|
|
49
|
+
def jid() -> Apple2:
|
|
50
|
+
"""I09 soft x-ray insertion device."""
|
|
51
|
+
return Apple2(
|
|
52
|
+
id_gap=jid_gap(),
|
|
53
|
+
id_phase=jid_phase(),
|
|
54
|
+
)
|
dodal/beamlines/i10.py
CHANGED
|
@@ -6,17 +6,17 @@ note:
|
|
|
6
6
|
idd == id1, idu == id2.
|
|
7
7
|
"""
|
|
8
8
|
|
|
9
|
-
from daq_config_server.client import ConfigServer
|
|
10
|
-
|
|
11
9
|
from dodal.common.beamlines.beamline_utils import device_factory
|
|
12
10
|
from dodal.common.beamlines.beamline_utils import set_beamline as set_utils_beamline
|
|
13
11
|
from dodal.devices.current_amplifiers import CurrentAmpDet
|
|
14
|
-
from dodal.devices.i10
|
|
15
|
-
|
|
16
|
-
|
|
12
|
+
from dodal.devices.i10 import (
|
|
13
|
+
I10Diagnostic,
|
|
14
|
+
I10Diagnostic5ADet,
|
|
15
|
+
I10Slits,
|
|
16
|
+
I10SlitsDrainCurrent,
|
|
17
|
+
PiezoMirror,
|
|
17
18
|
)
|
|
18
|
-
from dodal.devices.i10.
|
|
19
|
-
from dodal.devices.i10.mirrors import PiezoMirror
|
|
19
|
+
from dodal.devices.i10.diagnostics import I10Diagnostic, I10Diagnostic5ADet
|
|
20
20
|
from dodal.devices.i10.rasor.rasor_current_amp import RasorFemto, RasorSR570
|
|
21
21
|
from dodal.devices.i10.rasor.rasor_motors import (
|
|
22
22
|
DetSlits,
|
|
@@ -24,9 +24,7 @@ from dodal.devices.i10.rasor.rasor_motors import (
|
|
|
24
24
|
PaStage,
|
|
25
25
|
)
|
|
26
26
|
from dodal.devices.i10.rasor.rasor_scaler_cards import RasorScalerCard1
|
|
27
|
-
from dodal.devices.i10.slits import I10Slits, I10SlitsDrainCurrent
|
|
28
27
|
from dodal.devices.motors import XYStage, XYZStage
|
|
29
|
-
from dodal.devices.pgm import PGM
|
|
30
28
|
from dodal.devices.temperture_controller import (
|
|
31
29
|
Lakeshore340,
|
|
32
30
|
)
|
|
@@ -38,69 +36,9 @@ set_log_beamline(BL)
|
|
|
38
36
|
set_utils_beamline(BL)
|
|
39
37
|
PREFIX = BeamlinePrefix(BL)
|
|
40
38
|
|
|
41
|
-
I10_CONF_CLIENT = ConfigServer(url="https://daq-config.diamond.ac.uk")
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
LOOK_UPTABLE_DIR = "/dls_sw/i10/software/gda/workspace_git/gda-diamond.git/configurations/i10-shared/lookupTables/"
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
@device_factory()
|
|
48
|
-
def pgm() -> PGM:
|
|
49
|
-
"I10 Plane Grating Monochromator, it can change energy via pgm.energy.set(<energy>)"
|
|
50
|
-
return PGM(
|
|
51
|
-
prefix=f"{PREFIX.beamline_prefix}-OP-PGM-01:",
|
|
52
|
-
grating=I10Grating,
|
|
53
|
-
gratingPv="NLINES2",
|
|
54
|
-
)
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
@device_factory()
|
|
58
|
-
def idd() -> I10Id:
|
|
59
|
-
"""i10 downstream insertion device:
|
|
60
|
-
id.energy.set(<energy>) to change beamline energy.
|
|
61
|
-
id.energy.energy_offset.set(<off_set>) to change id energy offset relative to pgm.
|
|
62
|
-
id.pol.set(<polarisation>) to change polarisation.
|
|
63
|
-
id.laa.set(<linear polarisation angle>) to change polarisation angle, must be in LA mode.
|
|
64
|
-
"""
|
|
65
|
-
return I10Id(
|
|
66
|
-
prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-01:",
|
|
67
|
-
pgm=pgm(),
|
|
68
|
-
look_up_table_dir=LOOK_UPTABLE_DIR,
|
|
69
|
-
source=("Source", "idd"),
|
|
70
|
-
config_client=I10_CONF_CLIENT,
|
|
71
|
-
)
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
@device_factory()
|
|
75
|
-
def idu() -> I10Id:
|
|
76
|
-
"""i10 upstream insertion device:
|
|
77
|
-
id.energy.set(<energy>) to change beamline energy.
|
|
78
|
-
id.energy.energy_offset.set(<off_set>) to change id energy offset relative to pgm.
|
|
79
|
-
id.pol.set(<polarisation>) to change polarisation.
|
|
80
|
-
id.laa.set(<linear polarisation angle>) to change polarisation angle, must be in LA mode.
|
|
81
|
-
"""
|
|
82
|
-
return I10Id(
|
|
83
|
-
prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-21:",
|
|
84
|
-
pgm=pgm(),
|
|
85
|
-
look_up_table_dir=LOOK_UPTABLE_DIR,
|
|
86
|
-
source=("Source", "idu"),
|
|
87
|
-
config_client=I10_CONF_CLIENT,
|
|
88
|
-
)
|
|
89
|
-
|
|
90
|
-
|
|
91
39
|
"""Mirrors"""
|
|
92
40
|
|
|
93
41
|
|
|
94
|
-
@device_factory()
|
|
95
|
-
def first_mirror() -> PiezoMirror:
|
|
96
|
-
return PiezoMirror(prefix=f"{PREFIX.beamline_prefix}-OP-COL-01:")
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
@device_factory()
|
|
100
|
-
def switching_mirror() -> PiezoMirror:
|
|
101
|
-
return PiezoMirror(prefix=f"{PREFIX.beamline_prefix}-OP-SWTCH-01:")
|
|
102
|
-
|
|
103
|
-
|
|
104
42
|
@device_factory()
|
|
105
43
|
def focusing_mirror() -> PiezoMirror:
|
|
106
44
|
return PiezoMirror(prefix=f"{PREFIX.beamline_prefix}-OP-FOCS-01:")
|
dodal/beamlines/i10_1.py
ADDED
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
from dodal.common.beamlines.beamline_utils import device_factory
|
|
2
|
+
from dodal.common.beamlines.beamline_utils import set_beamline as set_utils_beamline
|
|
3
|
+
from dodal.devices.i10 import I10JDiagnostic, I10JSlits, PiezoMirror
|
|
4
|
+
from dodal.devices.temperture_controller.lakeshore.lakeshore import Lakeshore336
|
|
5
|
+
from dodal.log import set_beamline as set_log_beamline
|
|
6
|
+
from dodal.utils import BeamlinePrefix, get_beamline_name
|
|
7
|
+
|
|
8
|
+
BL = get_beamline_name("i10-1")
|
|
9
|
+
set_log_beamline(BL)
|
|
10
|
+
set_utils_beamline(BL)
|
|
11
|
+
PREFIX = BeamlinePrefix("i10", "J")
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
@device_factory()
|
|
15
|
+
def em_temperature_controller() -> Lakeshore336:
|
|
16
|
+
return Lakeshore336(
|
|
17
|
+
prefix=f"{PREFIX.beamline_prefix}-EA-TCTRL-41:",
|
|
18
|
+
)
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
@device_factory()
|
|
22
|
+
def slits() -> I10JSlits:
|
|
23
|
+
return I10JSlits(prefix=f"{PREFIX.beamline_prefix}-AL-SLITS-")
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
@device_factory()
|
|
27
|
+
def diagnostic() -> I10JDiagnostic:
|
|
28
|
+
return I10JDiagnostic(
|
|
29
|
+
prefix=f"{PREFIX.beamline_prefix}-DI-",
|
|
30
|
+
)
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
@device_factory()
|
|
34
|
+
def focusing_mirror() -> PiezoMirror:
|
|
35
|
+
return PiezoMirror(prefix=f"{PREFIX.beamline_prefix}-OP-FOCA-01:")
|
|
@@ -0,0 +1,231 @@
|
|
|
1
|
+
"""
|
|
2
|
+
note:
|
|
3
|
+
I10 has two insertion devices one up(idu) and one down stream(idd).
|
|
4
|
+
It is worth noting that the downstream device is slightly longer,
|
|
5
|
+
so it can reach Mn edge for linear arbitrary.
|
|
6
|
+
idd == id1, idu == id2.
|
|
7
|
+
"""
|
|
8
|
+
|
|
9
|
+
from daq_config_server.client import ConfigServer
|
|
10
|
+
|
|
11
|
+
from dodal.common.beamlines.beamline_utils import device_factory
|
|
12
|
+
from dodal.common.beamlines.beamline_utils import set_beamline as set_utils_beamline
|
|
13
|
+
from dodal.devices.apple2_undulator import (
|
|
14
|
+
BeamEnergy,
|
|
15
|
+
InsertionDeviceEnergy,
|
|
16
|
+
InsertionDevicePolarisation,
|
|
17
|
+
UndulatorGap,
|
|
18
|
+
UndulatorJawPhase,
|
|
19
|
+
UndulatorPhaseAxes,
|
|
20
|
+
)
|
|
21
|
+
from dodal.devices.i10 import (
|
|
22
|
+
I10SharedDiagnostic,
|
|
23
|
+
I10SharedSlits,
|
|
24
|
+
I10SharedSlitsDrainCurrent,
|
|
25
|
+
PiezoMirror,
|
|
26
|
+
)
|
|
27
|
+
from dodal.devices.i10.i10_apple2 import (
|
|
28
|
+
I10Apple2,
|
|
29
|
+
I10Apple2Controller,
|
|
30
|
+
LinearArbitraryAngle,
|
|
31
|
+
)
|
|
32
|
+
|
|
33
|
+
# Imports taken from i10 while we work out how to deal with split end stations
|
|
34
|
+
from dodal.devices.i10.i10_setting_data import I10Grating
|
|
35
|
+
from dodal.devices.pgm import PGM
|
|
36
|
+
from dodal.devices.synchrotron import Synchrotron
|
|
37
|
+
from dodal.log import set_beamline as set_log_beamline
|
|
38
|
+
from dodal.utils import BeamlinePrefix, get_beamline_name
|
|
39
|
+
|
|
40
|
+
BL = get_beamline_name("i10")
|
|
41
|
+
set_log_beamline(BL)
|
|
42
|
+
set_utils_beamline(BL)
|
|
43
|
+
PREFIX = BeamlinePrefix(BL)
|
|
44
|
+
|
|
45
|
+
LOOK_UPTABLE_DIR = "/dls_sw/i10/software/blueapi/scratch/i10-config/lookupTables/"
|
|
46
|
+
|
|
47
|
+
|
|
48
|
+
@device_factory()
|
|
49
|
+
def synchrotron() -> Synchrotron:
|
|
50
|
+
return Synchrotron()
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
"""Mirrors"""
|
|
54
|
+
|
|
55
|
+
|
|
56
|
+
@device_factory()
|
|
57
|
+
def first_mirror() -> PiezoMirror:
|
|
58
|
+
return PiezoMirror(prefix=f"{PREFIX.beamline_prefix}-OP-COL-01:")
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
@device_factory()
|
|
62
|
+
def pgm() -> PGM:
|
|
63
|
+
"I10 Plane Grating Monochromator, it can change energy via pgm.energy.set(<energy>)"
|
|
64
|
+
return PGM(
|
|
65
|
+
prefix=f"{PREFIX.beamline_prefix}-OP-PGM-01:",
|
|
66
|
+
grating=I10Grating,
|
|
67
|
+
grating_pv="NLINES2",
|
|
68
|
+
)
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
@device_factory()
|
|
72
|
+
def switching_mirror() -> PiezoMirror:
|
|
73
|
+
return PiezoMirror(prefix=f"{PREFIX.beamline_prefix}-OP-SWTCH-01:")
|
|
74
|
+
|
|
75
|
+
|
|
76
|
+
"""ID"""
|
|
77
|
+
|
|
78
|
+
I10_CONF_CLIENT = ConfigServer(url="https://daq-config.diamond.ac.uk")
|
|
79
|
+
|
|
80
|
+
LOOK_UPTABLE_DIR = "/dls_sw/i10/software/gda/workspace_git/gda-diamond.git/configurations/i10-shared/lookupTables/"
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
@device_factory()
|
|
84
|
+
def idd_gap() -> UndulatorGap:
|
|
85
|
+
return UndulatorGap(prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-01:")
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
@device_factory()
|
|
89
|
+
def idd_phase() -> UndulatorPhaseAxes:
|
|
90
|
+
return UndulatorPhaseAxes(
|
|
91
|
+
prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-01:",
|
|
92
|
+
top_outer="RPQ1",
|
|
93
|
+
top_inner="RPQ2",
|
|
94
|
+
btm_inner="RPQ3",
|
|
95
|
+
btm_outer="RPQ4",
|
|
96
|
+
)
|
|
97
|
+
|
|
98
|
+
|
|
99
|
+
@device_factory()
|
|
100
|
+
def idd_jaw_phase() -> UndulatorJawPhase:
|
|
101
|
+
return UndulatorJawPhase(
|
|
102
|
+
prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-01:",
|
|
103
|
+
move_pv="RPQ1",
|
|
104
|
+
)
|
|
105
|
+
|
|
106
|
+
|
|
107
|
+
@device_factory()
|
|
108
|
+
def idd() -> I10Apple2:
|
|
109
|
+
"""i10 downstream insertion device:"""
|
|
110
|
+
return I10Apple2(
|
|
111
|
+
id_gap=idd_gap(), id_phase=idd_phase(), id_jaw_phase=idd_jaw_phase()
|
|
112
|
+
)
|
|
113
|
+
|
|
114
|
+
|
|
115
|
+
@device_factory()
|
|
116
|
+
def idd_controller() -> I10Apple2Controller:
|
|
117
|
+
"""I10 downstream insertion device controller."""
|
|
118
|
+
return I10Apple2Controller(
|
|
119
|
+
apple2=idd(),
|
|
120
|
+
lookuptable_dir=LOOK_UPTABLE_DIR,
|
|
121
|
+
source=("Source", "idd"),
|
|
122
|
+
config_client=I10_CONF_CLIENT,
|
|
123
|
+
)
|
|
124
|
+
|
|
125
|
+
|
|
126
|
+
@device_factory()
|
|
127
|
+
def idd_energy() -> InsertionDeviceEnergy:
|
|
128
|
+
return InsertionDeviceEnergy(id_controller=idd_controller())
|
|
129
|
+
|
|
130
|
+
|
|
131
|
+
@device_factory()
|
|
132
|
+
def idd_polarisation() -> InsertionDevicePolarisation:
|
|
133
|
+
return InsertionDevicePolarisation(id_controller=idd_controller())
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
@device_factory()
|
|
137
|
+
def idd_laa() -> LinearArbitraryAngle:
|
|
138
|
+
return LinearArbitraryAngle(id_controller=idd_controller())
|
|
139
|
+
|
|
140
|
+
|
|
141
|
+
@device_factory()
|
|
142
|
+
def energy_dd() -> BeamEnergy:
|
|
143
|
+
"""Beam energy from down energy devices."""
|
|
144
|
+
return BeamEnergy(id_energy=idd_energy(), mono=pgm().energy)
|
|
145
|
+
|
|
146
|
+
|
|
147
|
+
@device_factory()
|
|
148
|
+
def idu_gap() -> UndulatorGap:
|
|
149
|
+
return UndulatorGap(prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-21:")
|
|
150
|
+
|
|
151
|
+
|
|
152
|
+
@device_factory()
|
|
153
|
+
def idu_phase() -> UndulatorPhaseAxes:
|
|
154
|
+
return UndulatorPhaseAxes(
|
|
155
|
+
prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-21:",
|
|
156
|
+
top_outer="RPQ1",
|
|
157
|
+
top_inner="RPQ2",
|
|
158
|
+
btm_inner="RPQ3",
|
|
159
|
+
btm_outer="RPQ4",
|
|
160
|
+
)
|
|
161
|
+
|
|
162
|
+
|
|
163
|
+
@device_factory()
|
|
164
|
+
def idu_jaw_phase() -> UndulatorJawPhase:
|
|
165
|
+
return UndulatorJawPhase(
|
|
166
|
+
prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-21:",
|
|
167
|
+
move_pv="RPQ1",
|
|
168
|
+
)
|
|
169
|
+
|
|
170
|
+
|
|
171
|
+
@device_factory()
|
|
172
|
+
def idu() -> I10Apple2:
|
|
173
|
+
"""i10 upstream insertion device"""
|
|
174
|
+
return I10Apple2(
|
|
175
|
+
id_gap=idu_gap(), id_phase=idu_phase(), id_jaw_phase=idu_jaw_phase()
|
|
176
|
+
)
|
|
177
|
+
|
|
178
|
+
|
|
179
|
+
@device_factory()
|
|
180
|
+
def idu_controller() -> I10Apple2Controller:
|
|
181
|
+
"""I10 upstream insertion device controller."""
|
|
182
|
+
return I10Apple2Controller(
|
|
183
|
+
apple2=idu(),
|
|
184
|
+
lookuptable_dir=LOOK_UPTABLE_DIR,
|
|
185
|
+
source=("Source", "idu"),
|
|
186
|
+
config_client=I10_CONF_CLIENT,
|
|
187
|
+
)
|
|
188
|
+
|
|
189
|
+
|
|
190
|
+
@device_factory()
|
|
191
|
+
def idu_energy() -> InsertionDeviceEnergy:
|
|
192
|
+
return InsertionDeviceEnergy(id_controller=idu_controller())
|
|
193
|
+
|
|
194
|
+
|
|
195
|
+
@device_factory()
|
|
196
|
+
def idu_polarisation() -> InsertionDevicePolarisation:
|
|
197
|
+
return InsertionDevicePolarisation(id_controller=idu_controller())
|
|
198
|
+
|
|
199
|
+
|
|
200
|
+
@device_factory()
|
|
201
|
+
def idu_laa() -> LinearArbitraryAngle:
|
|
202
|
+
return LinearArbitraryAngle(id_controller=idu_controller())
|
|
203
|
+
|
|
204
|
+
|
|
205
|
+
@device_factory()
|
|
206
|
+
def energy_ud() -> BeamEnergy:
|
|
207
|
+
"""Beam energy from down energy devices."""
|
|
208
|
+
return BeamEnergy(id_energy=idu_energy(), mono=pgm().energy)
|
|
209
|
+
|
|
210
|
+
|
|
211
|
+
"""Slits"""
|
|
212
|
+
|
|
213
|
+
|
|
214
|
+
@device_factory()
|
|
215
|
+
def optics_slits() -> I10SharedSlits:
|
|
216
|
+
return I10SharedSlits(prefix=f"{PREFIX.beamline_prefix}-AL-SLITS-")
|
|
217
|
+
|
|
218
|
+
|
|
219
|
+
"""Diagnostics"""
|
|
220
|
+
|
|
221
|
+
|
|
222
|
+
@device_factory()
|
|
223
|
+
def optics_diagnostics() -> I10SharedDiagnostic:
|
|
224
|
+
return I10SharedDiagnostic(
|
|
225
|
+
prefix=f"{PREFIX.beamline_prefix}-DI-",
|
|
226
|
+
)
|
|
227
|
+
|
|
228
|
+
|
|
229
|
+
@device_factory()
|
|
230
|
+
def optics_slits_current() -> I10SharedSlitsDrainCurrent:
|
|
231
|
+
return I10SharedSlitsDrainCurrent(prefix=f"{PREFIX.beamline_prefix}-")
|
dodal/beamlines/i15_1.py
CHANGED
|
@@ -25,7 +25,7 @@ to one or more Bluesky Protocols.
|
|
|
25
25
|
|
|
26
26
|
|
|
27
27
|
@device_factory()
|
|
28
|
-
def
|
|
28
|
+
def att_y() -> NumberedTripleAxisStage:
|
|
29
29
|
return NumberedTripleAxisStage(
|
|
30
30
|
f"{PREFIX.beamline_prefix}-OP-ATTN-01:",
|
|
31
31
|
axis1_infix="STICK1",
|
|
@@ -35,18 +35,18 @@ def attY() -> NumberedTripleAxisStage:
|
|
|
35
35
|
|
|
36
36
|
|
|
37
37
|
@device_factory()
|
|
38
|
-
def
|
|
38
|
+
def base_y() -> Motor:
|
|
39
39
|
return Motor(f"{PREFIX.beamline_prefix}-MO-TABLE-01:Y")
|
|
40
40
|
|
|
41
41
|
|
|
42
42
|
@device_factory()
|
|
43
|
-
def
|
|
43
|
+
def blower_y() -> Motor:
|
|
44
44
|
"""Same motor as blowerZ"""
|
|
45
45
|
return Motor(f"{PREFIX.beamline_prefix}-EA-BLOWR-01:TLATE")
|
|
46
46
|
|
|
47
47
|
|
|
48
48
|
@device_factory()
|
|
49
|
-
def
|
|
49
|
+
def blower_z() -> Motor:
|
|
50
50
|
"""Same motor as blowerY"""
|
|
51
51
|
return Motor(f"{PREFIX.beamline_prefix}-EA-BLOWR-01:TLATE")
|
|
52
52
|
|
|
@@ -67,7 +67,7 @@ def det2() -> YZStage:
|
|
|
67
67
|
|
|
68
68
|
|
|
69
69
|
@device_factory()
|
|
70
|
-
def
|
|
70
|
+
def env_x() -> Motor:
|
|
71
71
|
return Motor(f"{PREFIX.beamline_prefix}-MO-TABLE-01:ENV:X")
|
|
72
72
|
|
|
73
73
|
|
dodal/beamlines/i17.py
CHANGED
|
@@ -7,6 +7,16 @@ from dodal.common.beamlines.beamline_utils import (
|
|
|
7
7
|
device_factory,
|
|
8
8
|
)
|
|
9
9
|
from dodal.common.beamlines.beamline_utils import set_beamline as set_utils_beamline
|
|
10
|
+
from dodal.devices.apple2_undulator import (
|
|
11
|
+
Apple2,
|
|
12
|
+
Apple2Controller,
|
|
13
|
+
BeamEnergy,
|
|
14
|
+
InsertionDeviceEnergy,
|
|
15
|
+
InsertionDevicePolarisation,
|
|
16
|
+
UndulatorGap,
|
|
17
|
+
UndulatorPhaseAxes,
|
|
18
|
+
)
|
|
19
|
+
from dodal.devices.i17.i17_apple2 import I17Apple2Controller
|
|
10
20
|
from dodal.devices.pgm import PGM
|
|
11
21
|
from dodal.devices.synchrotron import Synchrotron
|
|
12
22
|
from dodal.log import set_beamline as set_log_beamline
|
|
@@ -33,5 +43,54 @@ def pgm() -> PGM:
|
|
|
33
43
|
return PGM(
|
|
34
44
|
prefix=f"{PREFIX.beamline_prefix}-OP-PGM-01:",
|
|
35
45
|
grating=I17Grating,
|
|
36
|
-
|
|
46
|
+
grating_pv="NLINES2",
|
|
37
47
|
)
|
|
48
|
+
|
|
49
|
+
|
|
50
|
+
@device_factory()
|
|
51
|
+
def id_gap() -> UndulatorGap:
|
|
52
|
+
return UndulatorGap(prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-01:")
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
@device_factory()
|
|
56
|
+
def id_phase() -> UndulatorPhaseAxes:
|
|
57
|
+
return UndulatorPhaseAxes(
|
|
58
|
+
prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-01:",
|
|
59
|
+
top_outer="RPQ1",
|
|
60
|
+
top_inner="RPQ2",
|
|
61
|
+
btm_inner="RPQ3",
|
|
62
|
+
btm_outer="RPQ4",
|
|
63
|
+
)
|
|
64
|
+
|
|
65
|
+
|
|
66
|
+
@device_factory(skip=True)
|
|
67
|
+
def id() -> Apple2:
|
|
68
|
+
"""I17 insertion device:"""
|
|
69
|
+
return Apple2(
|
|
70
|
+
id_gap=id_gap(),
|
|
71
|
+
id_phase=id_phase(),
|
|
72
|
+
)
|
|
73
|
+
|
|
74
|
+
|
|
75
|
+
@device_factory(skip=True)
|
|
76
|
+
def id_controller() -> Apple2Controller:
|
|
77
|
+
"""I17 insertion device controller with dummy energy to motor_converter."""
|
|
78
|
+
return I17Apple2Controller(
|
|
79
|
+
apple2=id(), energy_to_motor_converter=lambda energy, pol: (0.0, 0.0)
|
|
80
|
+
)
|
|
81
|
+
|
|
82
|
+
|
|
83
|
+
@device_factory(skip=True)
|
|
84
|
+
def id_energy() -> InsertionDeviceEnergy:
|
|
85
|
+
return InsertionDeviceEnergy(id_controller=id_controller())
|
|
86
|
+
|
|
87
|
+
|
|
88
|
+
@device_factory(skip=True)
|
|
89
|
+
def id_polarisation() -> InsertionDevicePolarisation:
|
|
90
|
+
return InsertionDevicePolarisation(id_controller=id_controller())
|
|
91
|
+
|
|
92
|
+
|
|
93
|
+
@device_factory(skip=True)
|
|
94
|
+
def energy() -> BeamEnergy:
|
|
95
|
+
"""Beam energy."""
|
|
96
|
+
return BeamEnergy(id_energy=id_energy(), mono=pgm().energy)
|
dodal/beamlines/i18.py
CHANGED
|
@@ -12,9 +12,13 @@ from dodal.common.visit import (
|
|
|
12
12
|
LocalDirectoryServiceClient,
|
|
13
13
|
StaticVisitPathProvider,
|
|
14
14
|
)
|
|
15
|
-
from dodal.devices.common_dcm import
|
|
15
|
+
from dodal.devices.common_dcm import (
|
|
16
|
+
DoubleCrystalMonochromatorWithDSpacing,
|
|
17
|
+
PitchAndRollCrystal,
|
|
18
|
+
RollCrystal,
|
|
19
|
+
)
|
|
16
20
|
from dodal.devices.i18.diode import Diode
|
|
17
|
-
from dodal.devices.i18.
|
|
21
|
+
from dodal.devices.i18.kb_mirror import KBMirror
|
|
18
22
|
from dodal.devices.motors import XYStage, XYZThetaStage
|
|
19
23
|
from dodal.devices.slits import Slits
|
|
20
24
|
from dodal.devices.synchrotron import Synchrotron
|
|
@@ -55,13 +59,15 @@ def undulator() -> Undulator:
|
|
|
55
59
|
|
|
56
60
|
# See https://github.com/DiamondLightSource/dodal/issues/1180
|
|
57
61
|
@device_factory(skip=True)
|
|
58
|
-
def dcm() ->
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
62
|
+
def dcm() -> DoubleCrystalMonochromatorWithDSpacing:
|
|
63
|
+
"""
|
|
64
|
+
A double crystal monocromator device, used to select the beam energy.
|
|
65
|
+
|
|
66
|
+
Once spacing is added Si111 d-spacing is 3.135 angsterm , and Si311 is 1.637
|
|
67
|
+
calculations are in gda/config/lookupTables/Si111/eV_Deg_converter.xml
|
|
68
|
+
"""
|
|
69
|
+
return DoubleCrystalMonochromatorWithDSpacing(
|
|
70
|
+
f"{PREFIX.beamline_prefix}-MO-DCM-01:", RollCrystal, PitchAndRollCrystal
|
|
65
71
|
)
|
|
66
72
|
|
|
67
73
|
|
dodal/beamlines/i19_1.py
CHANGED
|
@@ -4,12 +4,12 @@ from dodal.common.beamlines.beamline_utils import (
|
|
|
4
4
|
from dodal.common.beamlines.beamline_utils import (
|
|
5
5
|
set_beamline as set_utils_beamline,
|
|
6
6
|
)
|
|
7
|
-
from dodal.devices.i19.
|
|
8
|
-
from dodal.devices.i19.
|
|
9
|
-
from dodal.devices.i19.shutter import (
|
|
7
|
+
from dodal.devices.i19.access_controlled.blueapi_device import HutchState
|
|
8
|
+
from dodal.devices.i19.access_controlled.shutter import (
|
|
10
9
|
AccessControlledShutter,
|
|
11
10
|
HutchState,
|
|
12
11
|
)
|
|
12
|
+
from dodal.devices.i19.beamstop import BeamStop
|
|
13
13
|
from dodal.devices.oav.oav_detector import OAVBeamCentreFile
|
|
14
14
|
from dodal.devices.oav.oav_parameters import OAVConfigBeamCentre
|
|
15
15
|
from dodal.devices.synchrotron import Synchrotron
|
dodal/beamlines/i19_2.py
CHANGED
|
@@ -7,12 +7,12 @@ from dodal.common.beamlines.beamline_utils import (
|
|
|
7
7
|
from dodal.common.beamlines.beamline_utils import (
|
|
8
8
|
set_beamline as set_utils_beamline,
|
|
9
9
|
)
|
|
10
|
+
from dodal.devices.i19.access_controlled.blueapi_device import HutchState
|
|
11
|
+
from dodal.devices.i19.access_controlled.shutter import AccessControlledShutter
|
|
10
12
|
from dodal.devices.i19.backlight import BacklightPosition
|
|
11
13
|
from dodal.devices.i19.beamstop import BeamStop
|
|
12
|
-
from dodal.devices.i19.blueapi_device import HutchState
|
|
13
14
|
from dodal.devices.i19.diffractometer import FourCircleDiffractometer
|
|
14
15
|
from dodal.devices.i19.pin_col_stages import PinholeCollimatorControl
|
|
15
|
-
from dodal.devices.i19.shutter import AccessControlledShutter
|
|
16
16
|
from dodal.devices.synchrotron import Synchrotron
|
|
17
17
|
from dodal.devices.zebra.zebra import Zebra
|
|
18
18
|
from dodal.devices.zebra.zebra_constants_mapping import (
|
dodal/beamlines/i19_optics.py
CHANGED
|
@@ -5,7 +5,10 @@ from dodal.common.beamlines.beamline_utils import (
|
|
|
5
5
|
set_beamline as set_utils_beamline,
|
|
6
6
|
)
|
|
7
7
|
from dodal.devices.hutch_shutter import HutchShutter
|
|
8
|
-
from dodal.devices.i19.hutch_access import
|
|
8
|
+
from dodal.devices.i19.access_controlled.hutch_access import (
|
|
9
|
+
ACCESS_DEVICE_NAME,
|
|
10
|
+
HutchAccessControl,
|
|
11
|
+
)
|
|
9
12
|
from dodal.log import set_beamline as set_log_beamline
|
|
10
13
|
from dodal.utils import BeamlinePrefix
|
|
11
14
|
|
dodal/beamlines/i21.py
CHANGED
|
@@ -2,6 +2,11 @@ from dodal.common.beamlines.beamline_utils import (
|
|
|
2
2
|
device_factory,
|
|
3
3
|
)
|
|
4
4
|
from dodal.common.beamlines.beamline_utils import set_beamline as set_utils_beamline
|
|
5
|
+
from dodal.devices.apple2_undulator import (
|
|
6
|
+
Apple2,
|
|
7
|
+
UndulatorGap,
|
|
8
|
+
UndulatorPhaseAxes,
|
|
9
|
+
)
|
|
5
10
|
from dodal.devices.i21 import Grating
|
|
6
11
|
from dodal.devices.pgm import PGM
|
|
7
12
|
from dodal.devices.synchrotron import Synchrotron
|
|
@@ -9,7 +14,7 @@ from dodal.log import set_beamline as set_log_beamline
|
|
|
9
14
|
from dodal.utils import BeamlinePrefix, get_beamline_name
|
|
10
15
|
|
|
11
16
|
BL = get_beamline_name("i21")
|
|
12
|
-
PREFIX = BeamlinePrefix(BL
|
|
17
|
+
PREFIX = BeamlinePrefix(BL)
|
|
13
18
|
set_log_beamline(BL)
|
|
14
19
|
set_utils_beamline(BL)
|
|
15
20
|
|
|
@@ -25,3 +30,28 @@ def pgm() -> PGM:
|
|
|
25
30
|
prefix=f"{PREFIX.beamline_prefix}-OP-PGM-01:",
|
|
26
31
|
grating=Grating,
|
|
27
32
|
)
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
@device_factory()
|
|
36
|
+
def id_gap() -> UndulatorGap:
|
|
37
|
+
return UndulatorGap(prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-01:")
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
@device_factory()
|
|
41
|
+
def id_phase() -> UndulatorPhaseAxes:
|
|
42
|
+
return UndulatorPhaseAxes(
|
|
43
|
+
prefix=f"{PREFIX.insertion_prefix}-MO-SERVC-01:",
|
|
44
|
+
top_outer="PUO",
|
|
45
|
+
top_inner="PUI",
|
|
46
|
+
btm_inner="PLI",
|
|
47
|
+
btm_outer="PLO",
|
|
48
|
+
)
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
@device_factory()
|
|
52
|
+
def id() -> Apple2:
|
|
53
|
+
"""I21 insertion device."""
|
|
54
|
+
return Apple2(
|
|
55
|
+
id_gap=id_gap(),
|
|
56
|
+
id_phase=id_phase(),
|
|
57
|
+
)
|
dodal/beamlines/i24.py
CHANGED
|
@@ -9,8 +9,8 @@ from dodal.common.beamlines.beamline_utils import (
|
|
|
9
9
|
from dodal.common.beamlines.beamline_utils import set_beamline as set_utils_beamline
|
|
10
10
|
from dodal.devices.attenuator.attenuator import EnumFilterAttenuator
|
|
11
11
|
from dodal.devices.attenuator.filter_selections import (
|
|
12
|
-
|
|
13
|
-
|
|
12
|
+
I24FilterOneSelections,
|
|
13
|
+
I24FilterTwoSelections,
|
|
14
14
|
)
|
|
15
15
|
from dodal.devices.hutch_shutter import HutchShutter
|
|
16
16
|
from dodal.devices.i24.aperture import Aperture
|
|
@@ -59,7 +59,7 @@ def attenuator() -> EnumFilterAttenuator:
|
|
|
59
59
|
existing object."""
|
|
60
60
|
return EnumFilterAttenuator(
|
|
61
61
|
f"{PREFIX.beamline_prefix}-OP-ATTN-01:",
|
|
62
|
-
filter_selection=(
|
|
62
|
+
filter_selection=(I24FilterOneSelections, I24FilterTwoSelections),
|
|
63
63
|
)
|
|
64
64
|
|
|
65
65
|
|