Luke Cartwright / Mbed 2 deprecated ELEC2645_Project_el18loc_nearlythere

Dependencies:   mbed

Revision:
18:204cd747b54a
Child:
19:08862f49cd9e
diff -r 358987e9f30e -r 204cd747b54a Envelope/Envelope.h
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Envelope/Envelope.h	Thu May 21 22:59:59 2020 +0000
@@ -0,0 +1,49 @@
+#ifndef ENVELOPE_H
+#define ENVELOPE_H
+
+#include "mbed.h"
+#include "N5110.h"
+#include "Gamepad.h"
+
+/** Envelope class
+ * @author Luke Cartwright, University of Leeds
+ * @brief converts output to env output
+ * @date May 2020
+*/
+
+class Envelope
+{
+public://-----------------------------------------------------------------------
+//variables
+
+//methods
+    //Methods
+    //Constructor
+    Envelope();
+
+    //Destructior
+    ~Envelope();
+
+    //Modifies input to envelope
+    uint16_t env_in(int a, int d, int s, int r, int in, bool init);
+
+
+private://----------------------------------------------------------------------
+//variables
+    uint16_t out;
+    int samples;
+    //float time;
+    int av; //a volume
+    int dv;
+    int sv;
+    int rv;
+    int a_vec;
+    int d_vec;
+    int r_vec;
+    int at;
+
+//methods
+    int a_vector_calc(int av);
+
+};
+#endif
\ No newline at end of file