Skip to content

Commit 6da2fa5

Browse files
authored
Merge branch 'main' into tet_trig
2 parents a4363b7 + 1d370c2 commit 6da2fa5

File tree

1 file changed

+37
-0
lines changed

1 file changed

+37
-0
lines changed

src/dodal/beamlines/i17.py

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
"""The I17 hardware doesn't exist yet, but this configuration file is useful for
2+
creating plans in sm-bluesky as devices build up."""
3+
4+
from ophyd_async.core import StrictEnum
5+
6+
from dodal.common.beamlines.beamline_utils import (
7+
device_factory,
8+
)
9+
from dodal.common.beamlines.beamline_utils import set_beamline as set_utils_beamline
10+
from dodal.devices.pgm import PGM
11+
from dodal.devices.synchrotron import Synchrotron
12+
from dodal.log import set_beamline as set_log_beamline
13+
from dodal.utils import BeamlinePrefix, get_beamline_name
14+
15+
BL = get_beamline_name("i17")
16+
PREFIX = BeamlinePrefix(BL)
17+
set_log_beamline(BL)
18+
set_utils_beamline(BL)
19+
20+
21+
class I17Grating(StrictEnum):
22+
AU_400 = "400 line/mm Au"
23+
SI_400 = "400 line/mm Si"
24+
25+
26+
@device_factory()
27+
def synchrotron() -> Synchrotron:
28+
return Synchrotron()
29+
30+
31+
@device_factory(skip=True)
32+
def pgm() -> PGM:
33+
return PGM(
34+
prefix=f"{PREFIX.beamline_prefix}-OP-PGM-01:",
35+
grating=I17Grating,
36+
gratingPv="NLINES2",
37+
)

0 commit comments

Comments
 (0)