Skip to content

Commit a025ccd

Browse files
Merge pull request #118 from ispielma/master
TekScope bug fix
2 parents fa8b457 + fc3aeb9 commit a025ccd

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

labscript_devices/TekScope/blacs_workers.py

+4-2
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@ def transition_to_buffered(self, device_name, h5file, front_panel_values, refres
2727
self.scope_params = labscript_utils.properties.get(
2828
hdf5_file, device_name, 'device_properties'
2929
)
30-
self.scope.dev.timeout = 1000 * self.scope_params.get('timeout', 5)
30+
31+
self.scope.dev.timeout = 1000 * self.scope_params.get('timeout', 5)
3132

3233
self.scope.unlock()
3334
self.scope.set_acquire_state(True)
@@ -61,10 +62,11 @@ def transition_to_manual(self):
6162

6263
# Open the file after download so as not to hog the file lock
6364
with h5py.File(self.h5file, 'r+') as hdf_file:
64-
grp = hdf_file.create_group('/data/traces')
65+
grp = hdf_file.require_group('/data/traces')
6566
print('Saving traces...')
6667
dset = grp.create_dataset(self.device_name, data=data)
6768
dset.attrs.update(wfmp[ch])
69+
6870
print('Done!')
6971
return True
7072

0 commit comments

Comments
 (0)