added first startup code version
Some checks failed
EIVE/eive-obsw/pipeline/head There was a failure building this commit

This commit is contained in:
Robin Müller 2022-02-10 16:05:36 +01:00
parent 9313fa4639
commit 00f411eaca
No known key found for this signature in database
GPG Key ID: 71B58F8A3CDFA9AC
2 changed files with 28 additions and 2 deletions

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;