From 0bc27ddeae03930deb6106144b49e0614fe002da Mon Sep 17 00:00:00 2001 From: Mike Fiore Date: Wed, 11 Nov 2015 14:24:49 -0600 Subject: add layout for startup screen, tweak main to display startup and sit in loop --- main.cpp | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) (limited to 'main.cpp') diff --git a/main.cpp b/main.cpp index dc78e52..2bf100d 100644 --- a/main.cpp +++ b/main.cpp @@ -1,16 +1,20 @@ +// mbed headers #include "mbed.h" #include "rtos.h" - -#include "DOGS102.h" +// MTS headers +#include "mDot.h" +#include "MTSLog.h" +// sensor headers #include "ISL29011.h" #include "MMA845x.h" #include "MPL3115A2.h" -#include "NCP5623B.h" #include "GPSPARSER.h" -#include "DisplayManager.h" - -#include "mDot.h" -#include "MTSLog.h" +// display headers +#include "DOGS102.h" +#include "NCP5623B.h" +#include "LayoutStartup.h" +// misc heders +#include // LCD and backlight controllers SPI lcd_spi(SPI1_MOSI, SPI1_MISO, SPI1_SCK); @@ -19,7 +23,6 @@ DigitalOut lcd_spi_cs(SPI1_CS, 1); DigitalOut lcd_cd(XBEE_ON_SLEEP, 1); DOGS102* lcd; NCP5623B* lcd_backlight; -DisplayManager* display; // Serial debug port Serial debug(USBTX, USBRX); @@ -30,10 +33,10 @@ int main() { lcd = new DOGS102(lcd_spi, lcd_spi_cs, lcd_cd); lcd_backlight = new NCP5623B(backlight_i2c); - display = new DisplayManager(lcd); - logInfo("starting..."); - display->displaySplashScreen(); + + LayoutStartup ls(lcd); + ls.display(); while (true) { logInfo("in loop"); -- cgit v1.2.3