Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Revision 9:de758e9f9e8e, committed 2019-11-04
- Comitter:
- HeptaSatTraining2019
- Date:
- Mon Nov 04 16:01:31 2019 +0000
- Parent:
- 7:3a5b7c76eb48
- Commit message:
Changed in this revision
Hepta9axis.cpp | Show annotated file Show diff for this revision Revisions of this file |
diff -r 3a5b7c76eb48 -r de758e9f9e8e Hepta9axis.cpp --- a/Hepta9axis.cpp Thu Aug 29 02:49:27 2019 +0000 +++ b/Hepta9axis.cpp Mon Nov 04 16:01:31 2019 +0000 @@ -46,7 +46,7 @@ n_axis.stop(); double acc_ax = short((xh<<8) | (xl)); - *ax = (acc_ax)*2/32764*9.81; + *ax = -(acc_ax)*2/32764*9.81; //y-axis @@ -67,7 +67,7 @@ n_axis.stop(); double acc_ay = short((yh<<8) | (yl)); - *ay = (acc_ay)*2/32764*9.81; + *ay = -(acc_ay)*2/32764*9.81; //z-axis @@ -88,7 +88,7 @@ n_axis.stop(); double acc_az = short((zh<<8) | (zl)); - *az = (acc_az)*2/32764*(-9.81); + *az = -(acc_az)*2/32764*(-9.81); }