boot sequence EIVE sys
All checks were successful
EIVE/eive-obsw/pipeline/pr-develop This commit looks good

This commit is contained in:
Robin Müller 2023-03-14 15:08:56 +01:00
parent f8c9ddbc3c
commit dcbf1502a2
No known key found for this signature in database
GPG Key ID: 11D4952C8CCEF814
3 changed files with 20 additions and 3 deletions

View File

@ -15,6 +15,7 @@
#include "fsfw/tasks/TaskFactory.h"
#include "fsfw/version.h"
#include "mission/acsDefs.h"
#include "mission/comDefs.h"
#include "mission/system/tree/system.h"
#include "q7sConfig.h"
#include "watchdog/definitions.h"
@ -116,7 +117,22 @@ void obsw::commandEiveSystemToSafe() {
ReturnValue_t result =
MessageQueueSenderIF::sendMessage(sysQueueId, &msg, MessageQueueIF::NO_QUEUE, false);
if (result != returnvalue::OK) {
sif::error << "Sending safe mode command to EIVE system failed" << std::endl;
sif::error << "obsw: Sending safe mode command to EIVE system failed" << std::endl;
}
}
void obsw::commandComSubsystemRxOnly() {
auto* comSs = ObjectManager::instance()->get<HasModesIF>(objects::COM_SUBSYSTEM);
if (comSs == nullptr) {
sif::error << "obsw: Could not retrieve COM subsystem object" << std::endl;
return;
}
CommandMessage msg;
ModeMessage::setCmdModeMessage(msg, com::RX_ONLY, 0);
ReturnValue_t result = MessageQueueSenderIF::sendMessage(comSs->getCommandQueue(), &msg,
MessageQueueIF::NO_QUEUE, false);
if (result != returnvalue::OK) {
sif::error << "obsw: Sending RX_ONLY mode command to COM subsystem failed" << std::endl;
}
}
@ -127,6 +143,6 @@ void obsw::announceAllModes() {
ReturnValue_t result =
MessageQueueSenderIF::sendMessage(sysQueueId, &msg, MessageQueueIF::NO_QUEUE, false);
if (result != returnvalue::OK) {
sif::error << "Sending safe mode command to EIVE system failed" << std::endl;
sif::error << "obsw: Sending safe mode command to EIVE system failed" << std::endl;
}
}

View File

@ -7,6 +7,7 @@ int obsw(int argc, char* argv[]);
void bootDelayHandling();
void commandEiveSystemToSafe();
void commandComSubsystemRxOnly();
void announceAllModes();
}; // namespace obsw

View File

@ -98,7 +98,6 @@ void buildSafeSequence(Subsystem& ss, ModeListEntry& eh) {
// Build SAFE transition 0.
iht(objects::TCS_SUBSYSTEM, NML, 0, EIVE_TABLE_SAFE_TRANS_0.second);
iht(objects::COM_SUBSYSTEM, com::RX_ONLY, 0, EIVE_TABLE_SAFE_TRANS_0.second);
iht(objects::PL_SUBSYSTEM, OFF, 0, EIVE_TABLE_SAFE_TRANS_0.second);
iht(objects::ACS_SUBSYSTEM, acs::AcsMode::SAFE, 0, EIVE_TABLE_SAFE_TRANS_0.second, true);
check(ss.addTable(TableEntry(EIVE_TABLE_SAFE_TRANS_0.first, &EIVE_TABLE_SAFE_TRANS_0.second)),
@ -192,4 +191,5 @@ void buildBootSequence(Subsystem& ss, ModeListEntry& eh) {
check(ss.addSequence(SequenceEntry(EIVE_SEQUENCE_BOOT.first, &EIVE_SEQUENCE_BOOT.second,
EIVE_SEQUENCE_SAFE.first)),
ctxc);
}
} // namespace