small fix

This commit is contained in:
Robin Müller 2022-11-03 20:57:55 +01:00
parent 9503b2ca93
commit ba70bde3e9
No known key found for this signature in database
GPG Key ID: 11D4952C8CCEF814
3 changed files with 10 additions and 17 deletions

View File

@ -16,7 +16,6 @@ namespace {
// Alias for checker function // Alias for checker function
const auto check = subsystem::checkInsert; const auto check = subsystem::checkInsert;
void checkInsert(ReturnValue_t result, const char* ctx);
void buildOffSequence(Subsystem* ss, ModeListEntry& eh); void buildOffSequence(Subsystem* ss, ModeListEntry& eh);
void buildDetumbleSequence(Subsystem* ss, ModeListEntry& entryHelper); void buildDetumbleSequence(Subsystem* ss, ModeListEntry& entryHelper);
void buildSafeSequence(Subsystem* ss, ModeListEntry& entryHelper); void buildSafeSequence(Subsystem* ss, ModeListEntry& entryHelper);
@ -25,7 +24,6 @@ void buildIdleChargeSequence(Subsystem* ss, ModeListEntry& entryHelper);
void buildTargetPtSequence(Subsystem* ss, ModeListEntry& entryHelper); void buildTargetPtSequence(Subsystem* ss, ModeListEntry& entryHelper);
} // namespace } // namespace
static const auto OFF = HasModesIF::MODE_OFF; static const auto OFF = HasModesIF::MODE_OFF;
static const auto NML = DeviceHandlerIF::MODE_NORMAL; static const auto NML = DeviceHandlerIF::MODE_NORMAL;
@ -390,17 +388,4 @@ void buildTargetPtSequence(Subsystem* ss, ModeListEntry& eh) {
ctxc); ctxc);
} }
void checkInsert(ReturnValue_t result, const char* ctx) {
if (result != returnvalue::OK) {
sif::warning << "satsystem::checkInsert: Insertion failed at " << ctx;
if (result == mapdefs::KEY_ALREADY_EXISTS) {
sif::warning << ": Key already exists" << std::endl;
} else if (result == mapdefs::MAP_FULL) {
sif::warning << ": Map full" << std::endl;
} else {
sif::warning << std::endl;
}
}
}
} // namespace } // namespace

View File

@ -1,11 +1,11 @@
#include "payloadModeTree.h" #include "payloadModeTree.h"
#include "eive/objects.h"
#include <fsfw/devicehandlers/DeviceHandlerIF.h> #include <fsfw/devicehandlers/DeviceHandlerIF.h>
#include <fsfw/modes/HasModesIF.h> #include <fsfw/modes/HasModesIF.h>
#include <fsfw/retval.h> #include <fsfw/retval.h>
#include <fsfw/subsystem/Subsystem.h> #include <fsfw/subsystem/Subsystem.h>
#include "eive/objects.h"
#include "mission/devices/devicedefinitions/payloadPcduDefinitions.h" #include "mission/devices/devicedefinitions/payloadPcduDefinitions.h"
#include "mission/system/objects/PayloadSubsystem.h" #include "mission/system/objects/PayloadSubsystem.h"
#include "mission/system/objects/definitions.h" #include "mission/system/objects/definitions.h"

View File

@ -1,9 +1,17 @@
#include "util.h" #include "util.h"
#include "fsfw/container/FixedMap.h"
#include "fsfw/serviceinterface.h" #include "fsfw/serviceinterface.h"
void subsystem::checkInsert(ReturnValue_t result, const char* ctx) { void subsystem::checkInsert(ReturnValue_t result, const char* ctx) {
if (result != returnvalue::OK) { if (result != returnvalue::OK) {
sif::warning << "satsystem::checkInsert: Insertion failed at " << ctx << std::endl; sif::warning << "satsystem::checkInsert: Insertion failed at " << ctx;
if (result == mapdefs::KEY_ALREADY_EXISTS) {
sif::warning << ": Key already exists" << std::endl;
} else if (result == mapdefs::MAP_FULL) {
sif::warning << ": Map full" << std::endl;
} else {
sif::warning << std::endl;
}
} }
} }