v1.16.0 #323
@ -1,4 +1,5 @@
|
||||
target_sources(${OBSW_NAME} PRIVATE
|
||||
acsModeTree.cpp
|
||||
CoreController.cpp
|
||||
obsw.cpp
|
||||
InitMission.cpp
|
||||
|
72
bsp_q7s/core/acsModeTree.cpp
Normal file
72
bsp_q7s/core/acsModeTree.cpp
Normal file
@ -0,0 +1,72 @@
|
||||
#include <commonObjects.h>
|
||||
|
||||
#include "acsModeTree.h"
|
||||
#include <fsfw/subsystem/modes/ModeDefinitions.h>
|
||||
#include <fsfw/subsystem/Subsystem.h>
|
||||
#include <fsfw/modes/HasModesIF.h>
|
||||
|
||||
FixedArrayList<ModeListEntry, 2> ACS_SEQUENCE_OFF = FixedArrayList<ModeListEntry, 2>();
|
||||
FixedArrayList<ModeListEntry, 0> ACS_TABLE_OFF_TGT = FixedArrayList<ModeListEntry, 0>();
|
||||
FixedArrayList<ModeListEntry, 6> ACS_TABLE_OFF_TRANS = FixedArrayList<ModeListEntry, 6>();
|
||||
|
||||
static constexpr Mode_t ACS_SEQUENCE_OFF_ID = HasModesIF::MODE_OFF;
|
||||
static constexpr Mode_t ACS_TABLE_OFF_TGT_ID = 0x61000000;
|
||||
static constexpr Mode_t ACS_TABLE_OFF_TRANS_ID = 0x61000001;
|
||||
|
||||
void satsystem::acsSubsystemInit() {
|
||||
ModeListEntry entry;
|
||||
Subsystem *acsSubsystem = new Subsystem(objects::ACS_SUBSYSTEM, objects::EIVE_SYSTEM, 20, 20);
|
||||
buildOffSequence(acsSubsystem, entry);
|
||||
}
|
||||
|
||||
void satsystem::buildOffSequence(Subsystem* ss, ModeListEntry& eh) {
|
||||
// Build OFF target
|
||||
ss->addTable(&ACS_TABLE_OFF_TGT, ACS_TABLE_OFF_TGT_ID, false, true);
|
||||
|
||||
// Build OFF transition
|
||||
eh.setObject(objects::ACS_CONTROLLER);
|
||||
eh.setMode(HasModesIF::MODE_OFF);
|
||||
eh.setSubmode(0);
|
||||
ACS_TABLE_OFF_TRANS.insert(eh);
|
||||
|
||||
eh.setObject(objects::IMTQ_HANDLER);
|
||||
eh.setMode(HasModesIF::MODE_OFF);
|
||||
eh.setSubmode(0);
|
||||
ACS_TABLE_OFF_TRANS.insert(eh);
|
||||
|
||||
eh.setObject(objects::STAR_TRACKER);
|
||||
eh.setMode(HasModesIF::MODE_OFF);
|
||||
eh.setSubmode(0);
|
||||
ACS_TABLE_OFF_TRANS.insert(eh);
|
||||
|
||||
eh.setObject(objects::ACS_BOARD_ASS);
|
||||
eh.setMode(HasModesIF::MODE_OFF);
|
||||
eh.setSubmode(0);
|
||||
ACS_TABLE_OFF_TRANS.insert(eh);
|
||||
|
||||
eh.setObject(objects::SUS_BOARD_ASS);
|
||||
eh.setMode(HasModesIF::MODE_OFF);
|
||||
eh.setSubmode(0);
|
||||
ACS_TABLE_OFF_TRANS.insert(eh);
|
||||
|
||||
eh.setObject(objects::RW_ASS);
|
||||
eh.setMode(HasModesIF::MODE_OFF);
|
||||
eh.setSubmode(0);
|
||||
ACS_TABLE_OFF_TRANS.insert(eh);
|
||||
|
||||
ss->addTable(&ACS_TABLE_OFF_TRANS, ACS_TABLE_OFF_TRANS_ID, false, true);
|
||||
|
||||
// Build OFF sequence
|
||||
eh.setTableId(ACS_TABLE_OFF_TGT_ID);
|
||||
eh.setWaitSeconds(0);
|
||||
eh.setCheckSuccess(false);
|
||||
ACS_SEQUENCE_OFF.insert(eh);
|
||||
|
||||
eh.setTableId(ACS_TABLE_OFF_TRANS_ID);
|
||||
eh.setWaitSeconds(0);
|
||||
eh.setCheckSuccess(false);
|
||||
ACS_SEQUENCE_OFF.insert(eh);
|
||||
|
||||
ss->addSequence(&ACS_SEQUENCE_OFF, ACS_SEQUENCE_OFF_ID, ACS_SEQUENCE_OFF_ID, false, true);
|
||||
ss->setInitialMode(HasModesIF::MODE_OFF);
|
||||
}
|
10
bsp_q7s/core/acsModeTree.h
Normal file
10
bsp_q7s/core/acsModeTree.h
Normal file
@ -0,0 +1,10 @@
|
||||
#include <fsfw/subsystem/modes/ModeDefinitions.h>
|
||||
|
||||
class Subsystem;
|
||||
|
||||
namespace satsystem {
|
||||
|
||||
void acsSubsystemInit();
|
||||
void buildOffSequence(Subsystem* ss, ModeListEntry& entryHelper);
|
||||
|
||||
}
|
@ -97,7 +97,10 @@ enum commonObjects: uint32_t {
|
||||
// 0x73 ('s') for assemblies and system/subsystem components
|
||||
ACS_BOARD_ASS = 0x73000001,
|
||||
SUS_BOARD_ASS = 0x73000002,
|
||||
TCS_BOARD_ASS = 0x73000003
|
||||
TCS_BOARD_ASS = 0x73000003,
|
||||
RW_ASS = 0x73000004,
|
||||
ACS_SUBSYSTEM = 0x73010001,
|
||||
EIVE_SYSTEM = 0x73010000,
|
||||
};
|
||||
}
|
||||
|
||||
|
@ -1 +1 @@
|
||||
Subproject commit 5ad9fb94af3312d29863527106396395f7b808a5
|
||||
Subproject commit 19e8ee90be12f72ceb8c2aefdfd665b5babad417
|
Loading…
Reference in New Issue
Block a user