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.
Dependencies: C12832 MMA7660 mbed
Diff: accel.cpp
- Revision:
- 5:614e3ac042df
- Parent:
- 4:d61f6d186db0
- Child:
- 9:35c816293400
diff -r d61f6d186db0 -r 614e3ac042df accel.cpp
--- a/accel.cpp Wed Mar 07 10:57:16 2018 +0000
+++ b/accel.cpp Wed Mar 14 11:15:31 2018 +0000
@@ -11,7 +11,15 @@
Zaxis_n = 0;
}
-static void _Process(void) {
+static void _ProcessInitialize(void) {
+
+}
+
+static bool _ProcessIsContinue(void) {
+ return false;
+}
+
+static void _ProcessRunning(void) {
Zaxis_p = MMA.z();
Zaxis_n = -MMA.z();
}
@@ -20,4 +28,6 @@
_Initialize();
}
-COMMAND_DEFINE Command_accel = {"accel", 0x02, _Initialize, _Finalize, _Process};
+COMMAND_DEFINE Command_accel = {"accel", 0x02, _Initialize, _Finalize,
+ _ProcessInitialize, _ProcessIsContinue, _ProcessRunning
+};