From 3d617d7397c9b951e2a4b3005e35f4f9192b35fb Mon Sep 17 00:00:00 2001 From: "Michael J. Chudobiak" Date: Thu, 23 Aug 2012 09:50:08 -0400 Subject: warn if I2C bus not available --- i2c.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/i2c.c b/i2c.c index 84a9338..4f1e7cf 100644 --- a/i2c.c +++ b/i2c.c @@ -1,3 +1,4 @@ +#include "globals.h" #include #include #include @@ -22,8 +23,8 @@ void I2C_Write(gulong address, guchar value) int device = open(I2C_BUS, O_RDWR); - // FIXME? if (device == -1) { + g_print_debug("ERROR: could not open I2C bus %s\n", I2C_BUS); return; } -- cgit