WIP: PL PCDU #142

Closed
muellerr wants to merge 118 commits from mueller/plpcdu-sus-updates into develop
2 changed files with 28 additions and 2 deletions
Showing only changes of commit 00f411eaca - Show all commits

View File

@ -1,9 +1,26 @@
#include "PayloadPcduHandler.h"
PayloadPcduHandler::PayloadPcduHandler(object_id_t objectId, object_id_t comIF, CookieIF* cookie)
: DeviceHandlerBase(objectId, comIF, cookie) {}
: DeviceHandlerBase(objectId, comIF, cookie), state(States::ON) {}
void PayloadPcduHandler::doStartUp() {}
void PayloadPcduHandler::doStartUp() {
switch(state) {
case(States::ADC_OFF_PL_OFF): {
break;
}
case(States::SWITCH_ON_RELAY): {
// If necessary, check whether a certain amount of time has elapaed
break;
}
case(States::ADC_OFF_PL_OFF): {
break;
}
case(States::SWITCH_ON_HPA): {
// If necessary, check whether a certain amount of time has elapaed
break;
}
}
}
void PayloadPcduHandler::doShutDown() {}

View File

@ -8,6 +8,15 @@ class PayloadPcduHandler : DeviceHandlerBase {
PayloadPcduHandler(object_id_t objectId, object_id_t comIF, CookieIF* cookie);
private:
enum class States {
ADC_OFF_PL_OFF,
SWITCH_ON_RELAY,
ADC_ON_PL_OFF,
SWITCH_ON_HPA,
ADC_ON_PL_ON
};
States state;
void doStartUp() override;
void doShutDown() override;
ReturnValue_t buildNormalDeviceCommand(DeviceCommandId_t* id) override;