Demonstration of mbed os Threading capabilities using LPC4337 board and the general purpose shield

Dependencies:   ST7567

Files at this revision

API Documentation at this revision

Comitter:
uLipe
Date:
Mon Sep 19 22:52:06 2016 +0000
Parent:
1:b4065d4d692a
Commit message:
fix on acc task

Changed in this revision

main.cpp Show annotated file Show diff for this revision Revisions of this file
diff -r b4065d4d692a -r 8595c827daa9 main.cpp
--- a/main.cpp	Mon Sep 19 21:01:30 2016 +0000
+++ b/main.cpp	Mon Sep 19 22:52:06 2016 +0000
@@ -74,7 +74,9 @@
     i2c_reg_buffer[1] = 0x28;    
     imu_comm->write(BMI160_ADDR, i2c_reg_buffer, sizeof(i2c_reg_buffer), false);
  
-    for(;;) {      
+    for(;;) { 
+        int err = 0;
+         
         /* reads status register */
         i2c_reg_buffer[0] = 0x1B;
         err = imu_comm->write(BMI160_ADDR, i2c_reg_buffer, 1, true);