aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugeniy E. Mikhailov <evgmik@gmail.com>2021-06-17 18:22:45 -0400
committerEugeniy E. Mikhailov <evgmik@gmail.com>2021-06-17 18:22:45 -0400
commit6c26c69fa254124c5665f8b8d4496b62e8eda94a (patch)
treefacd6f275d6393271b3562ec81ec81d93c44ab1d
parent987ef732065f1296de45b9b83f0dcce9bd41311b (diff)
downloadpyExpControl-6c26c69fa254124c5665f8b8d4496b62e8eda94a.tar.gz
pyExpControl-6c26c69fa254124c5665f8b8d4496b62e8eda94a.zip
new default for ue9: bipolar ADC regime from -5V to 5V
-rw-r--r--ue9qol.py10
1 files changed, 8 insertions, 2 deletions
diff --git a/ue9qol.py b/ue9qol.py
index 6436552..e95fe6b 100644
--- a/ue9qol.py
+++ b/ue9qol.py
@@ -21,8 +21,14 @@ class UE9qol:
# fixing missing slope for gain '0'
c['AINSlopes']['0']= 0.0000775030
- def getInputCh(self, chNum):
- return self.daq.getAIN(chNum)
+ def getInputCh(self, chNum, BipGain = 8):
+ # BipGain = 8 -> bipolar range (-5V, +5V) gain 1
+ # UE9 default BipGain = 0 -> signal range (0V, +5V) gain 1
+ # other BipGain could be:
+ # 0 = Unipolar Gain 1, 1 = Unipolar Gain 2,
+ # 2 = Unipolar Gain 4, 3 = Unipolar Gain 8,
+ # 8 = Bipolar Gain 1
+ return self.daq.getAIN(chNum, BipGain = BipGain)
def setOutputCh(self, chNum=None, volts=None):
if chNum == None or volts == None: