diff --git a/build.gradle b/build.gradle index 1898657..97a3e73 100644 --- a/build.gradle +++ b/build.gradle @@ -6,7 +6,7 @@ plugins { import org.redline_rpm.header.Flags allprojects { - version = '2.1.1' + version = '2.1.2' group = 'ch.psi' ext.release = '1' ext.jar_suffix = 'fat' @@ -17,7 +17,7 @@ allprojects { ext.rpm_requires = [] //Not forcing workbench to same version, as it can break other apps. //If specific minimal version is needed then must be specified in project. - ext.workbench_version= '2.1.0' + ext.workbench_version= '2.1.2' repositories { mavenLocal() diff --git a/streamrecorder/src/main/java/ch/psi/streamrecorder/StreamRecorder.java b/streamrecorder/src/main/java/ch/psi/streamrecorder/StreamRecorder.java index b039e05..f09578f 100644 --- a/streamrecorder/src/main/java/ch/psi/streamrecorder/StreamRecorder.java +++ b/streamrecorder/src/main/java/ch/psi/streamrecorder/StreamRecorder.java @@ -19,6 +19,7 @@ import ch.psi.pshell.imaging.Overlay; import ch.psi.pshell.scan.MonitorScan; import ch.psi.pshell.screenpanel.CamServerViewer.SourceSelecionMode; import ch.psi.pshell.screenpanel.Options; +import ch.psi.pshell.sequencer.CommandInfo; import ch.psi.pshell.sequencer.CommandSource; import ch.psi.pshell.swing.DataPanel; import ch.psi.pshell.swing.DeviceValueChart; @@ -355,15 +356,17 @@ public class StreamRecorder extends Panel { } MonitorScan recordingScan; + CommandInfo commandInfo; void startRecording() throws Exception { stopRecording(); - Context.getSequencer().startExecution(CommandSource.plugin, null, cameraName, null, false); + commandInfo = Context.getSequencer().startExecution(CommandSource.plugin, null, cameraName, null, false); Context.getSequencer().setExecutionPar("name", cameraName); Context.getSequencer().setExecutionPar("open", true); recordingScan = new MonitorScan(dataPipeline.getStream(), getReadables(), -1, -1); Threading.getFuture(() -> recordingScan.start()).handle((ret, t) -> { recordingScan = null; + commandInfo = null; return ret; }); String fileName = Context.getSequencer().getExecutionPars().getPath(); @@ -387,9 +390,10 @@ public class StreamRecorder extends Panel { if (recordingScan != null) { logger.info("Stop recording"); recordingScan.abort(); - Context.getSequencer().endExecution(); + Context.getSequencer().endExecution(commandInfo); recordingScan = null; } + commandInfo = null; } void startSrvRecording() throws Exception {