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.
Dependencies: mbed PulseSensor2 SCP1000 mbed-rtos 4DGL-uLCD-SE LSM9DS1_Library_cal PinDetect FatFileSystemCpp GP-20U7
Diff: main.cpp
- Revision:
- 7:fb47593628be
- Parent:
- 6:29ccbdd09706
- Child:
- 20:adb9e6e1ad22
--- a/main.cpp	Wed Mar 25 19:14:35 2020 +0000
+++ b/main.cpp	Wed Mar 25 19:17:28 2020 +0000
@@ -1,4 +1,6 @@
 #include "mbed.h"
+#include "LSM9DS1.h"
+#include "uLCD_4DGL.h"
 
 uLCD_4DGL uLCD(p28, p27, p30);
 LSM9DS1 my_imu(p9, p10, 0xD6, 0x3C);
@@ -8,7 +10,6 @@
 int main() {
     // set up the display
     uLCD.display_control(PORTRAIT);
-    uLCD.cls();
     uLCD.baudrate(BAUD_3000000);
     uLCD.background_color(BLACK);
     uLCD.cls();
@@ -17,7 +18,7 @@
     //set up the imu 
     my_imu.begin();
     if (!my_imu.begin()) {
-        port.printf("Failed to communicate with LSM9DS1.\n");
+        uLCD.printf("Failed to communicate with LSM9DS1.\n");
     }
     my_imu.calibrate();
 
    
