bec_widgets.widgets.control.device_control.positioner_box#
Submodules#
- bec_widgets.widgets.control.device_control.positioner_box.positioner_box
- bec_widgets.widgets.control.device_control.positioner_box.positioner_box_2d
- bec_widgets.widgets.control.device_control.positioner_box.positioner_box_base
- bec_widgets.widgets.control.device_control.positioner_box.positioner_control_line
Classes#
Simple Widget to control a positioner in box form |
|
Simple Widget to control two positioners in box form |
Package Contents#
- class PositionerBox(parent=None, device: bec_lib.device.Positioner | str | None = None, **kwargs)#
Bases:
bec_widgets.widgets.control.device_control.positioner_box.positioner_box_base.PositionerBoxBaseSimple Widget to control a positioner in box form
Initialize the PositionerBox widget.
- Parameters:
parent – The parent widget.
device (Positioner) – The device to control.
- _device_ui_components(device: str) bec_widgets.widgets.control.device_control.positioner_box.positioner_box_base.DeviceUpdateUIComponents#
- _get_setpoint() float | None#
Get the setpoint of the motor
- force_update_readback()#
- hide_device_selection()#
Hide the device selection
- init_ui()#
Init the ui
- on_device_change(old_device: str, new_device: str)#
Upon changing the device, a check will be performed if the device is a Positioner.
- Parameters:
old_device (str) – The old device name.
new_device (str) – The new device name.
- on_device_readback(msg_content: dict, metadata: dict)#
Callback for device readback.
- Parameters:
msg_content (dict) – The message content.
metadata (dict) – The message metadata.
- on_setpoint_change()#
Change the setpoint for the motor
- on_stop()#
- on_tweak_left()#
Tweak motor left
- on_tweak_right()#
Tweak motor right
- set_positioner(positioner: str | bec_lib.device.Positioner)#
Set the device
- Parameters:
positioner (Positioner | str) – Positioner to set, accepts str or the device
- show_device_selection(value: bool)#
Show the device selection
- Parameters:
value (bool) – Show the device selection
- update_limits(limits: tuple)#
Update limits
- Parameters:
limits (tuple) – Limits of the positioner
- PLUGIN = True#
- RPC = True#
- USER_ACCESS = ['set_positioner', 'attach', 'detach', 'screenshot']#
- device = None#
- device_changed#
- dimensions = (234, 224)#
- position_update#
- property step_size#
Step size for tweak
- ui_file = 'positioner_box.ui'#
- class PositionerBox2D(parent=None, device_hor: bec_lib.device.Positioner | str | None = None, device_ver: bec_lib.device.Positioner | str | None = None, **kwargs)#
Bases:
bec_widgets.widgets.control.device_control.positioner_box.positioner_box_base.PositionerBoxBaseSimple Widget to control two positioners in box form
Initialize the PositionerBox widget.
- Parameters:
parent – The parent widget.
device_hor (Positioner | str) – The first device to control - assigned the horizontal axis.
device_ver (Positioner | str) – The second device to control - assigned the vertical axis.
- _apply_controls_enabled(axis: DeviceId)#
- _device_ui_components(device: str)#
- _device_ui_components_hv(device: DeviceId) bec_widgets.widgets.control.device_control.positioner_box.positioner_box_base.DeviceUpdateUIComponents#
- connect_ui()#
Connect the UI components to signals, data, or routines
- enable_controls_hor() bool#
Persisted switch for horizontal control buttons (tweak/step).
- enable_controls_ver() bool#
Persisted switch for vertical control buttons (tweak/step).
- hide_device_boxes()#
Hide the device selection
- hide_device_selection()#
Hide the device selection
- init_ui()#
Init the ui
- on_device_change_hor(old_device: str, new_device: str)#
Upon changing the device, a check will be performed if the device is a Positioner.
- Parameters:
old_device (str) – The old device name.
new_device (str) – The new device name.
- on_device_change_ver(old_device: str, new_device: str)#
Upon changing the device, a check will be performed if the device is a Positioner.
- Parameters:
old_device (str) – The old device name.
new_device (str) – The new device name.
- on_device_readback_hor(msg_content: dict, metadata: dict)#
Callback for device readback.
- Parameters:
msg_content (dict) – The message content.
metadata (dict) – The message metadata.
- on_device_readback_ver(msg_content: dict, metadata: dict)#
Callback for device readback.
- Parameters:
msg_content (dict) – The message content.
metadata (dict) – The message metadata.
- on_setpoint_change_hor()#
Change the setpoint for device a
- on_setpoint_change_ver()#
Change the setpoint for device b
- on_step_dec_hor()#
Tweak device a down
- on_step_dec_ver()#
Tweak device a down
- on_step_inc_hor()#
Tweak device a up
- on_step_inc_ver()#
Tweak device b up
- on_stop()#
- on_tweak_dec_hor()#
Tweak device a down
- on_tweak_dec_ver()#
Tweak device b down
- on_tweak_inc_hor()#
Tweak device a up
- on_tweak_inc_ver()#
Tweak device a up
- set_positioner_hor(positioner: str | bec_lib.device.Positioner)#
Set the device
- Parameters:
positioner (Positioner | str) – Positioner to set, accepts str or the device
- set_positioner_ver(positioner: str | bec_lib.device.Positioner)#
Set the device
- Parameters:
positioner (Positioner | str) – Positioner to set, accepts str or the device
- show_device_selection(value: bool)#
Show the device selection
- Parameters:
value (bool) – Show the device selection
- step_size_hor()#
Step size for tweak
- step_size_ver()#
Step size for tweak
- update_limits_hor(limits: tuple)#
Update limits
- Parameters:
limits (tuple) – Limits of the positioner
- update_limits_ver(limits: tuple)#
Update limits
- Parameters:
limits (tuple) – Limits of the positioner
- PLUGIN = True#
- RPC = True#
- USER_ACCESS = ['set_positioner_hor', 'set_positioner_ver', 'attach', 'detach', 'screenshot',...#
- device_changed_hor#
- device_changed_ver#
- device_hor = None#
- device_ver = None#
- position_update_hor#
- position_update_ver#
- ui_file = 'positioner_box_2d.ui'#