aboutsummaryrefslogtreecommitdiff
path: root/lockin.py
diff options
context:
space:
mode:
authorEugeniy E. Mikhailov <evgmik@gmail.com>2021-11-29 11:42:58 -0500
committerEugeniy E. Mikhailov <evgmik@gmail.com>2021-11-29 11:42:58 -0500
commit805e6d96e969546ed6f663931d6fe73a38a9aa24 (patch)
tree9a7ff6ba531cde1e9f547feb984d09edee032e9c /lockin.py
parent5e26df931568559fefc9fac6e2bea39e83df1e76 (diff)
downloadpyExpControl-805e6d96e969546ed6f663931d6fe73a38a9aa24.tar.gz
pyExpControl-805e6d96e969546ed6f663931d6fe73a38a9aa24.zip
tune in initialization
Diffstat (limited to 'lockin.py')
-rw-r--r--lockin.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/lockin.py b/lockin.py
index 0f54e79..18cffb2 100644
--- a/lockin.py
+++ b/lockin.py
@@ -12,13 +12,14 @@ class SCPIinstr:
SCPIinstr(rm.open_resource('TCPIP::192.168.0.2::INSTR'))
"""
def __init__(self, resource):
+ print(resource)
self.resource = resource
# convenience pyvisa functions
self.write = self.resource.write
self.read = self.resource.read
self.query = self.resource.query
- self.query_values = self.resource.query_values
+ #self.query_values = self.resource.query_values
@property
def idn(self):
@@ -68,7 +69,8 @@ class LockIn(SCPIinstr):
LockIn(rm.open_resource('TCPIP::192.168.0.2::INSTR'))
"""
def __init__(self, resource):
- super().__init__(self, resource)
+ super().__init__(resource)
+ self.resource.read_termination='\n'
if __name__ == '__main__':
@@ -79,5 +81,7 @@ if __name__ == '__main__':
lckn = LockIn(instr)
# lckn = LockIn(rm, 'TCPIP::192.168.0.51::INSTR')
print(lckn.query('*idn?'))
+ print(lckn.idn)
+