File tree Expand file tree Collapse file tree 3 files changed +32
-6
lines changed
Expand file tree Collapse file tree 3 files changed +32
-6
lines changed Original file line number Diff line number Diff line change 33from ophyd_async .core import PathProvider , StaticPathProvider , UUIDFilenameProvider
44from ophyd_async .epics .adsimdetector import SimDetector
55
6- from dodal .beamlines . dm_demo import DeviceManager
6+ from dodal .device_manager import DeviceManager
77from dodal .common .beamlines .beamline_utils import set_beamline as set_utils_beamline
88from dodal .common .beamlines .device_helpers import DET_SUFFIX , HDF5_SUFFIX
99from dodal .devices .motors import XThetaStage
Original file line number Diff line number Diff line change 1010from ophyd_async .plan_stubs import ensure_connected
1111
1212from dodal .beamlines import all_beamline_names , module_name_for_beamline
13- from dodal .beamlines . dm_demo import DeviceManager
13+ from dodal .device_manager import DeviceManager
1414from dodal .common .beamlines .beamline_utils import set_path_provider
1515from dodal .utils import AnyDevice , filter_ophyd_devices , make_all_devices
1616
Original file line number Diff line number Diff line change @@ -184,6 +184,7 @@ def build(
184184 )
185185 if devices .errors :
186186 # TODO: NotBuilt?
187+ print (devices .errors )
187188 raise Exception ("??? build" )
188189 else :
189190 if connect_immediately :
@@ -674,6 +675,23 @@ def unknown():
674675 return "unknown device"
675676
676677
678+ @devices .factory
679+ def one (): ...
680+
681+
682+ @devices .factory
683+ def two (one ): ...
684+
685+
686+ @devices .factory
687+ def three (one , two ): ...
688+
689+
690+ @devices .factory
691+ def four (one , two , three ):
692+ return 4
693+
694+
677695others = DeviceManager ()
678696
679697
@@ -746,9 +764,17 @@ def old_motor(motor: EpicsMotor, foo: int = 42):
746764
747765 # print(base_x())
748766
749- res = devices .build_all (fixtures = {"path_provider" : "nt_path_provider" })
750- print (res )
751- conn = res .connect ()
752- print (conn )
767+ # res = devices.build_all(fixtures={"path_provider": "nt_path_provider"})
768+ # print(res)
769+ # conn = res.connect()
770+ # print(conn)
771+
772+ # res = four.build()
773+ # print(res)
753774
754775 # devices.build_devices(circ_1, circ_2)
776+
777+ # print(old_motor.dependencies)
778+ print (old_motor .build (mock = False ))
779+
780+ # res = others.build_all()
You can’t perform that action at this time.
0 commit comments