showing the menu on the MCU display
Signed-off-by: Peter Siegmund <developer@mars3142.org>
This commit is contained in:
@@ -9,12 +9,12 @@ namespace MainMenuItem
|
||||
constexpr uint8_t LIGHT = 0;
|
||||
constexpr uint8_t EXTERNAL_DEVICES = 1;
|
||||
constexpr uint8_t SETTINGS = 2;
|
||||
}
|
||||
} // namespace MainMenuItem
|
||||
|
||||
MainMenu::MainMenu(menu_options_t *options) : Menu(options), m_options(options)
|
||||
{
|
||||
addText(MainMenuItem::LIGHT, "Lichtsteuerung");
|
||||
addText(MainMenuItem::EXTERNAL_DEVICES, "externe Geraete");
|
||||
addText(MainMenuItem::EXTERNAL_DEVICES, "Externe Geraete");
|
||||
addText(MainMenuItem::SETTINGS, "Einstellungen");
|
||||
}
|
||||
|
||||
|
@@ -2,8 +2,7 @@
|
||||
|
||||
#include "ui/MainMenu.h"
|
||||
|
||||
#ifdef ESP32
|
||||
#else
|
||||
#ifndef ESP32
|
||||
#include <chrono>
|
||||
#include <thread>
|
||||
#endif
|
||||
@@ -17,7 +16,11 @@ SplashScreen::SplashScreen(menu_options_t *options) : Widget(options->u8g2), m_o
|
||||
void SplashScreen::update(const uint64_t dt)
|
||||
{
|
||||
counter += dt;
|
||||
#ifndef ESP32
|
||||
if (counter > 200000)
|
||||
#else
|
||||
if (counter > 10)
|
||||
#endif
|
||||
{
|
||||
counter = 0;
|
||||
if (m_options && m_options->setScreen)
|
||||
|
Reference in New Issue
Block a user