19#ifndef SRC_SUPLA_DEVICE_FACTORY_TEST_H_
20#define SRC_SUPLA_DEVICE_FACTORY_TEST_H_
22#include <supla/action_handler.h>
23#include <supla/element.h>
32 TestStage_RegisteredAndReady = 2,
33 TestStage_WaitForCfgButton = 3,
39 TestAction_CfgButtonOnPress = 11000,
40 TestAction_DeviceStatusChange = 11101
48 virtual ~FactoryTest();
52 void handleAction(
int event,
int action)
override;
54 virtual int16_t getManufacturerId();
55 virtual void waitForConfigButtonPress();
56 virtual bool checkTestStep();
58 void setTestFailed(
int reason);
59 void setTestFinished();
60 Supla::TestStage getTestStage()
const;
63 bool testFailed =
false;
64 bool testFinished =
false;
65 bool waitForRegisteredAndReady =
true;
66 bool testingMachineEnabled =
true;
68 uint32_t timeoutS = 30;
69 uint32_t initTimestamp = 0;
70 Supla::TestStage testStage = Supla::TestStage_None;
Definition SuplaDevice.h:93
Definition action_handler.h:21
void iterateAlways() override
Method called on each SuplaDevice iteration.
Definition factory_test.cpp:143
void onInit() override
Third method called on element in SuplaDevice.begin()
Definition factory_test.cpp:43
Base class for all elements of SuplaDevice.
Definition element.h:33