release
This commit is contained in:
57
src/DisplayManager.h
Normal file
57
src/DisplayManager.h
Normal file
@@ -0,0 +1,57 @@
|
||||
#ifndef DisplayManager_h
|
||||
#define DisplayManager_h
|
||||
|
||||
#include <Arduino.h>
|
||||
#include <LittleFS.h>
|
||||
|
||||
class DisplayManager_
|
||||
{
|
||||
private:
|
||||
// The pins the buttons are connected to
|
||||
|
||||
DisplayManager_() = default;
|
||||
|
||||
const int BatReadings = 10;
|
||||
uint16_t TotalBatReadings[10];
|
||||
int readIndex = 0;
|
||||
uint16_t total = 0;
|
||||
uint16_t average = 0;
|
||||
const int LDRReadings = 30;
|
||||
uint16_t TotalLDRReadings[30];
|
||||
int sampleIndex = 0;
|
||||
unsigned long previousMillis = 0;
|
||||
const unsigned long interval = 1000;
|
||||
|
||||
public:
|
||||
static DisplayManager_ &getInstance();
|
||||
void setup();
|
||||
void tick();
|
||||
void setSettings();
|
||||
void rightButton();
|
||||
void dismissNotify();
|
||||
void HSVtext(int16_t, int16_t, const char *, bool);
|
||||
void loadApps();
|
||||
void nextApp();
|
||||
void previousApp();
|
||||
void leftButton();
|
||||
void resetTextColor();
|
||||
void gererateTimer(String);
|
||||
void clearMatrix();
|
||||
void selectButton();
|
||||
void selectButtonLong();
|
||||
void setBrightness(uint8_t);
|
||||
void setTextColor(uint16_t color);
|
||||
void setFPS(uint8_t);
|
||||
void MatrixState(bool);
|
||||
void generateNotification(String);
|
||||
void generateCustomPage(uint16_t, String);
|
||||
void printText(int16_t x, int16_t y, const char *text, bool centered);
|
||||
void disableAutoTransition();
|
||||
void enableAutoTransition();
|
||||
void drawGIF(uint16_t x, uint16_t y, fs::File gifFile);
|
||||
void drawJPG(uint16_t x, uint16_t y, fs::File jpgFile);
|
||||
};
|
||||
|
||||
extern DisplayManager_ &DisplayManager;
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user