dodal.common.signal_utils#

Classes

Functions

create_hardware_backed_soft_signal(datatype, ...)

Creates a soft signal that, when read will call the function passed into get_from_hardware_func and return this.

dodal.common.signal_utils.create_hardware_backed_soft_signal(datatype: type[T], get_from_hardware_func: Callable[[], Coroutine[Any, Any, T]], units: str | None = None, precision: int | None = None)[source]#

Creates a soft signal that, when read will call the function passed into get_from_hardware_func and return this.

This will allow you to make soft signals derived from arbitrary hardware signals. However, calling subscribe on this signal does not give you a sensible value and the signal is currently read only. See bluesky/ophyd-async#525 for a more full solution.

Parameters: