eive-obsw/linux/payload/FreshSupvHandler.h
Robin Mueller 92071b8e0e
All checks were successful
EIVE/eive-obsw/pipeline/pr-main This commit looks good
first structure
2023-11-09 11:35:28 +01:00

42 lines
1.4 KiB
C++

#ifndef LINUX_PAYLOAD_FRESHSUPVHANDLER_H_
#define LINUX_PAYLOAD_FRESHSUPVHANDLER_H_
#include "fsfw/devicehandlers/FreshDeviceHandlerBase.h"
class FreshSupvHandler : public FreshDeviceHandlerBase {
public:
enum OpCode { DEFAULT_OPERATION = 0, HANDLE_ACTIVE_CMDS = 1 };
FreshSupvHandler(DhbConfig cfg);
/**
* Periodic helper executed function, implemented by child class.
*/
void performDeviceOperation(uint8_t opCode) override;
/**
* Implemented by child class. Handle all command messages which are
* not health, mode, action or housekeeping messages.
* @param message
* @return
*/
ReturnValue_t handleCommandMessage(CommandMessage* message) override;
private:
// HK manager abstract functions.
LocalPoolDataSetBase* getDataSetHandle(sid_t sid) override;
ReturnValue_t initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
LocalDataPoolManager& poolManager) override;
// Mode abstract functions
ReturnValue_t checkModeCommand(Mode_t mode, Submode_t submode,
uint32_t* msToReachTheMode) override;
// Action override. Forward to user.
ReturnValue_t executeAction(ActionId_t actionId, MessageQueueId_t commandedBy,
const uint8_t* data, size_t size) override;
private:
bool transitionActive = false;
};
#endif /* LINUX_PAYLOAD_FRESHSUPVHANDLER_H_ */