Library for my home monitoring classes and serial communication protocol. It monitors temperature and movement on the mbed application board.

Dependents:   FinalProject

Revision:
0:3f846fc933a2
Child:
2:84432add9142
diff -r 000000000000 -r 3f846fc933a2 Motion/Motion.h
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/Motion/Motion.h	Sun Sep 01 23:35:18 2013 +0000
@@ -0,0 +1,34 @@
+#ifndef MOTION_H
+#define MOTION_H
+
+#include <vector>
+#include <string>
+#include "HomeMonUtils.h"
+
+struct motion_vec {
+    double x;
+    double y;
+    double z;
+};
+
+class Motion {
+    private: 
+      motion_vec min_motion;
+	  int max_samples_limit;
+      int max_samples;
+	  int sample_ptr;
+      bool wrapped_once;
+      std::vector<std::string> motion_samples;
+
+    public:
+	  Motion();
+      motion_vec get_motion_thresh(void);
+	  bool set_motion_thresh(motion_vec);
+      void add_sample(double motion_sample);
+      const std::vector<std::string> &get_samples();
+	  bool change_max_samples(int);
+	  int get_max_samples();
+
+};
+
+#endif
\ No newline at end of file