Merge remote-tracking branch 'origin/development' into mueller/refactor-tmtc-stack-with-retval-refactoring

This commit is contained in:
Robin Müller 2022-08-22 15:57:22 +02:00
commit 10f34e5a48
No known key found for this signature in database
GPG Key ID: 71B58F8A3CDFA9AC
163 changed files with 397 additions and 569 deletions

View File

@ -10,6 +10,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
# [v6.0.0]
## Changes
## Added
- Add new `UnsignedByteField` class
@ -41,7 +43,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
- HAL Devicehandlers: Periodic printout is run-time configurable now
- `oneShotAction` flag in the `TestTask` class is not static anymore
- `SimpleRingBuffer::writeData` now checks if the amount is larger than the total size of the
Buffer and rejects such writeData calls with `HasReturnvaluesIF::RETURN_FAILED`
Buffer and rejects such writeData calls with `returnvalue::FAILED`
PR: https://egit.irs.uni-stuttgart.de/fsfw/fsfw/pulls/586
- Major update for version handling, using `git describe` to fetch version information with git.
PR: https://egit.irs.uni-stuttgart.de/fsfw/fsfw/pulls/601

View File

@ -14,7 +14,7 @@ FSFW to achieve that. The fsfw uses run-time type information but exceptions are
# Failure Handling
Functions should return a defined `ReturnValue_t` to signal to the caller that something has
gone wrong. Returnvalues must be unique. For this the function `HasReturnvaluesIF::makeReturnCode`
gone wrong. Returnvalues must be unique. For this the function `returnvalue::makeCode`
or the macro `MAKE_RETURN` can be used. The `CLASS_ID` is a unique id for that type of object.
See `returnvalues/FwClassIds` folder. The user can add custom `CLASS_ID`s via the
`fsfwconfig` folder.

View File

@ -144,7 +144,7 @@ ReturnValue_t GyroHandler::initializeLocalDataPool(localpool::DataPool &localDat
new PoolEntry<uint8_t>({0}));
poolManager.subscribeForPeriodicPacket(gyroData.getSid(), false, 4.0, false);
return HasReturnvaluesIF::RETURN_OK;
return returnvalue::OK;
}
```
@ -154,7 +154,7 @@ in any case:
```cpp
PoolReadGuard readHelper(&gyroData);
if(readHelper.getReadResult() == HasReturnvaluesIF::RETURN_OK) {
if(readHelper.getReadResult() == returnvalue::OK) {
if(not gyroData.isValid()) {
gyroData.setValidity(true, true);
}

View File

@ -3,7 +3,7 @@
Returnvalue API
==================
.. doxygenfile:: HasReturnvaluesIF.h
.. doxygenfile:: returnvalue.h
.. _fwclassids:

View File

@ -75,11 +75,11 @@ and the respective source file with sensible default return values:
void TestDeviceHandler::doShutDown() {}
ReturnValue_t TestDeviceHandler::buildNormalDeviceCommand(DeviceCommandId_t* id) {
return HasReturnvaluesIF::RETURN_OK;
return returnvalue::OK;
}
ReturnValue_t TestDeviceHandler::buildTransitionDeviceCommand(DeviceCommandId_t* id) {
return HasReturnvaluesIF::RETURN_OK;
return returnvalue::OK;
}
void TestDeviceHandler::fillCommandAndReplyMap() {}
@ -87,17 +87,17 @@ and the respective source file with sensible default return values:
ReturnValue_t TestDeviceHandler::buildCommandFromCommand(DeviceCommandId_t deviceCommand,
const uint8_t* commandData,
size_t commandDataLen) {
return HasReturnvaluesIF::RETURN_OK;
return returnvalue::OK;
}
ReturnValue_t TestDeviceHandler::scanForReply(const uint8_t* start, size_t remainingSize,
DeviceCommandId_t* foundId, size_t* foundLen) {
return HasReturnvaluesIF::RETURN_OK;
return returnvalue::OK;
}
ReturnValue_t TestDeviceHandler::interpretDeviceReply(DeviceCommandId_t id,
const uint8_t* packet) {
return HasReturnvaluesIF::RETURN_OK;
return returnvalue::OK;
}
uint32_t TestDeviceHandler::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) {
@ -106,5 +106,5 @@ and the respective source file with sensible default return values:
ReturnValue_t TestDeviceHandler::initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
LocalDataPoolManager& poolManager) {
return HasReturnvaluesIF::RETURN_OK;
return returnvalue::OK;
}

View File

@ -18,7 +18,7 @@ Failure Handling
-----------------
Functions should return a defined :cpp:type:`ReturnValue_t` to signal to the caller that something has
gone wrong. Returnvalues must be unique. For this the function :cpp:func:`HasReturnvaluesIF::makeReturnCode`
gone wrong. Returnvalues must be unique. For this the function :cpp:func:`returnvalue::makeCode`
or the :ref:`macro MAKE_RETURN_CODE <retvalapi>` can be used. The ``CLASS_ID`` is a unique ID for that type of object.
See the :ref:`FSFW Class IDs file <fwclassids>`. The user can add custom ``CLASS_ID``\s via the
``fsfwconfig`` folder.

View File

@ -150,7 +150,7 @@ with a housekeeping service command.
new PoolEntry<uint8_t>({0}));
poolManager.subscribeForPeriodicPacket(gyroData.getSid(), false, 4.0, false);
return HasReturnvaluesIF::RETURN_OK;
return returnvalue::OK;
}
Now, if we receive some sensor data and converted them into the right format,
@ -160,7 +160,7 @@ in any case:
.. code-block:: cpp
PoolReadGuard readHelper(&gyroData);
if(readHelper.getReadResult() == HasReturnvaluesIF::RETURN_OK) {
if(readHelper.getReadResult() == returnvalue::OK) {
if(not gyroData.isValid()) {
gyroData.setValidity(true, true);
}

View File

@ -1,7 +1,7 @@
#ifndef POLLINGSEQUENCEFACTORY_H_
#define POLLINGSEQUENCEFACTORY_H_
#include <fsfw/returnvalues/HasReturnvaluesIF.h>
#include <fsfw/returnvalues/returnvalue.h>
class FixedTimeslotTaskIF;

View File

@ -45,7 +45,7 @@ class ActionHelper {
* helper function
* @param queueToUse_ Pointer to the messageQueue to be used, optional
* if queue was set in constructor
* @return Returns RETURN_OK if successful
* @return Returns returnvalue::OK if successful
*/
ReturnValue_t initialize(MessageQueueIF* queueToUse_ = nullptr);
/**
@ -75,7 +75,7 @@ class ActionHelper {
* message to
* @param replyId ID of the executed command
* @param data Pointer to the data
* @return Returns RETURN_OK if successful, otherwise failure code
* @return Returns returnvalue::OK if successful, otherwise failure code
*/
ReturnValue_t reportData(MessageQueueId_t reportTo, ActionId_t replyId, SerializeIF* data,
bool hideSender = false);
@ -86,7 +86,7 @@ class ActionHelper {
* message to
* @param replyId ID of the executed command
* @param data Pointer to the data
* @return Returns RETURN_OK if successful, otherwise failure code
* @return Returns returnvalue::OK if successful, otherwise failure code
*/
ReturnValue_t reportData(MessageQueueId_t reportTo, ActionId_t replyId, const uint8_t* data,
size_t dataSize, bool hideSender = false);

View File

@ -4,7 +4,7 @@
#include "ActionMessage.h"
#include "fsfw/ipc/MessageQueueIF.h"
#include "fsfw/objectmanager/ObjectManagerIF.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
#include "fsfw/serialize/SerializeIF.h"
#include "fsfw/storagemanager/StorageManagerIF.h"

View File

@ -3,7 +3,7 @@
#include "CommandActionHelper.h"
#include "fsfw/ipc/MessageQueueIF.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
/**
* Interface to separate commanding actions of other objects.

View File

@ -5,7 +5,7 @@
#include "ActionMessage.h"
#include "SimpleActionHelper.h"
#include "fsfw/ipc/MessageQueueIF.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
/**
* @brief
@ -53,7 +53,7 @@ class HasActionsIF {
*
* @return
* -@c EXECUTION_FINISHED Finish reply will be generated
* -@c Not RETURN_OK Step failure reply will be generated
* -@c Not returnvalue::OK Step failure reply will be generated
*/
virtual ReturnValue_t executeAction(ActionId_t actionId, MessageQueueId_t commandedBy,
const uint8_t* data, size_t size) = 0;

View File

@ -3,7 +3,7 @@
#include "fsfw/ipc/MessageQueueIF.h"
#include "fsfw/objectmanager/SystemObject.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
#include "fsfw/tasks/ExecutableObjectIF.h"
#include "fsfw/tcdistribution/CFDPDistributor.h"
#include "fsfw/tmtcservices/AcceptsTelecommandsIF.h"

View File

@ -7,7 +7,7 @@
#include <cstdint>
#include "fsfw/returnvalues/FwClassIds.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
namespace cfdp {

View File

@ -36,7 +36,7 @@ class HeaderDeserializer : public RedirectableDataPointerIF, public PduHeaderIF
/**
* This needs to be called before accessing the PDU fields to avoid segmentation faults.
* @return
* - RETURN_OK on parse success
* - returnvalue::OK on parse success
* - returnvalue::FAILED Invalid raw data
* - SerializeIF::BUFFER_TOO_SHORT if buffer is shorter than expected
*/

View File

@ -23,7 +23,7 @@ class Tlv : public TlvIF {
* @param maxSize
* @param streamEndianness
* @return
* - RETURN_OK on success
* - returnvalue::OK on success
* - INVALID_TLV_TYPE
* - SerializeIF returncode on wrong serialization parameters
*/
@ -37,7 +37,7 @@ class Tlv : public TlvIF {
* @param buffer Raw buffer including the size field
* @param size
* @param streamEndianness
* - RETURN_OK on success
* - returnvalue::OK on success
* - INVALID_TLV_TYPE
* - SerializeIF returncode on wrong deserialization parameters
*/

View File

@ -1,7 +1,7 @@
#ifndef FSFW_CONTAINER_ARRAYLIST_H_
#define FSFW_CONTAINER_ARRAYLIST_H_
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
#include "../serialize/SerializeAdapter.h"
#include "../serialize/SerializeIF.h"
@ -183,7 +183,7 @@ class ArrayList {
* @param entry
* @return
* -@c FULL if the List is full
* -@c RETURN_OK else
* -@c returnvalue::OK else
*/
ReturnValue_t insert(T entry) {
if (size >= maxSize_) {

View File

@ -4,7 +4,7 @@
#include <cstddef>
#include <cstring>
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
template <typename T>
class FIFOBase {
@ -20,24 +20,24 @@ class FIFOBase {
/**
* Insert value into FIFO
* @param value
* @return RETURN_OK on success, FULL if full
* @return returnvalue::OK on success, FULL if full
*/
ReturnValue_t insert(T value);
/**
* Retrieve item from FIFO. This removes the item from the FIFO.
* @param value Must point to a valid T
* @return RETURN_OK on success, EMPTY if empty and FAILED if nullptr check failed
* @return returnvalue::OK on success, EMPTY if empty and FAILED if nullptr check failed
*/
ReturnValue_t retrieve(T* value);
/**
* Retrieve item from FIFO without removing it from FIFO.
* @param value Must point to a valid T
* @return RETURN_OK on success, EMPTY if empty and FAILED if nullptr check failed
* @return returnvalue::OK on success, EMPTY if empty and FAILED if nullptr check failed
*/
ReturnValue_t peek(T* value);
/**
* Remove item from FIFO.
* @return RETURN_OK on success, EMPTY if empty
* @return returnvalue::OK on success, EMPTY if empty
*/
ReturnValue_t pop();

View File

@ -4,7 +4,7 @@
#include <type_traits>
#include <utility>
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
#include "ArrayList.h"
/**

View File

@ -100,7 +100,7 @@ class FixedOrderedMultimap {
* @param[in] value Value of the new element
* @param[in/out] (optional) storedValue On success this points to the new value, otherwise a
* nullptr
* @return RETURN_OK if insert was successful, MAP_FULL if no space is available
* @return returnvalue::OK if insert was successful, MAP_FULL if no space is available
*/
ReturnValue_t insert(key_t key, T value, Iterator* storedValue = nullptr);
@ -108,14 +108,14 @@ class FixedOrderedMultimap {
* Used to insert new pair instead of single values
*
* @param pair Pair to be inserted
* @return RETURN_OK if insert was successful, MAP_FULL if no space is available
* @return returnvalue::OK if insert was successful, MAP_FULL if no space is available
*/
ReturnValue_t insert(std::pair<key_t, T> pair);
/***
* Can be used to check if a certain key is in the map
* @param key Key to be checked
* @return RETURN_OK if the key exists KEY_DOES_NOT_EXIST otherwise
* @return returnvalue::OK if the key exists KEY_DOES_NOT_EXIST otherwise
*/
ReturnValue_t exists(key_t key) const;
@ -127,14 +127,14 @@ class FixedOrderedMultimap {
*
* @warning The iterator needs to be valid and dereferenceable
* @param[in/out] iter Pointer to iterator to the element that needs to be ereased
* @return RETURN_OK if erased, KEY_DOES_NOT_EXIST if the there is no element like this
* @return returnvalue::OK if erased, KEY_DOES_NOT_EXIST if the there is no element like this
*/
ReturnValue_t erase(Iterator* iter);
/***
* Used to erase by key
* @param key Key to be erased
* @return RETURN_OK if erased, KEY_DOES_NOT_EXIST if the there is no element like this
* @return returnvalue::OK if erased, KEY_DOES_NOT_EXIST if the there is no element like this
*/
ReturnValue_t erase(key_t key);
@ -160,7 +160,7 @@ class FixedOrderedMultimap {
*
* @param key Key to search for
* @param value Found value
* @return RETURN_OK if it points to the value,
* @return returnvalue::OK if it points to the value,
* KEY_DOES_NOT_EXIST if the key is not in the map
*/
ReturnValue_t find(key_t key, T** value) const;

View File

@ -4,7 +4,7 @@
#include <cmath>
#include "../globalfunctions/CRC.h"
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
#include "../serialize/SerialArrayListAdapter.h"
#include "../serviceinterface/ServiceInterfaceStream.h"
#include "ArrayList.h"

View File

@ -51,7 +51,7 @@ class PlacementFactory {
* This must be called by the user.
*
* @param thisElement Element to be destroyed
* @return RETURN_OK if the element was destroyed, different errors on failure
* @return returnvalue::OK if the element was destroyed, different errors on failure
*/
template <typename T>
ReturnValue_t destroy(T* thisElement) {

View File

@ -3,7 +3,7 @@
#include <cstddef>
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
template <uint8_t N_READ_PTRS = 1>
class RingBufferBase {

View File

@ -47,7 +47,7 @@ class SimpleRingBuffer : public RingBufferBase<> {
* Write to circular buffer and increment write pointer by amount.
* @param data
* @param amount
* @return -@c RETURN_OK if write operation was successful
* @return -@c returnvalue::OK if write operation was successful
* -@c returnvalue::FAILED if
*/
ReturnValue_t writeData(const uint8_t* data, size_t amount);
@ -95,7 +95,7 @@ class SimpleRingBuffer : public RingBufferBase<> {
* If readRemaining was set to true, the true amount read will be assigned
* to the passed value.
* @return
* - @c RETURN_OK if data was read successfully
* - @c returnvalue::OK if data was read successfully
* - @c returnvalue::FAILED if not enough data was available and readRemaining
* was set to false.
*/

View File

@ -7,7 +7,7 @@
#ifndef PLATFORM_WIN
#include <sys/time.h>
#endif
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
#include "fsfw_contrib/sgp4/sgp4unit.h"
class Sgp4Propagator {

View File

@ -9,12 +9,12 @@
#define CCSDSRETURNVALUESIF_H_
#include "dllConf.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
/**
* This is a helper class to collect special return values that come up during CCSDS Handling.
* @ingroup ccsds_handling
*/
class CCSDSReturnValuesIF : public HasReturnvaluesIF {
class CCSDSReturnValuesIF {
public:
static const uint8_t INTERFACE_ID = CLASS_ID::CCSDS_HANDLER_IF; //!< Basic ID of the interface.

View File

@ -51,7 +51,7 @@ class DataLinkLayer : public CCSDSReturnValuesIF {
* This method tries to process a frame that is placed in #frameBuffer.
* The procedures described in the Standard are performed.
* @param length Length of the incoming frame candidate.
* @return @c RETURN_OK on successful handling, otherwise the return codes of the higher
* @return @c returnvalue::OK on successful handling, otherwise the return codes of the higher
* methods.
*/
ReturnValue_t processFrame(uint16_t length);
@ -61,12 +61,12 @@ class DataLinkLayer : public CCSDSReturnValuesIF {
* handle Frames directed to this VC.
* @param virtualChannelId Id of the VC. Shall be smaller than 64.
* @param object Reference to the object that handles the Frame.
* @return @c RETURN_OK on success, @c returnvalue::FAILED otherwise.
* @return @c returnvalue::OK on success, @c returnvalue::FAILED otherwise.
*/
ReturnValue_t addVirtualChannel(uint8_t virtualChannelId, VirtualChannelReceptionIF* object);
/**
* The initialization method calls the @c initialize routine of all virtual channels.
* @return The return code of the first failed VC initialization or @c RETURN_OK.
* @return The return code of the first failed VC initialization or @c returnvalue::OK.
*/
ReturnValue_t initialize();
@ -91,19 +91,19 @@ class DataLinkLayer : public CCSDSReturnValuesIF {
virtualChannels; //!< Map of all virtual channels assigned.
/**
* Method that performs all possible frame validity checks (as specified).
* @return Various error codes or @c RETURN_OK on success.
* @return Various error codes or @c returnvalue::OK on success.
*/
ReturnValue_t frameValidationCheck();
/**
* First method to call.
* Removes start sequence bytes and checks if the complete frame was received.
* SHOULDDO: Maybe handling the start sequence must be done more variable.
* @return @c RETURN_OK or @c TOO_SHORT.
* @return @c returnvalue::OK or @c TOO_SHORT.
*/
ReturnValue_t frameDelimitingAndFillRemoval();
/**
* Small helper method to check the CRC of the Frame.
* @return @c RETURN_OK or @c CRC_FAILED.
* @return @c returnvalue::OK or @c CRC_FAILED.
*/
ReturnValue_t frameCheckCRC();
/**

View File

@ -37,8 +37,8 @@ class Farm1StateOpen : public Farm1StateIF {
* change to Farm1StateLockout.
* @param frame The frame to handle.
* @param clcw Any changes to the CLCW shall be done with the help of this interface.
* @return If the Sequence Number is ok, it returns #RETURN_OK. Otherwise either #NS_POSITIVE_W,
* #NS_NEGATIVE_W or NS_LOCKOUT is returned.
* @return If the Sequence Number is ok, it returns returnvalue::OK. Otherwise either
* #NS_POSITIVE_W, #NS_NEGATIVE_W or NS_LOCKOUT is returned.
*/
ReturnValue_t handleADFrame(TcTransferFrame* frame, ClcwIF* clcw);
/**

View File

@ -5,7 +5,7 @@
#include "dllConf.h"
#include "fsfw/ipc/MessageQueueSenderIF.h"
#include "fsfw/objectmanager/ObjectManagerIF.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
class StorageManagerIF;
@ -36,7 +36,7 @@ class MapPacketExtraction : public MapPacketExtractionIF {
* Method that is called if the segmentation flag is @c NO_SEGMENTATION.
* The method extracts one or more packets within the frame and forwards them to the OBSW.
* @param frame The TC Transfer Frame to work on.
* @return @c RETURN_OK if all Packets were extracted. If something is entirely wrong,
* @return @c returnvalue::OK if all Packets were extracted. If something is entirely wrong,
* @c DATA_CORRUPTED is returned, if some bytes are left over @c RESIDUAL_DATA.
*/
ReturnValue_t unpackBlockingPackets(TcTransferFrame* frame);
@ -63,7 +63,7 @@ class MapPacketExtraction : public MapPacketExtractionIF {
ReturnValue_t extractPackets(TcTransferFrame* frame);
/**
* The #packetStore and the default destination of #tcQueue are initialized here.
* @return @c RETURN_OK on success, @c returnvalue::FAILED otherwise.
* @return @c returnvalue::OK on success, @c returnvalue::FAILED otherwise.
*/
ReturnValue_t initialize();
/**

View File

@ -77,7 +77,7 @@ class VirtualChannelReception : public VirtualChannelReceptionIF, public CCSDSRe
* required.
* @param frame The Tc Transfer Frame to handle.
* @param clcw Any changes on the CLCW shall be done with this method.
* @return Always returns @c RETURN_OK.
* @return Always returns @c returnvalue::OK.
*/
ReturnValue_t handleBDFrame(TcTransferFrame* frame, ClcwIF* clcw);
/**
@ -102,14 +102,14 @@ class VirtualChannelReception : public VirtualChannelReceptionIF, public CCSDSRe
* Helper method to simplify adding a mapChannel during construction.
* @param mapId The mapId of the object to add.
* @param object Pointer to the MapPacketExtraction object itself.
* @return @c RETURN_OK if the channel was successfully inserted, @c returnvalue::FAILED
* @return @c returnvalue::OK if the channel was successfully inserted, @c returnvalue::FAILED
* otherwise.
*/
ReturnValue_t addMapChannel(uint8_t mapId, MapPacketExtractionIF* object);
/**
* The initialization routine checks the set #slidingWindowWidth and initializes all MAP
* channels.
* @return @c RETURN_OK on successful initialization, @c returnvalue::FAILED otherwise.
* @return @c returnvalue::OK on successful initialization, @c returnvalue::FAILED otherwise.
*/
ReturnValue_t initialize();
/**

View File

@ -11,7 +11,7 @@
#include "ClcwIF.h"
#include "TcTransferFrame.h"
#include "dllConf.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
/**
* This is the interface for Virtual Channel reception classes.
@ -33,13 +33,13 @@ class VirtualChannelReceptionIF {
* Handling the Frame includes forwarding to higher-level procedures.
* @param frame The Tc Transfer Frame that was received and checked.
* @param clcw Any changes to the CLCW value are forwarded by using this parameter.
* @return The return Value shall indicate successful processing with @c RETURN_OK.
* @return The return Value shall indicate successful processing with @c returnvalue::OK.
*/
virtual ReturnValue_t frameAcceptanceAndReportingMechanism(TcTransferFrame* frame,
ClcwIF* clcw) = 0;
/**
* If any other System Objects are required for operation they shall be initialized here.
* @return @c RETURN_OK for successful initialization.
* @return @c returnvalue::OK for successful initialization.
*/
virtual ReturnValue_t initialize() = 0;
/**

View File

@ -1,7 +1,7 @@
#ifndef FSFW_DATAPOOL_DATASETIF_H_
#define FSFW_DATAPOOL_DATASETIF_H_
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
#include "../timemanager/Clock.h"
class PoolVariableIF;

View File

@ -58,7 +58,7 @@ class PoolDataSetBase : public PoolDataSetIF, public SerializeIF {
* freed afterwards. It is mandatory to call commit after a read call,
* even if the read operation is not successful!
* @return
* - @c RETURN_OK if all variables were read successfully.
* - @c returnvalue::OK if all variables were read successfully.
* - @c INVALID_PARAMETER_DEFINITION if a pool entry does not exist or there
* is a type conflict.
* - @c SET_WAS_ALREADY_READ if read() is called twice without calling
@ -80,7 +80,7 @@ class PoolDataSetBase : public PoolDataSetIF, public SerializeIF {
* commit() can only be called after read(). If the set only contains
* variables which are write only, commit() can be called without a
* preceding read() call. Every read call must be followed by a commit call!
* @return - @c RETURN_OK if all variables were read successfully.
* @return - @c returnvalue::OK if all variables were read successfully.
* - @c COMMITING_WITHOUT_READING if set was not read yet and
* contains non write-only variables
*/
@ -97,7 +97,7 @@ class PoolDataSetBase : public PoolDataSetIF, public SerializeIF {
/**
* Provides the means to lock the underlying data structure to ensure
* thread-safety. Default implementation is empty
* @return Always returns -@c RETURN_OK
* @return Always returns -@c returnvalue::OK
*/
virtual ReturnValue_t lockDataPool(
MutexIF::TimeoutType timeoutType = MutexIF::TimeoutType::WAITING,
@ -105,7 +105,7 @@ class PoolDataSetBase : public PoolDataSetIF, public SerializeIF {
/**
* Provides the means to unlock the underlying data structure to ensure
* thread-safety. Default implementation is empty
* @return Always returns -@c RETURN_OK
* @return Always returns -@c returnvalue::OK
*/
virtual ReturnValue_t unlockDataPool() override;

View File

@ -1,7 +1,7 @@
#ifndef FSFW_DATAPOOL_POOLVARIABLEIF_H_
#define FSFW_DATAPOOL_POOLVARIABLEIF_H_
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
#include "../serialize/SerializeIF.h"
#include "ReadCommitIF.h"

View File

@ -2,7 +2,7 @@
#define FSFW_DATAPOOL_READCOMMITIF_H_
#include "../ipc/MutexIF.h"
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
/**
* @brief Common interface for all software objects which employ read-commit

View File

@ -2,7 +2,7 @@
#define FSFW_DATAPOOL_READCOMMITIFATTORNEY_H_
#include <fsfw/datapool/ReadCommitIF.h>
#include <fsfw/returnvalues/HasReturnvaluesIF.h>
#include <fsfw/returnvalues/returnvalue.h>
/**
* @brief This class determines which members are allowed to access protected members

View File

@ -4,7 +4,7 @@
#include "MarkChangedIF.h"
#include "fsfw/datapool/PoolVariableIF.h"
#include "fsfw/objectmanager/SystemObjectIF.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
#include "localPoolDefinitions.h"
class LocalDataPoolManager;

View File

@ -4,7 +4,7 @@
#include "fsfw/housekeeping/AcceptsHkPacketsIF.h"
#include "fsfw/ipc/MessageQueueIF.h"
#include "fsfw/ipc/messageQueueDefinitions.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
#include "localPoolDefinitions.h"
namespace subdp {

View File

@ -53,7 +53,7 @@ class AssemblyBase : public SubsystemBase {
* @param mode
* @param submode
* @return
* - @c RETURN_OK if ok
* - @c returnvalue::OK if ok
* - @c NEED_SECOND_STEP if children need to be commanded again
*/
virtual ReturnValue_t commandChildren(Mode_t mode, Submode_t submode) = 0;

View File

@ -1,7 +1,7 @@
#ifndef FSFW_DEVICES_DEVICECOMMUNICATIONIF_H_
#define FSFW_DEVICES_DEVICECOMMUNICATIONIF_H_
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
#include "CookieIF.h"
#include "DeviceHandlerIF.h"
/**
@ -61,7 +61,7 @@ class DeviceCommunicationIF {
* initialization.
* @param cookie
* @return
* - @c RETURN_OK if initialization was successfull
* - @c returnvalue::OK if initialization was successfull
* - Everything else triggers failure event with returnvalue as parameter 1
*/
virtual ReturnValue_t initializeInterface(CookieIF *cookie) = 0;
@ -74,7 +74,7 @@ class DeviceCommunicationIF {
* @param data
* @param len If this is 0, nothing shall be sent.
* @return
* - @c RETURN_OK for successfull send
* - @c returnvalue::OK for successfull send
* - Everything else triggers failure event with returnvalue as parameter 1
*/
virtual ReturnValue_t sendMessage(CookieIF *cookie, const uint8_t *sendData, size_t sendLen) = 0;
@ -84,7 +84,7 @@ class DeviceCommunicationIF {
* Get send confirmation that the data in sendMessage() was sent successfully.
* @param cookie
* @return
* - @c RETURN_OK if data was sent successfully but a reply is expected
* - @c returnvalue::OK if data was sent successfully but a reply is expected
* - NO_REPLY_EXPECTED if data was sent successfully and no reply is expected
* - Everything else to indicate failure
*/
@ -99,7 +99,7 @@ class DeviceCommunicationIF {
*
* @param cookie
* @param requestLen Size of data to read
* @return - @c RETURN_OK to confirm the request for data has been sent.
* @return - @c returnvalue::OK to confirm the request for data has been sent.
* - Everything else triggers failure event with
* returnvalue as parameter 1
*/
@ -113,7 +113,7 @@ class DeviceCommunicationIF {
* @param buffer [out] Set reply here (by using *buffer = ...)
* @param size [out] size pointer to set (by using *size = ...).
* Set to 0 if no reply was received
* @return - @c RETURN_OK for successfull receive
* @return - @c returnvalue::OK for successfull receive
* - @c NO_REPLY_RECEIVED if not reply was received. Setting size to
* 0 has the same effect
* - Everything else triggers failure event with

View File

@ -18,7 +18,7 @@
#include "fsfw/objectmanager/SystemObject.h"
#include "fsfw/parameters/ParameterHelper.h"
#include "fsfw/power/PowerSwitchIF.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
#include "fsfw/serviceinterface/ServiceInterface.h"
#include "fsfw/serviceinterface/serviceInterfaceDefintions.h"
#include "fsfw/tasks/ExecutableObjectIF.h"
@ -144,7 +144,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* 4. Decrements counter for timeout of replies by calling
* decrementDeviceReplyMap()
* 5. Performs FDIR check for failures
* 6. If the device mode is MODE_OFF, return RETURN_OK.
* 6. If the device mode is MODE_OFF, return returnvalue::OK.
* Otherwise, perform the Action property and performs depending
* on value specified by input value counter (incremented in PST).
* The child class tells base class what to do by setting this value.
@ -160,7 +160,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* - GET_READ: Access requested reading data by calling doGetRead()
* which calls readReceivedMessage of #communicationInterface
* @param counter Specifies which Action to perform
* @return RETURN_OK for successful execution
* @return returnvalue::OK for successful execution
*/
virtual ReturnValue_t performOperation(uint8_t counter) override;
@ -281,7 +281,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
*
* @param[out] id the device command id that has been built
* @return
* - @c RETURN_OK to send command after setting #rawPacket and
* - @c returnvalue::OK to send command after setting #rawPacket and
* #rawPacketLen.
* - @c NOTHING_TO_SEND when no command is to be sent.
* - Anything else triggers an even with the returnvalue as a parameter.
@ -305,7 +305,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
*
* @param[out] id the device command id built
* @return
* - @c RETURN_OK when a command is to be sent
* - @c returnvalue::OK when a command is to be sent
* - @c NOTHING_TO_SEND when no command is to be sent
* - Anything else triggers an even with the returnvalue as a parameter
*/
@ -327,7 +327,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* @param commandData Pointer to the data from the direct command
* @param commandDataLen Length of commandData
* @return
* - @c RETURN_OK to send command after #rawPacket and #rawPacketLen
* - @c returnvalue::OK to send command after #rawPacket and #rawPacketLen
* have been set.
* - @c HasActionsIF::EXECUTION_COMPLETE to generate a finish reply immediately. This can
* be used if no reply is expected
@ -357,7 +357,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* @param[out] foundLen length of the data found. Is to be set in function,
* buffer is scanned at previous position + foundLen.
* @return
* - @c RETURN_OK a valid packet was found at @c start, @c foundLen is valid
* - @c returnvalue::OK a valid packet was found at @c start, @c foundLen is valid
* - @c returnvalue::FAILED no reply could be found starting at @c start,
* implies @c foundLen is not valid, base class will call scanForReply()
* again with ++start
@ -387,7 +387,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* @param id the id found by scanForReply()
* @param packet
* @return
* - @c RETURN_OK when the reply was interpreted.
* - @c returnvalue::OK when the reply was interpreted.
* - @c IGNORE_REPLY_DATA Ignore the reply and don't reset reply cycle
* counter.
* - @c returnvalue::FAILED when the reply could not be interpreted,
@ -450,7 +450,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* @param countdown Instead of using maxDelayCycles to timeout a device reply it is also possible
* to provide a pointer to a Countdown object which will signal the timeout
* when expired
* @return - @c RETURN_OK when the command was successfully inserted,
* @return - @c returnvalue::OK when the command was successfully inserted,
* - @c returnvalue::FAILED else.
*/
ReturnValue_t insertInCommandAndReplyMap(DeviceCommandId_t deviceCommand, uint16_t maxDelayCycles,
@ -471,7 +471,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* @param countdown Instead of using maxDelayCycles to timeout a device reply it is also possible
* to provide a pointer to a Countdown object which will signal the timeout
* when expired
* @return - @c RETURN_OK when the command was successfully inserted,
* @return - @c returnvalue::OK when the command was successfully inserted,
* - @c returnvalue::FAILED else.
*/
ReturnValue_t insertInReplyMap(DeviceCommandId_t deviceCommand, uint16_t maxDelayCycles,
@ -481,7 +481,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
/**
* @brief A simple command to add a command to the commandList.
* @param deviceCommand The command to add
* @return - @c RETURN_OK when the command was successfully inserted,
* @return - @c returnvalue::OK when the command was successfully inserted,
* - @c returnvalue::FAILED else.
*/
ReturnValue_t insertInCommandMap(DeviceCommandId_t deviceCommand,
@ -518,7 +518,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* @param periodic Indicates if the command is periodic (i.e. it is sent
* by the device repeatedly without request) or not. Default is aperiodic (0).
* Warning: The setting always overrides the value that was entered in the map.
* @return - @c RETURN_OK when the command was successfully inserted,
* @return - @c returnvalue::OK when the command was successfully inserted,
* - @c returnvalue::FAILED else.
*/
ReturnValue_t updateReplyMapEntry(DeviceCommandId_t deviceReply, uint16_t delayCycles,
@ -602,7 +602,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* @param mode
* @param submode
* @return
* - @c RETURN_OK if valid
* - @c returnvalue::OK if valid
* - @c returnvalue::FAILED if invalid
*/
virtual ReturnValue_t isModeCombinationValid(Mode_t mode, Submode_t submode);
@ -622,7 +622,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* @param[out] switches pointer to an array of switches
* @param[out] numberOfSwitches length of returned array
* @return
* - @c RETURN_OK if the parameters were set
* - @c returnvalue::OK if the parameters were set
* - @c returnvalue::FAILED if no switches exist
*/
virtual ReturnValue_t getSwitches(const uint8_t **switches, uint8_t *numberOfSwitches);
@ -977,7 +977,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* - A failure code may be returned if something went fundamentally wrong.
*
* @param deviceCommand
* @return - RETURN_OK if a reply was activated.
* @return - returnvalue::OK if a reply was activated.
* - NO_REPLY_EXPECTED if there was no reply found. This is not an
* error case as many commands do not expect a reply.
*/
@ -1004,7 +1004,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
*
* @param[out] id the device command id built
* @return
* - @c RETURN_OK when a command is to be sent
* - @c returnvalue::OK when a command is to be sent
* - not @c NOTHING_TO_SEND when no command is to be sent
*/
virtual ReturnValue_t buildChildRawCommand();
@ -1085,7 +1085,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
/**
* Checks if current handler state allows reception of external device commands.
* Default implementation allows commands only in plain MODE_ON and MODE_NORMAL.
* @return RETURN_OK if commands are accepted, anything else otherwise.
* @return returnvalue::OK if commands are accepted, anything else otherwise.
*/
virtual ReturnValue_t acceptExternalDeviceCommands();
@ -1273,9 +1273,9 @@ class DeviceHandlerBase : public DeviceHandlerIF,
* @param[out] data
* @param[out] len
* @return
* - @c RETURN_OK @c data is valid
* - @c returnvalue::OK @c data is valid
* - @c returnvalue::FAILED IPCStore is nullptr
* - the return value from the IPCStore if it was not @c RETURN_OK
* - the return value from the IPCStore if it was not @c returnvalue::OK
*/
ReturnValue_t getStorageData(store_address_t storageAddress, uint8_t **data, size_t *len);

View File

@ -4,7 +4,7 @@
#include "../../container/PlacementFactory.h"
#include "../../events/EventMessage.h"
#include "../../globalfunctions/matching/MatchTree.h"
#include "../../returnvalues/HasReturnvaluesIF.h"
#include "../../returnvalues/returnvalue.h"
class StorageManagerIF;
class EventMatchTree : public MatchTree<EventMessage*> {

View File

@ -2,7 +2,7 @@
#define FRAMEWORK_FDIR_CONFIRMSFAILURESIF_H_
#include "../ipc/MessageQueueSenderIF.h"
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
class ConfirmsFailuresIF {
public:

View File

@ -5,7 +5,7 @@
#include "../health/HealthMessage.h"
#include "../ipc/MessageQueueIF.h"
#include "../parameters/HasParametersIF.h"
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
#include "ConfirmsFailuresIF.h"
#include "FaultCounter.h"

View File

@ -1,7 +1,7 @@
#ifndef ASCIICONVERTER_H_
#define ASCIICONVERTER_H_
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
class AsciiConverter {
public:

View File

@ -3,7 +3,7 @@
#include <cstddef>
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
/**
* @brief This DLE Encoder (Data Link Encoder) can be used to encode and
@ -72,7 +72,7 @@ class DleEncoder {
* @param addStxEtx Adding STX start marker and ETX end marker can be omitted,
* if they are added manually
* @return
* - RETURN_OK for successful encoding operation
* - returnvalue::OK for successful encoding operation
* - STREAM_TOO_SHORT if the destination stream is too short
*/
ReturnValue_t encode(const uint8_t *sourceStream, size_t sourceLen, uint8_t *destStream,
@ -87,7 +87,7 @@ class DleEncoder {
* @param maxDestStreamlen
* @param decodedLen
* @return
* - RETURN_OK for successful decode operation
* - returnvalue::OK for successful decode operation
* - DECODE_ERROR if the source stream is invalid
* - STREAM_TOO_SHORT if the destination stream is too short
*/

View File

@ -3,7 +3,7 @@
#include <type_traits>
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "fsfw/returnvalues/returnvalue.h"
#include "fsfw/serialize/SerializeIF.h"
/**

View File

@ -3,7 +3,7 @@
#include "../events/Event.h"
#include "../ipc/MessageQueueSenderIF.h"
#include "../returnvalues/HasReturnvaluesIF.h"
#include "../returnvalues/returnvalue.h"
class HasHealthIF {
public: