Bugfix record indefinitely
This commit is contained in:
parent
878da3369b
commit
3b2f2f7c41
@ -208,7 +208,7 @@ class Recording:
|
|||||||
|
|
||||||
recstatus = RecordStatus(curT=self.recordedTime, done=False)
|
recstatus = RecordStatus(curT=self.recordedTime, done=False)
|
||||||
|
|
||||||
if self.recordedTime >= self._requiredRecordingLength:
|
if self._requiredRecordingLength is not None and self.recordedTime >= self._requiredRecordingLength:
|
||||||
self._recState = RecordingState.AllDataStored
|
self._recState = RecordingState.AllDataStored
|
||||||
self._stop <<= True
|
self._stop <<= True
|
||||||
recstatus.done = True
|
recstatus.done = True
|
||||||
@ -287,7 +287,7 @@ class Recording:
|
|||||||
with self._rec_mutex:
|
with self._rec_mutex:
|
||||||
if self._recState == RecordingState.Finished:
|
if self._recState == RecordingState.Finished:
|
||||||
raise RuntimeError('Recording has already finished')
|
raise RuntimeError('Recording has already finished')
|
||||||
|
|
||||||
self._h5file.flush()
|
self._h5file.flush()
|
||||||
# Remove indata handler, which also should remove callback function
|
# Remove indata handler, which also should remove callback function
|
||||||
# from StreamMgr. This, however does not have to happen
|
# from StreamMgr. This, however does not have to happen
|
||||||
|
Loading…
Reference in New Issue
Block a user