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 1:05bd934b3abd, committed 2010-03-23
- Comitter:
- chris
- Date:
- Tue Mar 23 14:30:39 2010 +0000
- Parent:
- 0:9caf9cb82de0
- Commit message:
Changed in this revision
| main.cpp | Show annotated file Show diff for this revision Revisions of this file |
--- a/main.cpp Sun Feb 21 11:43:09 2010 +0000
+++ b/main.cpp Tue Mar 23 14:30:39 2010 +0000
@@ -1,12 +1,15 @@
-#include "mbed.h"
-#include "LIS302.h"
-
-LIS302 acc(p11, p12, p13, p10); // mosi, miso, clk, ncs
-
-int main() {
-
- for (int i = 0; i < 100; i++) {
- printf("%.2f, %.2f, %.2f\n", acc.x(),acc.y(),acc.z());
- wait(0.1);
- }
-}
+#include "mbed.h"
+#include "LIS302.h"
+
+DigitalOut led (LED1);
+LIS302 acc(p11, p12, p13, p10); // mosi, miso, clk, ncs
+
+int main() {
+
+ for (int i = 0; i < 100; i++) {
+ printf("%.2f, %.2f, %.2f\n", acc.x(),acc.y(),acc.z());
+ wait(0.1);
+ }
+
+ led = 1; // done!
+}