1
0
mirror of https://github.com/thooge/esp32-nmea2000-obp60.git synced 2025-12-15 06:53:07 +01:00
Files
esp32-nmea2000-obp60/lib/buttontask/GwButtonTask.h

22 lines
432 B
C++

#ifndef _GWBUTTONTASK_H
#define _GWBUTTONTASK_H
#include "GwApi.h"
//task function
void initButtons(GwApi *param);
DECLARE_INITFUNCTION(initButtons);
class IButtonTask : public GwApi::TaskInterfaces::Base
{
public:
typedef enum
{
OFF,
PRESSED,
PRESSED_5, // 5...10s
PRESSED_10 //>10s
} ButtonState;
ButtonState state=OFF;
long pressCount=0;
};
DECLARE_TASKIF(IButtonTask);
#endif