Playing around with accelerometer and magnetometer on mbed KL46Z
Dependencies: MAG3110 MMA8451Q PinDetect mbed TSI
Revision 14:1608275a874f, committed 2014-02-10
- Comitter:
- mohammmo
- Date:
- Mon Feb 10 22:52:28 2014 +0000
- Parent:
- 13:921cb2856808
- Commit message:
- add analog input (add also to printf)
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Sat Feb 08 03:02:23 2014 +0000 +++ b/main.cpp Mon Feb 10 22:52:28 2014 +0000 @@ -111,10 +111,11 @@ void printData() { - pc.printf("/%f/%f/%f/%d/%d/%d/%f/%f/%.3f/%.3f/%.3f/%.3f/%d/%d/%d/%d/\r\n", + pc.printf("/%f/%f/%f/%d/%d/%d/%f/%f/%.3f/%.3f/%.3f/%.3f/%d/%d/%d/%d/%f/\r\n", xAcc, yAcc, zAcc, xMag, yMag, zMag, xLight, xTouch, accRate, magRate, lightRate, touchRate, - accEn, magEn, lightEn, touchEn); + accEn, magEn, lightEn, touchEn, + xAin); }