better error msg

This commit is contained in:
Robin Müller 2023-02-12 21:07:11 +01:00
parent 7fae6cbd6d
commit 8b4f73a97b
No known key found for this signature in database
GPG Key ID: 71B58F8A3CDFA9AC

View File

@ -195,9 +195,13 @@ ReturnValue_t SpiComIF::performRegularSendOperation(SpiCookie* spiCookie, const
if (result != returnvalue::OK) { if (result != returnvalue::OK) {
#if FSFW_VERBOSE_LEVEL >= 1 #if FSFW_VERBOSE_LEVEL >= 1
#if FSFW_CPP_OSTREAM_ENABLED == 1 #if FSFW_CPP_OSTREAM_ENABLED == 1
sif::error << "SpiComIF::sendMessage: Failed to lock mutex with code " if (result == MutexIF::MUTEX_TIMEOUT) {
<< "0x" << std::hex << std::setfill('0') << std::setw(4) << result << std::dec sif::error << "SpiComIF::sendMessage: Lock timeout" << std::endl;
<< std::endl; } else {
sif::error << "SpiComIF::sendMessage: Failed to lock mutex with code "
<< "0x" << std::hex << std::setfill('0') << std::setw(4) << result << std::dec
<< std::endl;
}
#else #else
sif::printError("SpiComIF::sendMessage: Failed to lock mutex with code %d\n", result); sif::printError("SpiComIF::sendMessage: Failed to lock mutex with code %d\n", result);
#endif #endif