aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--qolab/hardware/lockin/__init__.py2
-rw-r--r--qolab/hardware/lockin/srs_sr865a.py28
2 files changed, 25 insertions, 5 deletions
diff --git a/qolab/hardware/lockin/__init__.py b/qolab/hardware/lockin/__init__.py
index 1385fcb..799da22 100644
--- a/qolab/hardware/lockin/__init__.py
+++ b/qolab/hardware/lockin/__init__.py
@@ -8,7 +8,7 @@ class Lockin(BasicInstrument):
self.config['FnamePrefix'] = 'lockin'
self.config['Device model'] = 'Generic Lockin Without Hardware interface'
self.config['FnamePrefix'] = 'lockin'
- self.deviceProperties = ['FreqInt'];
+ self.deviceProperties = ['FreqInt', 'FreqExt', 'Harm', 'SinAmpl'];
# Minimal set of methods to be implemented.
pass
diff --git a/qolab/hardware/lockin/srs_sr865a.py b/qolab/hardware/lockin/srs_sr865a.py
index 1bddb6d..b20574b 100644
--- a/qolab/hardware/lockin/srs_sr865a.py
+++ b/qolab/hardware/lockin/srs_sr865a.py
@@ -1,9 +1,5 @@
from qolab.hardware.lockin import LockinSCPI
-from qolab.data.trace import Trace
-import re
-import numpy as np
-
class SRS_SR865A(LockinSCPI):
""" SRS SR865A lockin """
def __init__(self, resource):
@@ -20,6 +16,30 @@ class SRS_SR865A(LockinSCPI):
cstr = f'FreqInt {freq}'
rstr = self.write(cstr)
+ # this one has no setter
+ def getFreqExt(self):
+ qstr = f'FreqExt?'
+ rstr = self.query(qstr)
+ return(float(rstr))
+
+ def getHarm(self):
+ qstr = f'Harm?'
+ rstr = self.query(qstr)
+ return(int(rstr))
+
+ def setHarm(self, harm):
+ cstr = f'Harm {harm}'
+ rstr = self.write(cstr)
+
+ def getSinAmpl(self):
+ qstr = f'SLVL?'
+ rstr = self.query(qstr)
+ return(float(rstr))
+
+ def setSinAmpl(self, ampl):
+ cstr = f'SLVL {ampl}'
+ rstr = self.write(cstr)
+
if __name__ == '__main__':
import pyvisa