From 71a1ac7ec5292fd359949f710220b62ea92d7bfa Mon Sep 17 00:00:00 2001 From: wakonig_k Date: Wed, 19 Aug 2026 10:58:21 +0200 Subject: [PATCH] feat(hexapod): add hexapod configuration and pivot device class --- csaxs_bec/device_configs/user_template.yaml | 106 +++++++++++++++++--- csaxs_bec/devices/epics/hexapod_pivot.py | 9 ++ 2 files changed, 102 insertions(+), 13 deletions(-) create mode 100644 csaxs_bec/devices/epics/hexapod_pivot.py diff --git a/csaxs_bec/device_configs/user_template.yaml b/csaxs_bec/device_configs/user_template.yaml index c8968a3e..c279f293 100644 --- a/csaxs_bec/device_configs/user_template.yaml +++ b/csaxs_bec/device_configs/user_template.yaml @@ -53,16 +53,15 @@ rotx: acceleration: 0.2 user_offset_dir: 1 limits: - - -0.1 - - 0.1 + - -0.1 + - 0.1 onFailure: buffer enabled: true readoutPriority: baseline softwareTrigger: false deviceTags: - user_template - - + ############################################################ #################### npoint motors ######################### ############################################################ @@ -74,8 +73,8 @@ npx: axis_Id: A host: "nPoint000003.psi.ch" limits: - - -50 - - 50 + - -50 + - 50 port: 23 sign: 1 settle_time: 0.1 @@ -93,8 +92,8 @@ npy: axis_Id: B host: "nPoint000003.psi.ch" limits: - - -50 - - 50 + - -50 + - 50 port: 23 sign: 1 settle_time: 0.1 @@ -112,8 +111,8 @@ np2x: axis_Id: A host: "nPoint219026.psi.ch" limits: - - -25 - - 25 + - -25 + - 25 port: 23 sign: 1 settle_time: 0.08 @@ -144,7 +143,7 @@ test_cam_mic: readoutPriority: async deviceTags: - user_template - + ############################################################ ####################### Smaract ############################ ############################################################ @@ -155,8 +154,8 @@ xbpm3x: axis_Id: A host: x12sa-eb-smaract-mcs-04.psi.ch limits: - - -200 - - 200 + - -200 + - 200 port: 5000 sign: -1 # precision: 3 @@ -172,3 +171,84 @@ xbpm3x: bl_smar_stage: 0 deviceTags: - user_template + +############################################################ +####################### Hexapod ############################ +############################################################ +hx: + description: Hexapod translation x + deviceClass: ophyd_devices.EpicsUserMotorVME + deviceConfig: + prefix: X12SA-EH-HXP1:TRX + onFailure: retry + enabled: true + readoutPriority: baseline + softwareTrigger: false + deviceTags: + - user_template +hy: + description: Hexapod translation y + deviceClass: ophyd_devices.EpicsUserMotorVME + deviceConfig: + prefix: X12SA-EH-HXP1:TRY + onFailure: retry + enabled: true + readoutPriority: baseline + softwareTrigger: false + deviceTags: + - user_template +hz: + description: Hexapod translation z + deviceClass: ophyd_devices.EpicsUserMotorVME + deviceConfig: + prefix: X12SA-EH-HXP1:TRZ + onFailure: retry + enabled: true + readoutPriority: baseline + softwareTrigger: false + deviceTags: + - user_template +hrox: + description: Hexapod rotation x + deviceClass: ophyd_devices.EpicsUserMotorVME + deviceConfig: + prefix: X12SA-EH-HXP1:ROX + onFailure: retry + enabled: true + readoutPriority: baseline + softwareTrigger: false + deviceTags: + - user_template +hroy: + description: Hexapod rotation y + deviceClass: ophyd_devices.EpicsUserMotorVME + deviceConfig: + prefix: X12SA-EH-HXP1:ROY + onFailure: retry + enabled: true + readoutPriority: baseline + softwareTrigger: false + deviceTags: + - user_template +hroz: + description: Hexapod rotation z + deviceClass: ophyd_devices.EpicsUserMotorVME + deviceConfig: + prefix: X12SA-EH-HXP1:ROZ + onFailure: retry + enabled: true + readoutPriority: baseline + softwareTrigger: false + deviceTags: + - user_template +hpivot: + description: Hexapod pivot points + deviceClass: csaxs_bec.devices.epics.hexapod_pivot.HexapodPivot + deviceConfig: + prefix: "X12SA-EH-HXP1:" + onFailure: retry + enabled: true + readoutPriority: baseline + softwareTrigger: false + deviceTags: + - user_template diff --git a/csaxs_bec/devices/epics/hexapod_pivot.py b/csaxs_bec/devices/epics/hexapod_pivot.py new file mode 100644 index 00000000..cb76d71b --- /dev/null +++ b/csaxs_bec/devices/epics/hexapod_pivot.py @@ -0,0 +1,9 @@ +from ophyd import Component as Cpt +from ophyd import Device +from ophyd_devices import EpicsSignal + + +class HexapodPivot(Device): + pivot_x = Cpt(EpicsSignal, "PIVOT_X", kind="normal", auto_monitor=True) + pivot_y = Cpt(EpicsSignal, "PIVOT_Y", kind="normal", auto_monitor=True) + pivot_z = Cpt(EpicsSignal, "PIVOT_Z", kind="normal", auto_monitor=True) -- 2.54.0