In this lab, you will: Construct a prototype

Dependencies:   ADXL362 mbed

Revision:
5:7f4dc37352d7
Parent:
4:7616d6fd81d8
--- a/main.cpp	Tue Feb 27 15:19:12 2018 +0000
+++ b/main.cpp	Thu Mar 01 16:06:44 2018 +0000
@@ -20,7 +20,7 @@
     int countOverThreshHold = 0;
     adxl362_reg_print(1,0); // Test of axdl_reg_print
     wait_ms(1000); // wait so that values can be seen
-    int threshHoldRange = 50; // threshhold difference between avg and read values
+    int threshHoldRange = 30; // threshhold difference between avg and read values
     adxl362_get_average(avg);// Generate an average of what x,y,z are.
     //pc.printf("xAvg = %d yAvg = %d zAvg = %d\r\n",avg[0],avg[1],avg[2]);
     while(1) {
@@ -54,7 +54,7 @@
 
 void adxl362_get_average(int16_t avg[]) {
      // Generate an average of what x,y,z are.
-    int numberOfPolls = 10;
+    int numberOfPolls = 2;
     // reset average back to zero for each
     int tmp[3]; // required because avg was having integer overflow
     tmp[0] = 0;