Merge branch 'mueller/master' of https://egit.irs.uni-stuttgart.de/fsfw/fsfw into mueller/master

This commit is contained in:
Robin Müller 2021-01-01 18:03:40 +01:00
commit 3ea763bf34
7 changed files with 28 additions and 35 deletions

View File

@ -1,13 +1,14 @@
target_sources(${TARGET_NAME} target_sources(${LIB_FSFW_NAME} PRIVATE
PRIVATE ipc/missionMessageTypes.cpp
objects/FsfwFactory.cpp
pollingsequence/PollingSequenceFactory.cpp
) )
# Add include paths for the executable # Should be added to include path
target_include_directories(${TARGET_NAME} target_include_directories(${TARGET_NAME} PRIVATE
PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_CURRENT_SOURCE_DIR}
) )
if(NOT DEFINED FSFW_CONFIG_DIRECTORY) if(NOT DEFINED FSFW_CONFIG_DIRECTORY)
set(FSFW_CONFIG_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) set(FSFW_CONFIG_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR})
endif() endif()

View File

@ -1,5 +0,0 @@
#include "logicalAddresses.h"

View File

@ -2,7 +2,7 @@
#define CONFIG_DEVICES_LOGICALADDRESSES_H_ #define CONFIG_DEVICES_LOGICALADDRESSES_H_
#include <fsfw/devicehandlers/CookieIF.h> #include <fsfw/devicehandlers/CookieIF.h>
#include "../objects/systemObjectList.h" #include <objects/systemObjectList.h>
#include <cstdint> #include <cstdint>
/** /**

View File

@ -1,4 +0,0 @@
#include "powerSwitcherList.h"

View File

@ -1,9 +1,5 @@
#include "Factory.h" #include "FsfwFactory.h"
#include "../tmtc/apid.h" #include <OBSWConfig.h>
#include "../tmtc/pusIds.h"
#include "../objects/systemObjectList.h"
#include "../devices/logicalAddresses.h"
#include "../devices/powerSwitcherList.h"
#include <fsfw/devicehandlers/DeviceHandlerBase.h> #include <fsfw/devicehandlers/DeviceHandlerBase.h>
#include <fsfw/events/EventManager.h> #include <fsfw/events/EventManager.h>
@ -11,24 +7,27 @@
#include <fsfw/tmtcpacket/pus/TmPacketStored.h> #include <fsfw/tmtcpacket/pus/TmPacketStored.h>
#include <fsfw/tmtcservices/CommandingServiceBase.h> #include <fsfw/tmtcservices/CommandingServiceBase.h>
#include <fsfw/tmtcservices/PusServiceBase.h> #include <fsfw/tmtcservices/PusServiceBase.h>
#include <internalError/InternalErrorReporter.h> #include <fsfw/internalError/InternalErrorReporter.h>
#include <cstdint> #include <cstdint>
/** /**
* This class should be used to create all system objects required for * This function builds all system objects required for using
* the on-board software, using the object ID list from the configuration * the FSFW. It is recommended to build all other required objects
* folder. * in a function with an identical prototype, call this function in it and
* then pass the function to the object manager so it builds all system
* objects on software startup.
* *
* The objects are registered in the internal object manager automatically. * All system objects are registered in the internal object manager
* This is used later to add objects to tasks. * automatically. The objects should be added to tasks at a later stage, using
* their objects IDs.
* *
* This file also sets static framework IDs. * This function also sets static framework IDs.
* *
* Framework objects are created first. * Framework should be created first before creating mission system objects.
* @ingroup init * @ingroup init
*/ */
void Factory::produce(void) { void Factory::produceFsfwObjects(void) {
setStaticFrameworkObjectIds(); setStaticFrameworkObjectIds();
new EventManager(objects::EVENT_MANAGER); new EventManager(objects::EVENT_MANAGER);
new HealthTable(objects::HEALTH_TABLE); new HealthTable(objects::HEALTH_TABLE);

View File

@ -9,7 +9,7 @@ namespace Factory {
* @brief Creates all SystemObject elements which are persistent * @brief Creates all SystemObject elements which are persistent
* during execution. * during execution.
*/ */
void produce(); void produceFsfwObjects();
void setStaticFrameworkObjectIds(); void setStaticFrameworkObjectIds();
} }

View File

@ -682,8 +682,10 @@ void DeviceHandlerBase::doGetRead() {
replyRawData(receivedData, receivedDataLen, requestedRawTraffic); replyRawData(receivedData, receivedDataLen, requestedRawTraffic);
} }
if (mode == MODE_RAW and defaultRawReceiver != MessageQueueIF::NO_QUEUE) { if (mode == MODE_RAW) {
replyRawReplyIfnotWiretapped(receivedData, receivedDataLen); if (defaultRawReceiver != MessageQueueIF::NO_QUEUE) {
replyRawReplyIfnotWiretapped(receivedData, receivedDataLen);
}
} }
else { else {
parseReply(receivedData, receivedDataLen); parseReply(receivedData, receivedDataLen);