@@ -147,16 +147,23 @@ def __init__(self, prefix: str, name: str = "") -> None:
147147 with self .add_children_as_readables (StandardReadableFormat .HINTED_SIGNAL ):
148148 # When explicitly reading run control, the most obvious signal that people will be
149149 # interested in is whether the block is in range or not.
150- self .in_range = epics_signal_r (bool , f"{ prefix } INRANGE" )
150+ self .in_range : SignalR [bool ] = epics_signal_r (bool , f"{ prefix } INRANGE" )
151+ """Whether run-control is currently in-range."""
151152
152- self .low_limit = epics_signal_rw (float , f"{ prefix } LOW" )
153- self .high_limit = epics_signal_rw (float , f"{ prefix } HIGH" )
153+ self .low_limit : SignalRW [float ] = epics_signal_rw (float , f"{ prefix } LOW" )
154+ """Run-control low limit."""
155+ self .high_limit : SignalRW [float ] = epics_signal_rw (float , f"{ prefix } HIGH" )
156+ """Run-control high limit."""
154157
155- self .suspend_if_invalid = epics_signal_rw (bool , f"{ prefix } SOI" )
156- self .enabled = epics_signal_rw (bool , f"{ prefix } ENABLE" )
158+ self .suspend_if_invalid : SignalRW [bool ] = epics_signal_rw (bool , f"{ prefix } SOI" )
159+ """Whether run-control should suspend data collection on invalid values."""
160+ self .enabled : SignalRW [bool ] = epics_signal_rw (bool , f"{ prefix } ENABLE" )
161+ """Run-control enabled."""
157162
158- self .out_time = epics_signal_r (float , f"{ prefix } OUT:TIME" )
159- self .in_time = epics_signal_r (float , f"{ prefix } IN:TIME" )
163+ self .out_time : SignalR [float ] = epics_signal_r (float , f"{ prefix } OUT:TIME" )
164+ """Run-control time outside limits."""
165+ self .in_time : SignalR [float ] = epics_signal_r (float , f"{ prefix } IN:TIME" )
166+ """Run-control time inside limits."""
160167
161168 super ().__init__ (name = name )
162169
@@ -176,9 +183,11 @@ def __init__(self, datatype: type[T], prefix: str, block_name: str) -> None:
176183 """
177184 with self .add_children_as_readables (StandardReadableFormat .HINTED_SIGNAL ):
178185 self .readback : SignalR [T ] = epics_signal_r (datatype , f"{ prefix } CS:SB:{ block_name } " )
186+ """Readback value. This is the hinted signal for a block."""
179187
180188 # Run control doesn't need to be read by default
181- self .run_control = RunControl (f"{ prefix } CS:SB:{ block_name } :RC:" )
189+ self .run_control : RunControl = RunControl (f"{ prefix } CS:SB:{ block_name } :RC:" )
190+ """Run-control settings for this block."""
182191
183192 super ().__init__ (name = block_name )
184193 self .readback .set_name (block_name )
@@ -243,6 +252,7 @@ def plan():
243252 self .setpoint : SignalRW [T ] = epics_signal_rw (
244253 datatype , f"{ prefix } CS:SB:{ block_name } { sp_suffix } "
245254 )
255+ """The setpoint for this block."""
246256
247257 self ._write_config : BlockWriteConfig [T ] = write_config or BlockWriteConfig ()
248258
@@ -360,6 +370,7 @@ def __init__(
360370 self .setpoint_readback : SignalR [T ] = epics_signal_r (
361371 datatype , f"{ prefix } CS:SB:{ block_name } :SP:RBV"
362372 )
373+ """The setpoint-readback for this block."""
363374
364375 super ().__init__ (
365376 datatype = datatype , prefix = prefix , block_name = block_name , write_config = write_config
@@ -413,34 +424,37 @@ def __init__(
413424 ) -> None :
414425 """Create a new motor-record block.
415426
416- The ' BlockMot' object supports motion-specific functionality such as:
427+ The `` BlockMot`` object supports motion-specific functionality such as:
417428
418- - Stopping if a scan is aborted (supports the bluesky 'Stoppable' protocol)
419- - Limit checking (before a move starts - supports the bluesky 'Checkable' protocol)
429+ - Stopping if a scan is aborted (supports the bluesky
430+ :py:obj:`~bluesky.protocols.Stoppable` protocol)
431+ - Limit checking (before a move starts - supports the bluesky
432+ :py:obj:`~bluesky.protocols.Checkable` protocol)
420433 - Automatic calculation of move timeouts based on motor velocity
421434 - Fly scanning
422435
423436 However, it generally relies on the underlying motor being "well-behaved". For example, a
424437 motor which does many retries may exceed the simple default timeout based on velocity (it
425438 is possible to explicitly specify a timeout on set() to override this).
426439
427- Blocks pointing at motors do not take a BlockWriteConfiguration parameter, as these
440+ Blocks pointing at motors do not take a
441+ :py:obj:`~ibex_bluesky_core.devices.block.BlockWriteConfig` parameter, as these
428442 parameters duplicate functionality which already exists in the motor record. The mapping is:
429443
430444 use_completion_callback:
431445 Motors always use completion callbacks to check whether motion has completed. Whether to
432446 wait on that completion callback can be configured by the 'wait' keyword argument on
433447 set().
434448 set_success_func:
435- Use .RDBD and .RTRY to control motor retries if the position has not been reached to
436- within a specified tolerance. Note that motors which retry a lot may exceed the default
437- motion timeout which is calculated based on velocity, distance and acceleration.
449+ Use ``.RDBD`` and ``.RTRY`` to control motor retries if the position has not been
450+ reached to within a specified tolerance. Note that motors which retry a lot may
451+ exceed the default motion timeout which is calculated based on velocity,
452+ distance and acceleration.
438453 set_timeout_s:
439454 A suitable timeout is calculated automatically based on velocity, distance and
440- acceleration as defined on the motor record. This may be overridden by the 'timeout'
441- keyword-argument on set().
455+ acceleration as defined on the motor record.
442456 settle_time_s:
443- Use .DLY on the motor record to configure this.
457+ Use `` .DLY`` on the motor record to configure this.
444458 use_global_moving_flag:
445459 This is unnecessary for a single motor block, as a completion callback will always be
446460 used instead to detect when a single move has finished.
0 commit comments