diff --git a/src/main/java/org/micromanager/lightsheetmanager/model/PLogicDISPIM.java b/src/main/java/org/micromanager/lightsheetmanager/model/PLogicDISPIM.java index c02d116..034f198 100644 --- a/src/main/java/org/micromanager/lightsheetmanager/model/PLogicDISPIM.java +++ b/src/main/java/org/micromanager/lightsheetmanager/model/PLogicDISPIM.java @@ -1128,6 +1128,16 @@ public void setPathPreset(int side) { studio_.logs().showError("Couldn't set the path config " + preset + " of group " + group); } } + + public void stopSPIMStateMachines() { + if (model_.devices().getDeviceAdapter().getMicroscopeGeometry() == GeometryType.SCAPE) { + scanner_.setSPIMState(ASIScanner.SPIMState.IDLE); + } else { + scanner1_.setSPIMState(ASIScanner.SPIMState.IDLE); + scanner2_.setSPIMState(ASIScanner.SPIMState.IDLE); + } + } + } diff --git a/src/main/java/org/micromanager/lightsheetmanager/model/acquisitions/AcquisitionEngine.java b/src/main/java/org/micromanager/lightsheetmanager/model/acquisitions/AcquisitionEngine.java index b623e38..3e5ddea 100644 --- a/src/main/java/org/micromanager/lightsheetmanager/model/acquisitions/AcquisitionEngine.java +++ b/src/main/java/org/micromanager/lightsheetmanager/model/acquisitions/AcquisitionEngine.java @@ -610,6 +610,7 @@ public void close() { // maybe not at all since we move when we switch to setup tab, something else??) if (isUsingPLC) { controller.cleanUpControllerAfterAcquisition(acqSettings_, true); + controller.stopSPIMStateMachines(); } // Restore shutter/autoshutter to original state @@ -1410,6 +1411,7 @@ public void close() { // maybe not at all since we move when we switch to setup tab, something else??) if (isUsingPLC && controller != null) { controller.cleanUpControllerAfterAcquisition(acqSettings_, true); + controller.stopSPIMStateMachines(); } // Restore shutter/autoshutter to original state