Fix capitalize folder and file name ignored

This commit is contained in:
Phat Nguyen
2024-02-17 17:28:51 +07:00
parent 781fb51c6f
commit 6cdbb8a0a3
24 changed files with 1469 additions and 0 deletions

47
src/Main/PushButton.h Normal file
View File

@ -0,0 +1,47 @@
#ifndef _AIR_GRADIENT_SW_H_
#define _AIR_GRADIENT_SW_H_
#include "BoardDef.h"
#include <Arduino.h>
/**
* @brief The class define how to handle the Push button
*
*/
class PushButton {
public:
/**
* @brief Enum button state
*/
enum State { BUTTON_PRESSED, BUTTON_RELEASED };
#if defined(ESP8266)
void begin(Stream &debugStream);
#else
#endif
PushButton(BoardType type);
void begin(void);
State getState(void);
String toString(State state);
private:
/** BSP constant variable */
const BoardDef *_bsp;
/** Board type */
BoardType _boardType;
/** Is inititalize flag */
bool _isBegin = false;
/** Special variable for ESP8266 */
#if defined(ESP8266)
Stream *_debugStream = nullptr;
const char *TAG = "PushButton";
#else
#endif
/** Method */
bool isBegin(void);
};
#endif /** _AIR_GRADIENT_SW_H_ */