-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
NVRS add calibration data and sensor HW ID
- Loading branch information
1 parent
fbd6a87
commit 6939d43
Showing
4 changed files
with
99 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
from ..IEEE488 import IEEE488 | ||
|
||
|
||
class TTI1705(IEEE488): | ||
"""TTI 1705.""" | ||
|
||
def __post__(self): | ||
self.inst.read_termination = '\r\n' | ||
|
||
@property | ||
def reading(self): | ||
""".""" | ||
read = self.query_float('READ?') | ||
if 'OVLOAD' in read: | ||
return read | ||
else: | ||
return float(read[0:10]), read[10:].strip() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,70 @@ | ||
from ..Instrument import Instrument | ||
from ..IEEE488 import IEEE488 | ||
from ..SCPI import SCPI | ||
|
||
|
||
class HP8116A(Instrument): | ||
"""HP 8116A, 0 to 50MHz. | ||
.. figure:: images/WaveformGenerator/HP8116A.jpg | ||
""" | ||
""".""" | ||
|
||
pass | ||
# self.amps = [0.01, 7] | ||
# self.freqs = [0, 50e6] | ||
|
||
# ' NO MESSAGE' or ' SYNTAX' on inital or following comms | ||
|
||
def __post__(self): | ||
self.inst.read_termination = '\r\n' | ||
self.inst.write_termination = '\r\n' | ||
|
||
def state(self): | ||
""".""" | ||
print(f"Amplitude: {self.amplitude}") | ||
print(f"Frequency: {self.frequency}") | ||
print(f"Shape: {self.shape}") | ||
# print(f"Load: {self.load}") | ||
# print("Output: {}".format(self.output)) | ||
|
||
@property | ||
def frequency(self): | ||
""".""" | ||
return self.query("IFRQ") | ||
|
||
@frequency.setter | ||
def frequency(self, frequency): | ||
self.write(f"FRQ {frequency} Hz") | ||
|
||
@property | ||
def shape(self): | ||
""".""" | ||
# inst.query('W3') # 0, 1,2,3 DC, Sine, Tri, Square | ||
return NotImplementedError # self.query("SOURce:FUNCtion:SHAPe?") | ||
|
||
@shape.setter | ||
def shape(self, shape="SIN"): | ||
# self.write(f"SOURce:FUNCtion:SHAPe {shape}") | ||
pass | ||
|
||
@property | ||
def amplitude(self): | ||
return self.query("IAMP") | ||
|
||
@amplitude.setter | ||
# @AmplitudeLimiter | ||
def amplitude(self, amplitude: | ||
self.write(f"AMP {amplitude} V") | ||
|
||
@property | ||
def offset(self): | ||
return self.query("IOFS") | ||
|
||
@offset.setter | ||
# @AmplitudeLimiter | ||
def offset(self, amplitude: | ||
self.write(f"OFS {amplitude} V") | ||
|
||
@property | ||
def setup(self): | ||
# ' M1,CT0,T0,W0,H0,A0,L0,C0,D0,FRQ 55.0 HZ,DTY 50 %,WID 500 MS,AMP 1.00 V,OFS 7.50 V,' | ||
return self.query('CST') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters