improved events

This commit is contained in:
Marius Eggert 2023-03-24 14:52:26 +01:00
parent dce6323090
commit 41215c9ae9

View File

@ -6,7 +6,7 @@
namespace acs {
// These modes are the submodes of the ACS controller and the modes of the ACS subsystem.
// These modes are the modes of the ACS controller and of the ACS subsystem.
enum AcsMode : Mode_t {
OFF = HasModesIF::MODE_OFF,
SAFE = 10,
@ -19,20 +19,26 @@ enum AcsMode : Mode_t {
enum SafeSubmode : Submode_t { DEFAULT = 0, DETUMBLE = 1 };
// static constexpr uint8_t ACS_SYSTEM_DETUMBLE_SUBMODE = 1;
static const uint8_t SUBSYSTEM_ID = SUBSYSTEM_ID::ACS_SUBSYSTEM;
//!< The limits for the rotation in safe mode were violated.
//! [EXPORT] : [COMMENT] The limits for the rotation in safe mode were violated.
static const Event SAFE_RATE_VIOLATION = MAKE_EVENT(0, severity::MEDIUM);
//!< The system has recovered from a safe rate rotation violation.
//! [EXPORT] : [COMMENT] The system has recovered from a safe rate rotation violation.
static constexpr Event SAFE_RATE_RECOVERY = MAKE_EVENT(1, severity::MEDIUM);
//!< Multiple RWs are invalid, not commandable and therefore higher ACS modes cannot be maintained.
//! [EXPORT] : [COMMENT] Multiple RWs are invalid, uncommandable and therefore higher ACS modes
//! cannot be maintained.
static constexpr Event MULTIPLE_RW_INVALID = MAKE_EVENT(2, severity::HIGH);
//!< MEKF was not able to compute a solution.
//! [EXPORT] : [COMMENT] MEKF was not able to compute a solution.
//! P1: MEKF state on exit
static constexpr Event MEKF_INVALID_INFO = MAKE_EVENT(3, severity::INFO);
//!< MEKF was not able to compute a solution during any pointing ACS mode for a prolonged time.
//! [EXPORT] : [COMMENT] MEKF performed an automatic recovery after detection of nonfinite values.
static constexpr Event MEKF_AUTOMATIC_RECOVERY = MAKE_EVENT(4, severity::INFO);
//! [EXPORT] : [COMMENT] MEKF was not able to compute a solution during any pointing ACS mode for a
//! prolonged time.
static constexpr Event MEKF_INVALID_MODE_VIOLATION = MAKE_EVENT(4, severity::HIGH);
//!< The ACS safe mode controller was not able to compute a solution and has failed.
//! [EXPORT] : [COMMENT] The ACS safe mode controller was not able to compute a solution and has
//! failed.
//! P1: Missing information about magnetic field
//! P2: Missing information about rotational rate
static constexpr Event SAFE_MODE_CONTROLLER_FAILURE = MAKE_EVENT(5, severity::HIGH);
extern const char* getModeStr(AcsMode mode);