diff options
author | Eddy Pedroni <eddy@0xf7.com> | 2022-05-24 11:27:09 +0200 |
---|---|---|
committer | Eddy Pedroni <eddy@0xf7.com> | 2022-05-24 11:27:09 +0200 |
commit | 83e3b55f9986326c213efbdc8ac20559577362c0 (patch) | |
tree | 71b8e9ca1bf8b5adc9cb3baaea9cfc9083aad0e0 /src | |
parent | 9e15bf5b5b0195b4d6be6f00fa3f3349e91f823e (diff) |
Update diagram, added interfaces
Diffstat (limited to 'src')
-rw-r--r-- | src/lab-control/function_generator.py | 23 | ||||
-rw-r--r-- | src/lab-control/oscilloscope.py | 17 |
2 files changed, 40 insertions, 0 deletions
diff --git a/src/lab-control/function_generator.py b/src/lab-control/function_generator.py new file mode 100644 index 0000000..b7b5266 --- /dev/null +++ b/src/lab-control/function_generator.py @@ -0,0 +1,23 @@ +class FunctionGenerator: + FUNCTION_SINE = 0 + FUNCTION_SQUARE = 1 + FUNCTION_SAWTOOTH = 2 + + def __init__(self): + raise Exception("This class should not be instantiated directly, please extend it instead") + + def setOn(self, channel: int) -> None: + pass + + def setOff(self, channel: int) -> None: + pass + + def setFrequency(self, channel: int, frequency: float) -> None: + pass + + def setAmplitude(self, channel: int, amplitude: float) -> None: + pass + + def setFunction(self, channel: int, function: int) -> None: + pass + diff --git a/src/lab-control/oscilloscope.py b/src/lab-control/oscilloscope.py new file mode 100644 index 0000000..a09f8a0 --- /dev/null +++ b/src/lab-control/oscilloscope.py @@ -0,0 +1,17 @@ +class Oscilloscope: + def __init__(self): + raise Exception("This class should not be instantiated directly, please extend it instead") + + def measureAmplitude(self, channel: int) -> float: + pass + + def measurePkToPk(self, channel: int) -> float: + pass + + def measureRMS(self, channel: int) -> float: + pass + + def measureFrequency(self, channel: int) -> float: + pass + + |