1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
#ifndef APPS_BACKLIGHT_DIMMING_TIMER_H #define APPS_BACKLIGHT_DIMMING_TIMER_H #include <escher.h> class BacklightDimmingTimer : public Timer { public: BacklightDimmingTimer(); private: constexpr static int k_idleBeforeDimmingDuration = 30*1000; // In miliseconds constexpr static int k_dimBacklightBrightness = 0; bool fire() override; }; #endif