-
Notifications
You must be signed in to change notification settings - Fork 5
(#1354) update Hyperion to use the new ApertureScatterguard #1356
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great, thank you, couple of ways to tidy up. I assume you'd missed set_sim_value
, it plays nicely with types :)
tests/conftest.py
Outdated
motor.user_setpoint._backend._set_value(val) # type: ignore | ||
motor.user_readback._backend._set_value(val) # type: ignore |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should: I think it's cleaner to do:
motor.user_setpoint._backend._set_value(val) # type: ignore | |
motor.user_readback._backend._set_value(val) # type: ignore | |
set_sim_value(motor.user_setpoint, val) | |
set_sim_value(motor.user_readback, val) |
Similarly elsewhere in this file
tests/conftest.py
Outdated
ap_sg.aperture.z.user_setpoint._backend._set_value(2) # type: ignore | ||
ap_sg.aperture.z.motor_done_move._backend._set_value(1) # type: ignore |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should: I think you can just set patch_async_motor(ap_sg.aperture.z, 2),
below and then remove these 2 lines
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missed a set_sim_value
, otherwise good, thanks.
Co-authored-by: Dominic Oram <[email protected]>
…Source/1354_update_ap_sg (DiamondLightSource/hyperion#1354) update Hyperion to use the new ApertureScatterguard
Fixes #1354
Link to dodal PR (if required): DiamondLightSource/dodal#509
To test: