aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugeniy E. Mikhailov <evgmik@gmail.com>2021-06-11 22:52:59 -0400
committerEugeniy E. Mikhailov <evgmik@gmail.com>2021-06-11 22:52:59 -0400
commitd5443fbf8d4f1c6131f2430ed36c176be0c029a0 (patch)
treebbf276a5da4ba0b5d6fe612d4512107fff1df441
parent0c60367f237948ba02d1467106489150989393bd (diff)
downloadqolab-d5443fbf8d4f1c6131f2430ed36c176be0c029a0.tar.gz
qolab-d5443fbf8d4f1c6131f2430ed36c176be0c029a0.zip
added dummy UE9 class suitable for debugging without hardware
-rw-r--r--ue9qol.py18
1 files changed, 18 insertions, 0 deletions
diff --git a/ue9qol.py b/ue9qol.py
index 2250f2b..0ce21b8 100644
--- a/ue9qol.py
+++ b/ue9qol.py
@@ -2,6 +2,7 @@ import sys
import traceback
import time # For sleep, clock, time and perf_counter
from datetime import datetime
+import random
import u3
import u6
@@ -35,3 +36,20 @@ class UE9qol:
def close(self):
self.daq.close()
+class UE9qolDummy:
+ # to be used for graphics debugging
+ def __init__(self, debug = False, autoOpen = True, **kargs):
+ # do nothing
+ return
+
+ def getInputCh(self, chNum):
+ return random.normalvariate(chNum, 0.25)
+
+ def setOutputCh(self, chNum=None, volts=None):
+ # do nothing
+ return
+
+ def close(self):
+ # do nothing
+ return
+