continue TCS mode tree
All checks were successful
EIVE/eive-obsw/pipeline/pr-develop This commit looks good

This commit is contained in:
Robin Müller 2022-11-14 13:46:26 +01:00
parent 859855ed31
commit 24093e13e7
No known key found for this signature in database
GPG Key ID: 11D4952C8CCEF814
4 changed files with 50 additions and 17 deletions

View File

@ -1,2 +1,2 @@
target_sources(${LIB_EIVE_MISSION} PRIVATE acsModeTree.cpp payloadModeTree.cpp tcsModeTree.cpp
system.cpp util.cpp)
target_sources(${LIB_EIVE_MISSION} PRIVATE acsModeTree.cpp payloadModeTree.cpp
tcsModeTree.cpp system.cpp util.cpp)

View File

@ -16,7 +16,7 @@ namespace {
// Alias for checker function
const auto check = subsystem::checkInsert;
void buildOffSequence(Subsystem&ss, ModeListEntry& eh);
void buildOffSequence(Subsystem& ss, ModeListEntry& eh);
void buildDetumbleSequence(Subsystem& ss, ModeListEntry& entryHelper);
void buildSafeSequence(Subsystem& ss, ModeListEntry& entryHelper);
void buildIdleSequence(Subsystem& ss, ModeListEntry& entryHelper);
@ -275,8 +275,8 @@ void buildIdleSequence(Subsystem& ss, ModeListEntry& eh) {
ihs(ACS_SEQUENCE_IDLE.second, ACS_TABLE_IDLE_TGT.first, 0, true);
ihs(ACS_SEQUENCE_IDLE.second, ACS_TABLE_IDLE_TRANS_0.first, 0, true);
ihs(ACS_SEQUENCE_IDLE.second, ACS_TABLE_IDLE_TRANS_1.first, 0, false);
ss.addSequence(&ACS_SEQUENCE_IDLE.second, ACS_SEQUENCE_IDLE.first, ACS_SEQUENCE_SAFE.first,
false, true);
ss.addSequence(&ACS_SEQUENCE_IDLE.second, ACS_SEQUENCE_IDLE.first, ACS_SEQUENCE_SAFE.first, false,
true);
}
void buildIdleChargeSequence(Subsystem& ss, ModeListEntry& eh) {

View File

@ -2,8 +2,10 @@
#include "acsModeTree.h"
#include "payloadModeTree.h"
#include "tcsModeTree.h"
void satsystem::init() {
acs::init();
pl::init();
tcs::init();
}

View File

@ -1,12 +1,43 @@
#include "tcsModeTree.h"
#include "eive/objects.h"
#include "fsfw/devicehandlers/DeviceHandlerIF.h"
#include "fsfw/subsystem/Subsystem.h"
#include "mission/system/tree/util.h"
#include "eive/objects.h"
Subsystem satsystem::tcs::SUBSYSTEM(objects::TCS_SUBSYSTEM, 12, 24);
namespace {
// Alias for checker function
const auto check = subsystem::checkInsert;
void buildOffSequence(Subsystem& ss, ModeListEntry& eh);
void buildNormalSequence(Subsystem& ss, ModeListEntry& eh);
} // namespace
static const auto OFF = HasModesIF::MODE_OFF;
static const auto NML = DeviceHandlerIF::MODE_NORMAL;
auto TCS_SEQUENCE_OFF = std::make_pair(OFF << 24, FixedArrayList<ModeListEntry, 2>());
auto TCS_TABLE_OFF_TGT = std::make_pair((OFF << 24) | 1, FixedArrayList<ModeListEntry, 4>());
auto TCS_TABLE_OFF_TRANS_0 = std::make_pair((OFF << 24) | 2, FixedArrayList<ModeListEntry, 4>());
auto TCS_TABLE_OFF_TRANS_1 = std::make_pair((OFF << 24) | 2, FixedArrayList<ModeListEntry, 4>());
auto TCS_SEQUENCE_NORMAL = std::make_pair(NML << 24, FixedArrayList<ModeListEntry, 2>());
auto TCS_TABLE_NORMAL_TGT = std::make_pair((NML << 24) | 1, FixedArrayList<ModeListEntry, 4>());
auto TCS_TABLE_NORMAL_TRANS_0 = std::make_pair((NML << 24) | 2, FixedArrayList<ModeListEntry, 4>());
auto TCS_TABLE_NORMAL_TRANS_1 = std::make_pair((NML << 24) | 2, FixedArrayList<ModeListEntry, 4>());
void satsystem::tcs::init() {
ModeListEntry entry;
buildOffSequence(SUBSYSTEM, entry);
buildNormalSequence(SUBSYSTEM, entry);
SUBSYSTEM.setInitialMode(OFF);
}
namespace {
void buildOffSequence(Subsystem& ss, ModeListEntry& eh) {}
void buildNormalSequence(Subsystem& ss, ModeListEntry& eh) {}
} // namespace