-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
59 additions
and
88 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
from ophyd_async.epics.motion import Motor | ||
from ophyd_async.sim import PatternGenerator | ||
|
||
|
||
class SimDetector: | ||
def __init__(self, name: str, motor: Motor, motor_field: str): | ||
self.name = name | ||
self.motor = motor | ||
self.motor_field = motor_field | ||
self.pattern_generator = PatternGenerator( | ||
saturation_exposure_time=0.1, detector_height=100, detector_width=100 | ||
) | ||
|
||
def read(self): | ||
return {self.name: {"value": self.pattern_generator}} | ||
|
||
def describe(self): | ||
return {self.name: {"source": "synthetic", "dtype": "number"}} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
from bluesky.protocols import Movable | ||
from ophyd_async.core import StandardReadable | ||
from ophyd_async.epics.motion import Motor | ||
|
||
|
||
class RasterStage(StandardReadable, Movable): | ||
def __init__(self, prefix: str, name: str = "") -> None: | ||
with self.add_children_as_readables(): | ||
self.offset_in_mm = Motor(prefix + "M1") | ||
self.perp_in_mm = Motor(prefix + "M2") | ||
super().__init__(name) |