Improve some jogging docstrings
This commit is contained in:
parent
8478194e30
commit
f1d974c922
2 changed files with 15 additions and 1 deletions
|
|
@ -33,7 +33,11 @@ class RedefinedBaseMovementError(RuntimeError):
|
||||||
|
|
||||||
|
|
||||||
class JogCommand:
|
class JogCommand:
|
||||||
"""A base class for jog operations."""
|
"""A base class for jog operations.
|
||||||
|
|
||||||
|
This class handles threading events used to interrupt previous jog commands. There
|
||||||
|
are two subclasses that are used by jogging `JogMoveCommand` and `JogStopCommand`.
|
||||||
|
"""
|
||||||
|
|
||||||
def __init__(self) -> None:
|
def __init__(self) -> None:
|
||||||
"""Initialise a JogCommand."""
|
"""Initialise a JogCommand."""
|
||||||
|
|
|
||||||
|
|
@ -72,6 +72,16 @@ class DummyStage(BaseStage):
|
||||||
}
|
}
|
||||||
|
|
||||||
def _apply_move(self, displacement: Sequence[int]) -> None:
|
def _apply_move(self, displacement: Sequence[int]) -> None:
|
||||||
|
"""Make a move, this function is designed to be run in a thread by jogging.
|
||||||
|
|
||||||
|
This can't be used for normal movements as the delays setting up the extra
|
||||||
|
threads causes autofucs to fail. As such `_hardware_move_relative` is similarly
|
||||||
|
structured.
|
||||||
|
|
||||||
|
Interrupt this function with the ``self._abort_move`` event.
|
||||||
|
|
||||||
|
:param displacement: The (x, y, z) position.
|
||||||
|
"""
|
||||||
try:
|
try:
|
||||||
fraction_complete = 0.0
|
fraction_complete = 0.0
|
||||||
dt = self.step_time
|
dt = self.step_time
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue