mpsoc startup command

This commit is contained in:
Jakob Meier
2022-03-30 09:19:30 +02:00
parent 25c3f39c82
commit 2dca9d598d
14 changed files with 571 additions and 414 deletions

View File

@ -1,8 +1,9 @@
#ifndef MISSION_DEVICES_SYRLINKSHKHANDLER_H_
#define MISSION_DEVICES_SYRLINKSHKHANDLER_H_
#include <fsfw/devicehandlers/DeviceHandlerBase.h>
#include <mission/devices/devicedefinitions/SyrlinksDefinitions.h>
#include "devices/powerSwitcherList.h"
#include "fsfw/devicehandlers/DeviceHandlerBase.h"
#include "mission/devices/devicedefinitions/SyrlinksDefinitions.h"
#include <string.h>
/**
@ -15,7 +16,8 @@
*/
class SyrlinksHkHandler : public DeviceHandlerBase {
public:
SyrlinksHkHandler(object_id_t objectId, object_id_t comIF, CookieIF* comCookie);
SyrlinksHkHandler(object_id_t objectId, object_id_t comIF, CookieIF* comCookie,
power::Switch_t powerSwitch);
virtual ~SyrlinksHkHandler();
/**
@ -28,12 +30,16 @@ class SyrlinksHkHandler : public DeviceHandlerBase {
void doShutDown() override;
ReturnValue_t buildNormalDeviceCommand(DeviceCommandId_t* id) override;
ReturnValue_t buildTransitionDeviceCommand(DeviceCommandId_t* id) override;
void fillCommandAndReplyMap() override;
ReturnValue_t buildCommandFromCommand(DeviceCommandId_t deviceCommand, const uint8_t* commandData,
size_t commandDataLen) override;
void fillCommandAndReplyMap() override;
// ReturnValue_t enableReplyInReplyMap(DeviceCommandMap::iterator command,
// uint8_t expectedReplies = 1, bool useAlternateId = false,
// DeviceCommandId_t alternateReplyID = 0) override;
ReturnValue_t scanForReply(const uint8_t* start, size_t remainingSize, DeviceCommandId_t* foundId,
size_t* foundLen) override;
ReturnValue_t interpretDeviceReply(DeviceCommandId_t id, const uint8_t* packet) override;
ReturnValue_t getSwitches(const uint8_t** switches, uint8_t* numberOfSwitches) override;
void setNormalDatapoolEntriesInvalid() override;
uint32_t getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) override;
ReturnValue_t initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
@ -75,6 +81,8 @@ class SyrlinksHkHandler : public DeviceHandlerBase {
SYRLINKS::RxDataset rxDataset;
SYRLINKS::TxDataset txDataset;
const power::Switch_t powerSwitch = power::NO_SWITCH;
uint8_t agcValueHighByte;
uint8_t commandBuffer[SYRLINKS::MAX_COMMAND_SIZE];