diff --git a/src/fsfw/objectmanager/ObjectManager.cpp b/src/fsfw/objectmanager/ObjectManager.cpp index 29c1b2fc..5d345a3c 100644 --- a/src/fsfw/objectmanager/ObjectManager.cpp +++ b/src/fsfw/objectmanager/ObjectManager.cpp @@ -109,13 +109,15 @@ void ObjectManager::initialize() { for (auto const& it : objectList) { result = it.second->initialize(); if (result != returnvalue::OK) { -#if FSFW_CPP_OSTREAM_ENABLED == 1 object_id_t var = it.first; +#if FSFW_CPP_OSTREAM_ENABLED == 1 sif::error << "ObjectManager::initialize: Object 0x" << std::hex << std::setw(8) << std::setfill('0') << var << " failed to " "initialize with code 0x" << result << std::dec << std::setfill(' ') << std::endl; +#else + sif::printError("ObjectManager::initialize: Object 0x%08x failed to initialize with code 0x%04x\n", var, result); #endif errorCount++; } @@ -124,6 +126,8 @@ void ObjectManager::initialize() { #if FSFW_CPP_OSTREAM_ENABLED == 1 sif::error << "ObjectManager::ObjectManager: Counted " << errorCount << " failed initializations." << std::endl; +#else + sif::printError("ObjectManager: Counted %d\n", errorCount); #endif } // Init was successful. Now check successful interconnections. diff --git a/src/fsfw/tcdistribution/CcsdsDistributor.cpp b/src/fsfw/tcdistribution/CcsdsDistributor.cpp index 4668a3bc..9c674674 100644 --- a/src/fsfw/tcdistribution/CcsdsDistributor.cpp +++ b/src/fsfw/tcdistribution/CcsdsDistributor.cpp @@ -6,7 +6,7 @@ #include "fsfw/serviceinterface/ServiceInterface.h" #include "fsfw/tmtcpacket/ccsds/SpacePacketReader.h" -#define CCSDS_DISTRIBUTOR_DEBUGGING 0 +#define CCSDS_DISTRIBUTOR_DEBUGGING 1 CcsdsDistributor::CcsdsDistributor(uint16_t setDefaultApid, object_id_t setObjectId, StorageManagerIF* tcStore, MessageQueueIF* queue, @@ -68,9 +68,13 @@ ReturnValue_t CcsdsDistributor::selectDestination(MessageQueueId_t& destId) { handlePacketCheckFailure(result); return result; } -#if FSFW_CPP_OSTREAM_ENABLED == 1 && CCSDS_DISTRIBUTOR_DEBUGGING == 1 +#if CCSDS_DISTRIBUTOR_DEBUGGING == 1 +#if FSFW_CPP_OSTREAM_ENABLED == 1 sif::info << "CCSDSDistributor::selectDestination has packet with APID 0x" << std::hex << currentPacket.getApid() << std::dec << std::endl; +#else + sif::printDebug("CCSDS Distributor: Packet with APID 0x%04x detected\n", currentPacket.getApid()); +#endif #endif auto iter = receiverMap.find(currentPacket.getApid()); if (iter != receiverMap.end()) {