Enable global locking.

This commit:
* switches to the LabThings branch
* enables locking when config files are loaded
* Updates jogging so jog moves aren't subject to the lock, but the jog loop is.
This commit is contained in:
Richard Bowman 2026-04-28 12:11:06 +01:00 committed by Julian Stirling
parent eff66eb667
commit 608f4ec0d5
2 changed files with 9 additions and 2 deletions

View file

@ -404,7 +404,7 @@ class BaseStage(lt.Thing):
"StageThings must define their own _estimate_move_duration method"
)
@lt.action
@lt.action(use_global_lock=False)
def jog(self, stop: bool = False, **kwargs: int) -> None:
"""Make a relative move that may be interrupted by a future ``jog``.
@ -471,7 +471,7 @@ class BaseStage(lt.Thing):
command: Optional[JogCommand] = first_command
# prevent others using the stage while jogging.
with self._hardware_lock:
with self._thing_server_interface.hold_global_lock(True), self._hardware_lock:
while command is not None:
if command.displacement is not None:
self._hardware_start_move_relative(command.displacement)