Replace arduino-timer with PositionWatcher

This commit is contained in:
2025-01-20 22:46:01 +11:00
parent 680b6b3b6a
commit 41af7b508f
10 changed files with 441 additions and 115 deletions

View File

@@ -0,0 +1,33 @@
#ifndef SHADE_COMMAND_H
#define SHADE_COMMAND_H
#include <variant>
#include <stdint.h>
#include <typeindex>
struct OpenCommand {
uint16_t shadeID;
};
struct CloseCommand {
uint16_t shadeID;
};
struct StopCommand {
uint16_t shadeID;
};
struct SetPositionCommand {
uint16_t shadeID;
float percentage;
};
struct RefreshCommand {
uint16_t shadeID;
};
using ShadeCommand = std::variant<OpenCommand, CloseCommand, StopCommand, SetPositionCommand, RefreshCommand>;
#endif // SHADE_COMMAND_H