A quick and dirty demo of the Xadow M0 acceleromoeter values displayed on the Xadow OLED 0.96" (using the SSD1308 128x64 OLED Driver with I2C interface library).
Dependencies: mbed SSD1308_128x64_I2C_opt XadowGPS BMP180 ADXL345_I2C MPU9250 USBDevice
Diff: main.cpp
- Revision:
- 7:4931dbfbc042
- Parent:
- 5:50051611b5bd
- Child:
- 8:4e8991196bb8
--- a/main.cpp Tue Jun 12 08:36:39 2018 +0000 +++ b/main.cpp Fri Oct 26 06:35:24 2018 +0000 @@ -65,7 +65,7 @@ if (bmp180.init() != 0) { LOG("Error communicating with BMP180r\n"); } else { - LOG("Initialized BMP180r\n"); + LOG("Initialized BMP180\r\n"); break; } wait(1); @@ -198,6 +198,7 @@ // Serial print and/or display at 1.5 s rate independent of data rates delt_t = t.read_ms() - count; if (delt_t > 1500) { // update LCD once per half-second independent of read rate + LOG("\033[2J"); // ANSI clear screen ESC[2J LOG("ax = %f", 1000*ax); LOG(" ay = %f", 1000*ay); LOG(" az = %f mg\r\n", 1000*az);