fix(dxp): fix multiple signals marked as trigger_signals for dxp Falcon, but ophyd only supports 1 trigger signal

This commit is contained in:
2025-06-17 08:05:19 +02:00
committed by Christian Appel
parent 9b2f712044
commit fb58ed50d5
2 changed files with 14 additions and 2 deletions

View File

@ -158,7 +158,7 @@ class EpicsDXPFalconMultiElementSystem(EpicsDXPBaseSystem):
# Acquisition control
erase_all = Cpt(EpicsSignal, "EraseAll")
erase_start = Cpt(EpicsSignal, "EraseStart", put_complete=True, trigger_value=1)
start_all = Cpt(EpicsSignal, "StartAll", put_complete=True, trigger_value=1)
start_all = Cpt(EpicsSignal, "StartAll", put_complete=True)
stop_all = Cpt(EpicsSignal, "StopAll")
# Status
@ -231,7 +231,7 @@ class EpicsDXPMultiElementSystem(_EpicsDXPMultiElementSystem):
# Override some action signals, so calling `set`` method
# returns a waitable Status object. Otherwise the Status object is immediately done.
erase_start = Cpt(EpicsSignal, "EraseStart", put_complete=True, trigger_value=1)
start_all = Cpt(EpicsSignal, "StartAll", put_complete=True, trigger_value=1)
start_all = Cpt(EpicsSignal, "StartAll", put_complete=True)
# mca.EpicsDXPMultiElementSystem maps the EPICS records under wrong names, i.e.
# copy_adcp_ercent_rule, copy_roic_hannel and copy_roie_nergy

View File

@ -99,6 +99,18 @@ def test_falcon(mock_falcon):
]
def test_falcon_trigger(mock_falcon):
"""Test the Falcon device trigger method."""
mock_falcon: TestFalcon
mock_falcon.erase_start.put(0)
assert mock_falcon.erase_start.get() == 0
status = mock_falcon.trigger()
# Tagged trigger value, should be set to 1 when trigger is called
assert mock_falcon.erase_start.get() == 1
assert status.success is True
assert status.done is True
def test_xmap(mock_xmap):
"""Test the xMAP device."""
# Test the default values