Dependencies:   mbed PinDetect

Revision:
2:017371e6cb26
Parent:
1:87d535bf8c53
--- a/LSM9DS1.cpp	Mon Oct 26 16:14:04 2015 +0000
+++ b/LSM9DS1.cpp	Mon Feb 04 18:15:03 2019 +0000
@@ -36,7 +36,12 @@
 #define LSM9DS1_COMMUNICATION_TIMEOUT 1000
 
 float magSensitivity[4] = {0.00014, 0.00029, 0.00043, 0.00058};
-extern Serial pc;
+//extern Serial pc;
+#ifndef ULCD_4DGL_H_
+#define ULCD_4DGL_H_
+#include "uLCD_4DGL.h"
+#endif
+extern uLCD_4DGL uLCD;
 
 LSM9DS1::LSM9DS1(PinName sda, PinName scl, uint8_t xgAddr, uint8_t mAddr)
     :i2c(sda, scl)
@@ -170,7 +175,8 @@
     // each device. Store those in a variable so we can return them.
     uint8_t mTest = mReadByte(WHO_AM_I_M);      // Read the gyro WHO_AM_I
     uint8_t xgTest = xgReadByte(WHO_AM_I_XG);   // Read the accel/mag WHO_AM_I
-    pc.printf("%x, %x, %x, %x\n\r", mTest, xgTest, _xgAddress, _mAddress);
+    //pc.printf("%x, %x, %x, %x\n\r", mTest, xgTest, _xgAddress, _mAddress);
+    uLCD.printf("%x, %x, %x, %x\n\r", mTest, xgTest, _xgAddress, _mAddress);
     uint16_t whoAmICombined = (xgTest << 8) | mTest;
     
     if (whoAmICombined != ((WHO_AM_I_AG_RSP << 8) | WHO_AM_I_M_RSP))