Good posture sensor

Dependencies:   MMA8451Q mbed

Fork of FRDM_MMA8451Q by mbed official

Files at this revision

API Documentation at this revision

Comitter:
mfed1
Date:
Thu May 02 09:10:49 2013 +0000
Parent:
7:70775be9f474
Child:
9:6bc7c9ece653
Commit message:
coordinate output

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/main.cpp	Tue Feb 19 23:46:45 2013 +0000
+++ b/main.cpp	Thu May 02 09:10:49 2013 +0000
@@ -11,8 +11,14 @@
 
     while (true) {
         rled = 1.0 - abs(acc.getAccX());
+        printf(" X ");
+        printf("%f",acc.getAccX());
         gled = 1.0 - abs(acc.getAccY());
+        printf(" Y ");
+        printf("%f",acc.getAccY());
         bled = 1.0 - abs(acc.getAccZ());
+        printf(" Z ");
+        printf("%f\r",acc.getAccZ());
         wait(0.1);
     }
 }