Smart Home Controller
Dependencies: TS_DISCO_F746NG mbed LCD_DISCO_F746NG BSP_DISCO_F746NG sMotor
Diff: main.cpp
- Revision:
- 3:ffdd4d778110
- Parent:
- 2:2f4e4558277c
--- a/main.cpp Wed Jan 09 09:15:41 2019 +0000 +++ b/main.cpp Wed Jan 09 12:58:26 2019 +0000 @@ -1,8 +1,8 @@ #include "mbed.h" -#include "stdio.h" #include "TS_DISCO_F746NG.h" #include "LCD_DISCO_F746NG.h" #include "sMotor.h" +#include "Draw.h" // Devices LCD_DISCO_F746NG lcd; @@ -11,6 +11,7 @@ int step_speed = 2200; int numstep = 1; DigitalOut led(D8); +Draw draw; int main() { @@ -71,7 +72,9 @@ // Button 3 if ((TS_State.touchDetected) && (TS_State.touchX[0] > 240) && (TS_State.touchX[0] < 320) && (TS_State.touchY[0] > 190 )) { - + lcd.Clear(LCD_COLOR_RED); + lcd.DrawBitmap(0, 0, (uint8_t *)draw.GetStarWars()); + wait(5); } // Button 4