Une horloge à afficheurs 7 segments

Dependencies:   BSP_DISCO_F746NG

Committer:
sol427
Date:
Mon Jun 22 16:33:43 2020 +0000
Revision:
4:06a5a25319d5
Horloge fonctionnelle

Who changed what in which revision?

UserRevisionLine numberNew contents of line
sol427 4:06a5a25319d5 1 #ifndef VIEW_H
sol427 4:06a5a25319d5 2 #define VIEW_H
sol427 4:06a5a25319d5 3 #include "mbed.h"
sol427 4:06a5a25319d5 4 #include "button.h"
sol427 4:06a5a25319d5 5 #include "horloge.h"
sol427 4:06a5a25319d5 6 #include "stm32746g_discovery_lcd.h"
sol427 4:06a5a25319d5 7 #include <list>
sol427 4:06a5a25319d5 8
sol427 4:06a5a25319d5 9 #define SCREENWIDTH 480
sol427 4:06a5a25319d5 10 #define SCREENHEIGHT 272
sol427 4:06a5a25319d5 11
sol427 4:06a5a25319d5 12 class View
sol427 4:06a5a25319d5 13 {
sol427 4:06a5a25319d5 14 public:
sol427 4:06a5a25319d5 15 View(int width = SCREENWIDTH, int height = SCREENHEIGHT, uint32_t bgColor = LCD_COLOR_WHITE);
sol427 4:06a5a25319d5 16 void contain(int x, int y);
sol427 4:06a5a25319d5 17 void drawStatic();
sol427 4:06a5a25319d5 18 void drawDynamic();
sol427 4:06a5a25319d5 19 void updateHorloge();
sol427 4:06a5a25319d5 20
sol427 4:06a5a25319d5 21 private :
sol427 4:06a5a25319d5 22 int16_t m_width = SCREENWIDTH;
sol427 4:06a5a25319d5 23 int16_t m_height = SCREENHEIGHT;
sol427 4:06a5a25319d5 24 uint32_t m_bgColor = LCD_COLOR_BLACK;
sol427 4:06a5a25319d5 25 list <Button> m_buttonList;
sol427 4:06a5a25319d5 26 uint8_t m_horlogeX;
sol427 4:06a5a25319d5 27 uint8_t m_reveilX;
sol427 4:06a5a25319d5 28 Horloge h;
sol427 4:06a5a25319d5 29
sol427 4:06a5a25319d5 30 };
sol427 4:06a5a25319d5 31
sol427 4:06a5a25319d5 32 #endif