From 0de25bc37cddc63fbb7f83867a786eeb853aff5a Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Tue, 30 Sep 2014 16:09:51 +0200 Subject: Reliable reboot, idle status LED indicator --- gyro.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'gyro.c') diff --git a/gyro.c b/gyro.c index fdf2d1f..ac9ec1c 100644 --- a/gyro.c +++ b/gyro.c @@ -17,6 +17,7 @@ #define L3GD20_CTRLREG1 0x20 #define L3GD20_CTRLREG3 0x22 #define L3GD20_CTRLREG4 0x23 +#define L3GD20_CTRLREG5 0x24 #define L3GD20_OUTZ 0x2c /* raw z value */ @@ -65,6 +66,7 @@ void gyroStart () { puts ("cannot start write"); } sleepwhile (twr.status == TWST_WAIT); + assert (twr.status == TWST_OK); puts ("gyroStart done"); disableWakeup (WAKE_I2C); } -- cgit v1.2.3