Merge branch 'develop' into meier/pdec-config-persistent
This commit is contained in:
@ -8,7 +8,7 @@
|
||||
#include "eive/definitions.h"
|
||||
#include "fsfw/action/ActionHelper.h"
|
||||
#include "fsfw/action/HasActionsIF.h"
|
||||
#include "fsfw/parameters/HasParametersIF.h"
|
||||
#include "fsfw/parameters/ReceivesParameterMessagesIF.h"
|
||||
#include "fsfw/parameters/ParameterHelper.h"
|
||||
#include "fsfw/objectmanager/SystemObject.h"
|
||||
#include "fsfw/returnvalues/returnvalue.h"
|
||||
@ -17,7 +17,6 @@
|
||||
#include "fsfw/tmtcservices/AcceptsTelecommandsIF.h"
|
||||
#include "fsfw_hal/common/gpio/gpioDefinitions.h"
|
||||
#include "fsfw_hal/linux/gpio/LinuxLibgpioIF.h"
|
||||
#include "mission/utility/GlobalConfigHandler.h"
|
||||
|
||||
struct UioNames {
|
||||
const char* configMemory;
|
||||
@ -47,7 +46,7 @@ struct UioNames {
|
||||
class PdecHandler : public SystemObject,
|
||||
public ExecutableObjectIF,
|
||||
public HasActionsIF,
|
||||
public HasParametersIF {
|
||||
public ReceivesParameterMessagesIF {
|
||||
public:
|
||||
static constexpr dur_millis_t IRQ_TIMEOUT_MS = 500;
|
||||
|
||||
@ -61,10 +60,9 @@ class PdecHandler : public SystemObject,
|
||||
* @param pdecReset GPIO ID of GPIO connected to the reset signal of the PDEC.
|
||||
* @param uioConfigMemory String of uio device file same mapped to the PDEC memory space
|
||||
* @param uioregsiters String of uio device file same mapped to the PDEC register space
|
||||
* @param globalConfigHandler Object ID of global config file handler
|
||||
*/
|
||||
PdecHandler(object_id_t objectId, object_id_t tcDestinationId, LinuxLibgpioIF* gpioComIF,
|
||||
gpioId_t pdecReset, UioNames names, object_id_t globalConfigHandlerId);
|
||||
gpioId_t pdecReset, UioNames names);
|
||||
|
||||
virtual ~PdecHandler();
|
||||
|
||||
@ -98,37 +96,40 @@ class PdecHandler : public SystemObject,
|
||||
static const Event LOST_CARRIER_LOCK_PDEC = MAKE_EVENT(5, severity::INFO);
|
||||
//! [EXPORT] : [COMMENT] Lost bit lock
|
||||
static const Event LOST_BIT_LOCK_PDEC = MAKE_EVENT(6, severity::INFO);
|
||||
static constexpr Event POLL_ERROR_PDEC = event::makeEvent(SUBSYSTEM_ID, 7, severity::MEDIUM);
|
||||
static constexpr Event POLL_SYSCALL_ERROR_PDEC =
|
||||
event::makeEvent(SUBSYSTEM_ID, 7, severity::MEDIUM);
|
||||
static constexpr Event WRITE_SYSCALL_ERROR_PDEC =
|
||||
event::makeEvent(SUBSYSTEM_ID, 8, severity::MEDIUM);
|
||||
|
||||
private:
|
||||
static const uint8_t INTERFACE_ID = CLASS_ID::PDEC_HANDLER;
|
||||
|
||||
static constexpr Modes OP_MODE = Modes::IRQ;
|
||||
|
||||
static const ReturnValue_t ABANDONED_CLTU = MAKE_RETURN_CODE(0xA0);
|
||||
static const ReturnValue_t FRAME_DIRTY = MAKE_RETURN_CODE(0xA1);
|
||||
static const ReturnValue_t ABANDONED_CLTU_RETVAL = MAKE_RETURN_CODE(0xA0);
|
||||
static const ReturnValue_t FRAME_DIRTY_RETVAL = MAKE_RETURN_CODE(0xA1);
|
||||
static const ReturnValue_t FRAME_ILLEGAL_ONE_REASON = MAKE_RETURN_CODE(0xA2);
|
||||
static const ReturnValue_t FRAME_ILLEGAL_MULTIPLE_REASONS = MAKE_RETURN_CODE(0xA2);
|
||||
static const ReturnValue_t AD_DISCARDED_LOCKOUT = MAKE_RETURN_CODE(0xA3);
|
||||
static const ReturnValue_t AD_DISCARDED_WAIT = MAKE_RETURN_CODE(0xA4);
|
||||
static const ReturnValue_t AD_DISCARDED_LOCKOUT_RETVAL = MAKE_RETURN_CODE(0xA3);
|
||||
static const ReturnValue_t AD_DISCARDED_WAIT_RETVAL = MAKE_RETURN_CODE(0xA4);
|
||||
static const ReturnValue_t AD_DISCARDED_NS_VS = MAKE_RETURN_CODE(0xA5);
|
||||
|
||||
//! [EXPORT] : [COMMENT] Received action message with unknown action id
|
||||
static const ReturnValue_t COMMAND_NOT_IMPLEMENTED = MAKE_RETURN_CODE(0xB0);
|
||||
|
||||
static const ReturnValue_t NO_REPORT = MAKE_RETURN_CODE(0xA6);
|
||||
static const ReturnValue_t NO_REPORT_RETVAL = MAKE_RETURN_CODE(0xA6);
|
||||
//! Error in version number and reserved A and B fields
|
||||
static const ReturnValue_t ERROR_VERSION_NUMBER = MAKE_RETURN_CODE(0xA7);
|
||||
static const ReturnValue_t ERROR_VERSION_NUMBER_RETVAL = MAKE_RETURN_CODE(0xA7);
|
||||
//! Illegal combination of bypass and control command flag
|
||||
static const ReturnValue_t ILLEGAL_COMBINATION = MAKE_RETURN_CODE(0xA8);
|
||||
static const ReturnValue_t ILLEGAL_COMBINATION_RETVAL = MAKE_RETURN_CODE(0xA8);
|
||||
//! Spacecraft identifier did not match
|
||||
static const ReturnValue_t INVALID_SC_ID = MAKE_RETURN_CODE(0xA9);
|
||||
static const ReturnValue_t INVALID_SC_ID_RETVAL = MAKE_RETURN_CODE(0xA9);
|
||||
//! VC identifier bits 0 to 4 did not match
|
||||
static const ReturnValue_t INVALID_VC_ID_MSB = MAKE_RETURN_CODE(0xAA);
|
||||
static const ReturnValue_t INVALID_VC_ID_MSB_RETVAL = MAKE_RETURN_CODE(0xAA);
|
||||
//! VC identifier bit 5 did not match
|
||||
static const ReturnValue_t INVALID_VC_ID_LSB = MAKE_RETURN_CODE(0xAB);
|
||||
static const ReturnValue_t INVALID_VC_ID_LSB_RETVAL = MAKE_RETURN_CODE(0xAB);
|
||||
//! N(S) of BC or BD frame not set to all zeros
|
||||
static const ReturnValue_t NS_NOT_ZERO = MAKE_RETURN_CODE(0xAC);
|
||||
static const ReturnValue_t NS_NOT_ZERO_RETVAL = MAKE_RETURN_CODE(0xAC);
|
||||
//! Invalid BC control command
|
||||
static const ReturnValue_t INVALID_BC_CC = MAKE_RETURN_CODE(0xAE);
|
||||
|
||||
@ -246,13 +247,8 @@ class PdecHandler : public SystemObject,
|
||||
|
||||
UioNames uioNames;
|
||||
|
||||
// Object ID of global config file handler
|
||||
object_id_t globalConfigHandlerId;
|
||||
|
||||
ParameterHelper paramHelper;
|
||||
|
||||
GlobalConfigHandler* globalConfigHandler = nullptr;
|
||||
|
||||
PdecConfig pdecConfig;
|
||||
|
||||
/**
|
||||
|
Reference in New Issue
Block a user