summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorLennart <lekaiser@uos.de>2020-07-17 12:39:15 +0200
committerLennart <lekaiser@uos.de>2020-07-17 12:39:15 +0200
commit5c4045862bf55be0b8dc755ac3d5c5bd24b5fedf (patch)
treec104a31c95b5a6498f9c195da4cdc406286d9768 /include
parentdd188370afa340d3b717b8747890bc304c0e3346 (diff)
parent52f23fad43b47c6cebb38fa387c39d0e27a12797 (diff)
Merge branch 'master' into state-duration-timers
Diffstat (limited to 'include')
-rw-r--r--include/driver/resistive_load.h35
1 files changed, 35 insertions, 0 deletions
diff --git a/include/driver/resistive_load.h b/include/driver/resistive_load.h
new file mode 100644
index 0000000..74725ac
--- /dev/null
+++ b/include/driver/resistive_load.h
@@ -0,0 +1,35 @@
+#ifndef RESISTIVE_LOAD_H
+#define RESISTIVE_LOAD_H
+
+/*
+ * Resistance at 25°c
+ * R1: 986R
+ * R2: 3K25
+ * R3: 46K3
+ * R4: 9K86
+ */
+
+class ResistiveLoad {
+ private:
+ ResistiveLoad(const ResistiveLoad &copy);
+
+ public:
+ ResistiveLoad() {}
+ void setup();
+ void switchToNone();
+ void switchTo750(); // 576R (R1 || R2)
+ void switchTo1K0(); // 986R (R1)
+ void switchTo2K4(); // 2K44 (R2 || 4)
+ void switchTo3K3(); // 3K25 (R2)
+ void switchTo10K(); // 9K86 (R4)
+ void switchTo47K(); // 46K3 (R3)
+ void nop1K0(unsigned int duration_ms);
+ void nop2K4(unsigned int duration_ms);
+ void nop3K3(unsigned int duration_ms);
+ void nop10K(unsigned int duration_ms);
+ void nop47K(unsigned int duration_ms);
+};
+
+extern ResistiveLoad resistiveLoad;
+
+#endif