File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed
src/mx_bluesky/hyperion/device_setup_plans Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change 1- import json
2-
31import bluesky .plan_stubs as bps
42from dodal .devices .focusing_mirror import (
53 FocusingMirrorWithStripes ,
1715from mx_bluesky .common .utils .utils import (
1816 energy_to_bragg_angle ,
1917)
18+ from mx_bluesky .hyperion .external_interaction .config_server import (
19+ get_hyperion_config_client ,
20+ )
2021
2122MIRROR_VOLTAGE_GROUP = "MIRROR_VOLTAGE_GROUP"
2223DCM_GROUP = "DCM_GROUP"
@@ -27,11 +28,12 @@ def _apply_and_wait_for_voltages_to_settle(
2728 stripe : MirrorStripe ,
2829 mirror_voltages : MirrorVoltages ,
2930):
30- with open (mirror_voltages .voltage_lookup_table_path ) as lut_file :
31- json_obj = json .load (lut_file )
32-
31+ config_server = get_hyperion_config_client ()
32+ config_dict = config_server .get_file_contents (
33+ mirror_voltages .voltage_lookup_table_path , dict
34+ )
3335 # sample mode is the only mode supported
34- sample_data = json_obj ["sample" ]
36+ sample_data = config_dict ["sample" ]
3537 if stripe == MirrorStripe .BARE :
3638 stripe_key = "bare"
3739 elif stripe == MirrorStripe .RHODIUM :
You can’t perform that action at this time.
0 commit comments