fixed some message queue includes

This commit is contained in:
2020-09-15 16:42:17 +02:00
parent ad98a63e87
commit 15891b3cf0
14 changed files with 52 additions and 36 deletions

View File

@ -1,5 +1,5 @@
#include "MessageQueue.h"
#include "../../objectmanager/ObjectManagerIF.h"
#include "../../serviceinterface/ServiceInterfaceStream.h"
// TODO I guess we should have a way of checking if we are in an ISR and then
@ -40,7 +40,7 @@ ReturnValue_t MessageQueue::sendToDefaultFrom(MessageQueueMessageIF* message,
}
ReturnValue_t MessageQueue::reply(MessageQueueMessageIF* message) {
if (this->lastPartner != MessageQueueMessageIF::NO_QUEUE) {
if (this->lastPartner != MessageQueueIF::NO_QUEUE) {
return sendMessageFrom(this->lastPartner, message, this->getId());
} else {
return NO_REPLY_PARTNER;
@ -58,8 +58,8 @@ ReturnValue_t MessageQueue::sendMessageFrom(MessageQueueId_t sendTo,
ReturnValue_t MessageQueue::handleSendResult(BaseType_t result, bool ignoreFault) {
if (result != pdPASS) {
if (not ignoreFault) {
InternalErrorReporterIF* internalErrorReporter =
objectManager->get<InternalErrorReporterIF>(
InternalErrorReporterIF* internalErrorReporter = objectManager->
get<InternalErrorReporterIF>(
objects::INTERNAL_ERROR_REPORTER);
if (internalErrorReporter != nullptr) {
internalErrorReporter->queueMessageNotSent();

View File

@ -8,6 +8,7 @@
#include <freertos/FreeRTOS.h>
#include <freertos/queue.h>
#include <fsfw/ipc/MessageQueueMessage.h>
// TODO: this class assumes that MessageQueueId_t is the same size as void*
// (the FreeRTOS handle type), compiler will catch this but it might be nice
@ -139,8 +140,8 @@ protected:
private:
bool defaultDestinationSet = false;
QueueHandle_t handle;
MessageQueueId_t defaultDestination = 0;
MessageQueueId_t lastPartner = 0;
MessageQueueId_t defaultDestination = MessageQueueIF::NO_QUEUE;
MessageQueueId_t lastPartner = MessageQueueIF::NO_QUEUE;
const size_t maxMessageSize;
//! Stores the current system context
CallContext callContext = CallContext::TASK;

View File

@ -1,3 +1,4 @@
#include "../../ipc/MessageQueueSenderIF.h"
#include "../../ipc/QueueFactory.h"
#include "../../osal/FreeRTOS/MessageQueue.h"