Refactor TMTC Stack, improve test framework #655

Merged
mohr merged 150 commits from mueller/refactor-tmtc-stack into development 2022-09-12 14:31:23 +02:00
Owner
  • Separate TMTC stack into dedicated creator and reader components. There are few occasions where both are needed. Splitting them into dedicated classes leads to more focused classes which are also easier to test and re-use
  • The reader classes use zero-copy semantics to increase program speed and avoid unnecessary copies. The creator classes focus on a comfortable API dedicated towards creating packets.
  • Add full unit test suite for the space packet and PUS packet stack to allow more flexibility and safety when doing more refactoring or changes in the future
  • Drop the PUS A support. It is an old standard, and no projects currently using the newest FSFW version are using PUS A
  • Make the creator and reader components first class objects and the storage and sender components thin wrappers or helpers using them. This allows framework users to only use the packet stack without pulling in a lot of other dependencies of components which might not be required
  • Significantly improve existing test framework. Adds several new mock classes and improves the MessageQueueMock significantly. Most of these mocks are also necessary to unittest more complex classes like the CommandingServiceBase
  • Unit tests for PusServiceBase
  • Refactoring for PusServiceBase to ensure better testability
  • PusServiceBase now takes a composite configuration struct called PsbParams
  • For class like the TmFunnel, which need to manipulate certain fields of a PUS TM
    which is otherwise fine, a special PusTmZeroCopyWriter class can be used. This class currently only exposes the two functions required: Updating the sequence count and the error control field.
  • There are now two distinct checker components inside the CCSDS router stack: The PusPacketChecker and the CcsdsPacketChecker. The CCSDS distributor will perform the CCSDS packet check while the PUS distributor performs the PUS check. By default, the CCSDS checker will not perform any APID checking, but the PUS checker will. It is possible to specify a custom CCSDS checker. This allows to set a custom checker which will verify that the APID is equal to the PUS APID or a hypothetical CFDP APID. The CFDP checker will not make assumptions about how the CFDP packets are wrapped and then has an implementation independent of CCSDS SpacePacket.

These changes also introduce a lot more interfaces to increase the flexbility of the code base. They are also composition-centric, which gets rid of the complicated inheritance trees and the diamond inheritance issue of the former packet stack.

This PR pushes the code coverage to ~65 %.

Full list of added interfaces

  • SpacePacketIF : Generic CCSDS space packet fields. This interface provides all methods based on 4 core abstract methods which return the packet ID, packet sequence control, data length and version as uint16_t oder uint8_t
  • PusIF : Generic PUS fields: Version, service and subservice. This interface implies SpacePacketIF
  • PusTmIF : Generic PUS C TM fields, for example the fields of the secondary header. This interface implies PusIF
  • PusTcIF : Generic PUS C TC fields, for example the fields of the secondary header. This interface implies PusIF
  • ReadablePacketIF : Returns whole packet in raw format. Useful for zero-copy classes
  • RawUserDataReaderIF: Returns user data like TC app data or TM source data in raw format. Useful for zero-copy classes
  • CreatorDataIF : Returns user data in form of a tagged union which allows to specify user data as a serializable (implementing SerializeIF) or in raw format (pointer + size). Useful for high-level packet creators

Migration Guide

Framework Objects

The VerificationReporter object will not be created automatically now,
so a call like this in the user object factory will probably become necessary

  #include "fsfw/tmtcservices/VerificationReporter.h"
  
  ...
  new VerificationReporter();
  ...

This creates the reporter with the default object ID VERIFICATION_REPORTER
which is used by other objects if no explicit reporter is set.

Pus Service Base API

Calls like this:

  new Service17Test(objects::PUS_SERVICE_17_TEST, apid::APID,
                    pus::PUS_SERVICE_17);

do look like this now

  new Service17Test(PsbParams(objects::PUS_SERVICE_17_TEST, apid::APID,
                    pus::PUS_SERVICE_17));

Static Framework IDs

Some static IDs are written in capital letter now to specify that those are statics
which should remain constant after setting them once.

For example, the following PusServiceBase and the VerificationReporter IDs
might be interesting to set in the Factory::setStaticFrameworkObjectIds function, assuming that all the objects were created and set up properly:

  PusServiceBase::PUS_DISTRIBUTOR = objects::PUS_DISTRIBUTOR;
  PusServiceBase::PACKET_DESTINATION = objects::TM_FUNNEL;

  VerificationReporter::DEFAULT_RECEIVER = objects::PUS_SERVICE_1_VERIFICATION;

Data Pool Manager Subscription

Calls like this:

poolManager.subscribeForPeriodicPacket(internalErrorSid, false,
      static_cast<float>(getPeriodicOperationFrequency()) / static_cast<float>(1000.0), true);

look like this now

  poolManager.subscribeForDiagPeriodicPacket({internalErrorSid, false,
      static_cast<float>(getPeriodicOperationFrequency()) / static_cast<float>(1000.0)});

TM Funnel Implementation

Existing funnel implementations looked like this

  TmPacketPusC packet(packetData);
  packet.setPacketSequenceCount(this->sourceSequenceCount);
  sourceSequenceCount++;
  sourceSequenceCount =
      sourceSequenceCount % SpacePacketBase::LIMIT_SEQUENCE_COUNT;
  packet.setErrorControl();

They now look like this, with the time reader being explicitely set

  PusTmZeroCopyWriter packet(&timeReader, packetData, size);
  result = packet.parseDataWithoutCrcCheck();
  if(result != HasReturnvaluesIF::RETURN_OK) {
    return result;
  }
  packet.setSequenceCount(sourceSequenceCount++);
  sourceSequenceCount = sourceSequenceCount % ccsds::LIMIT_SEQUENCE_COUNT;
  packet.updateErrorControl();

Changed Interfaces

  • TimeStamperIF : Remove hardcoded timestamp size and imply SerializeIF. This allows more flexibility in the used timestamp

Other changes

  • Rename TimeStamper to CdsShortTimeStamper. This is more explicit.

WIP

  • Unittest for new PusTmZeroCopyWriter class
  • Full unit test suite for the TMTC packet stack
  • Basic integration tests for CSB and PSB
  • Unittests for PSB
  • More advanced integration tests, for example a failing CSB command
- Separate TMTC stack into dedicated creator and reader components. There are few occasions where both are needed. Splitting them into dedicated classes leads to more focused classes which are also easier to test and re-use - The reader classes use zero-copy semantics to increase program speed and avoid unnecessary copies. The creator classes focus on a comfortable API dedicated towards creating packets. - Add full unit test suite for the space packet and PUS packet stack to allow more flexibility and safety when doing more refactoring or changes in the future - Drop the PUS A support. It is an old standard, and no projects currently using the newest FSFW version are using PUS A - Make the creator and reader components first class objects and the storage and sender components thin wrappers or helpers using them. This allows framework users to only use the packet stack without pulling in a lot of other dependencies of components which might not be required - Significantly improve existing test framework. Adds several new mock classes and improves the `MessageQueueMock` significantly. Most of these mocks are also necessary to unittest more complex classes like the CommandingServiceBase - Unit tests for `PusServiceBase` - Refactoring for `PusServiceBase` to ensure better testability - `PusServiceBase` now takes a composite configuration struct called `PsbParams` - For class like the `TmFunnel`, which need to manipulate certain fields of a PUS TM which is otherwise fine, a special `PusTmZeroCopyWriter` class can be used. This class currently only exposes the two functions required: Updating the sequence count and the error control field. - There are now two distinct checker components inside the CCSDS router stack: The `PusPacketChecker` and the `CcsdsPacketChecker`. The CCSDS distributor will perform the CCSDS packet check while the PUS distributor performs the PUS check. By default, the CCSDS checker will not perform any APID checking, but the PUS checker will. It is possible to specify a custom CCSDS checker. This allows to set a custom checker which will verify that the APID is equal to the PUS APID or a hypothetical CFDP APID. The CFDP checker will not make assumptions about how the CFDP packets are wrapped and then has an implementation independent of CCSDS SpacePacket. These changes also introduce a lot more interfaces to increase the flexbility of the code base. They are also composition-centric, which gets rid of the complicated inheritance trees and the diamond inheritance issue of the former packet stack. This PR pushes the code coverage to ~65 %. ## Full list of added interfaces - `SpacePacketIF` : Generic CCSDS space packet fields. This interface provides all methods based on 4 core abstract methods which return the packet ID, packet sequence control, data length and version as `uint16_t` oder `uint8_t` - `PusIF` : Generic PUS fields: Version, service and subservice. This interface implies `SpacePacketIF` - `PusTmIF` : Generic PUS C TM fields, for example the fields of the secondary header. This interface implies `PusIF` - `PusTcIF` : Generic PUS C TC fields, for example the fields of the secondary header. This interface implies `PusIF` - `ReadablePacketIF` : Returns whole packet in raw format. Useful for zero-copy classes - `RawUserDataReaderIF`: Returns user data like TC app data or TM source data in raw format. Useful for zero-copy classes - `CreatorDataIF` : Returns user data in form of a tagged union which allows to specify user data as a serializable (implementing `SerializeIF`) or in raw format (pointer + size). Useful for high-level packet creators ## Migration Guide ### Framework Objects The `VerificationReporter` object will not be created automatically now, so a call like this in the user object factory will probably become necessary ```cpp #include "fsfw/tmtcservices/VerificationReporter.h" ... new VerificationReporter(); ... ``` This creates the reporter with the default object ID `VERIFICATION_REPORTER` which is used by other objects if no explicit reporter is set. ### Pus Service Base API Calls like this: ```cpp new Service17Test(objects::PUS_SERVICE_17_TEST, apid::APID, pus::PUS_SERVICE_17); ``` do look like this now ```cpp new Service17Test(PsbParams(objects::PUS_SERVICE_17_TEST, apid::APID, pus::PUS_SERVICE_17)); ``` ### Static Framework IDs Some static IDs are written in capital letter now to specify that those are statics which should remain constant after setting them once. For example, the following `PusServiceBase` and the `VerificationReporter` IDs might be interesting to set in the `Factory::setStaticFrameworkObjectIds` function, assuming that all the objects were created and set up properly: ```cpp PusServiceBase::PUS_DISTRIBUTOR = objects::PUS_DISTRIBUTOR; PusServiceBase::PACKET_DESTINATION = objects::TM_FUNNEL; VerificationReporter::DEFAULT_RECEIVER = objects::PUS_SERVICE_1_VERIFICATION; ``` ### Data Pool Manager Subscription Calls like this: ```cpp poolManager.subscribeForPeriodicPacket(internalErrorSid, false, static_cast<float>(getPeriodicOperationFrequency()) / static_cast<float>(1000.0), true); ``` look like this now ```cpp poolManager.subscribeForDiagPeriodicPacket({internalErrorSid, false, static_cast<float>(getPeriodicOperationFrequency()) / static_cast<float>(1000.0)}); ``` ### TM Funnel Implementation Existing funnel implementations looked like this ```cpp TmPacketPusC packet(packetData); packet.setPacketSequenceCount(this->sourceSequenceCount); sourceSequenceCount++; sourceSequenceCount = sourceSequenceCount % SpacePacketBase::LIMIT_SEQUENCE_COUNT; packet.setErrorControl(); ``` They now look like this, with the time reader being explicitely set ```cpp PusTmZeroCopyWriter packet(&timeReader, packetData, size); result = packet.parseDataWithoutCrcCheck(); if(result != HasReturnvaluesIF::RETURN_OK) { return result; } packet.setSequenceCount(sourceSequenceCount++); sourceSequenceCount = sourceSequenceCount % ccsds::LIMIT_SEQUENCE_COUNT; packet.updateErrorControl(); ``` ## Changed Interfaces - `TimeStamperIF` : Remove hardcoded timestamp size and imply `SerializeIF`. This allows more flexibility in the used timestamp ## Other changes - Rename `TimeStamper` to `CdsShortTimeStamper`. This is more explicit. ## WIP - [x] Unittest for new `PusTmZeroCopyWriter` class - [x] Full unit test suite for the TMTC packet stack - [x] Basic integration tests for CSB and PSB - [x] Unittests for PSB - [x] More advanced integration tests, for example a failing CSB command
muellerr added 18 commits 2022-07-21 13:51:19 +02:00
fsfw/fsfw/pipeline/head There was a failure building this commit Details
d7a2eada94
add space packet creator class
fsfw/fsfw/pipeline/head This commit looks good Details
0c5f623780
additional ctor for space packet creator
fsfw/fsfw/pipeline/head This commit looks good Details
3c72a42ce1
added basic sp creator test
fsfw/fsfw/pipeline/head There was a failure building this commit Details
7e2fdc06cd
hmm this is problematic
fsfw/fsfw/pipeline/head There was a failure building this commit Details
e4d7182d93
update changelog
fsfw/fsfw/pipeline/head This commit looks good Details
ddf38b65c3
apply auto-formatter
fsfw/fsfw/pipeline/head This commit looks good Details
3d2af203f2
finished creator unittests
fsfw/fsfw/pipeline/head There was a failure building this commit Details
5fffbd4a90
start PUS TC refactoring
fsfw/fsfw/pipeline/head There was a failure building this commit Details
6c636661b6
a lot of refactoring
fsfw/fsfw/pipeline/head There was a failure building this commit Details
d80941514f
start refactoring PUS TM handling
fsfw/fsfw/pipeline/head There was a failure building this commit Details
9860061fc6
create new TmSendHelper
fsfw/fsfw/pipeline/head There was a failure building this commit Details
be35bd53a6
switched to new tmtc stack API
fsfw/fsfw/pipeline/head There was a failure building this commit Details
d8b6cb39ac
various bugfixes and improvements
fsfw/fsfw/pipeline/head There was a failure building this commit Details
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
e5ee96259d
some fixes
muellerr added 1 commit 2022-07-21 14:05:29 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
23f264096c
delete a few old classes
muellerr added 1 commit 2022-07-21 14:40:00 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
08e0b0f1a0
added sp reader unittests
muellerr added 1 commit 2022-07-21 17:48:10 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
5af3138e81
fnished PUS TC creator unittests
muellerr added 1 commit 2022-07-21 17:57:29 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
61bc867bed
delete code which is not used anymore
muellerr added 1 commit 2022-07-21 18:17:37 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
0981ee6f7e
minor changes, virtual dtors added
muellerr added 1 commit 2022-07-21 18:21:08 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
affde6bad5
rename namespace
muellerr added 1 commit 2022-07-21 19:10:14 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
0dfaba81f9
finished basic TC unittests
muellerr added 1 commit 2022-07-21 19:16:40 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
bfee4fd90a
add empty test files
muellerr added 1 commit 2022-07-22 16:06:38 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
67776241de
verify successfull TM serialization
muellerr added 1 commit 2022-07-22 16:09:19 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
9275ccb79b
added some missing implementations
muellerr added 1 commit 2022-07-22 16:41:30 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
f28b9ea61b
APID getter bugfix
muellerr added 1 commit 2022-07-22 17:09:43 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
cecaec6007
PUS TM creator tests done
muellerr added 1 commit 2022-07-22 17:11:54 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
2dfbce6174
start TM reader unittests
muellerr added 1 commit 2022-07-22 18:22:32 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
b350018cad
completed basic test set
muellerr added 1 commit 2022-07-22 18:30:59 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
cb05329dd9
completed baseline PUS TM unittests
muellerr added 1 commit 2022-07-22 18:46:56 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
133894f4ba
add basic CCSDS tests
muellerr added 14 commits 2022-07-25 10:24:39 +02:00
muellerr added 1 commit 2022-07-25 10:31:44 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
4921527022
replace c include
muellerr added 1 commit 2022-07-25 10:38:43 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
63ee88af17
added base for tm store test
muellerr added 1 commit 2022-07-25 10:50:48 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
832367fb30
replace some API components with references
muellerr added 1 commit 2022-07-25 10:56:17 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
4989bd0f02
fixes for Linux OSAL clock
muellerr added 1 commit 2022-07-25 11:15:57 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
899d021e00
using uint32_t as store_address requires explicit cast
muellerr added 1 commit 2022-07-25 11:24:10 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
973d4ee8a5
some more ref replacements
muellerr added 1 commit 2022-07-25 11:26:40 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
e2ad37e3e6
more ref replacements
muellerr added 3 commits 2022-07-25 11:35:26 +02:00
fsfw/fsfw/pipeline/head This commit looks good Details
fsfw/fsfw/pipeline/pr-development This commit looks good Details
2a34c831b1
use Be instead of Ne, which could be confused
muellerr added 1 commit 2022-07-25 13:39:17 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
36e3956efb
finished tm store helper tests
muellerr added 1 commit 2022-07-25 14:03:59 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
1a7d7b172b
set up new internal error reporter mock
muellerr added 2 commits 2022-07-25 14:57:17 +02:00
muellerr added 1 commit 2022-07-25 19:37:17 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
6d0fa36f8a
cleaning up message queue mock and subscription API
muellerr added 1 commit 2022-07-25 19:41:58 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
935e135f1c
normal queue sufficient
muellerr added 1 commit 2022-07-25 19:49:12 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
a88f767cca
all tests running again
muellerr added 1 commit 2022-07-25 20:31:03 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
586993c081
completed send helper tests
muellerr added 1 commit 2022-07-25 20:40:56 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
c83f75c515
some more tests using TM send helper
muellerr added this to the v6.0.0 milestone 2022-07-25 20:42:28 +02:00
muellerr added the
Refactor
Breaking API Change
labels 2022-07-25 20:42:43 +02:00
muellerr changed title from WIP: Refactor TMTC Stack to Refactor TMTC Stack, improve test framework 2022-07-25 20:46:01 +02:00
muellerr changed title from Refactor TMTC Stack, improve test framework to WIP: Refactor TMTC Stack, improve test framework 2022-07-25 20:46:09 +02:00
muellerr added 1 commit 2022-07-25 20:53:13 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
7d87274844
add old api but mark it deprecated
muellerr added 1 commit 2022-07-25 21:07:54 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
6d00fc65c0
fix memory leak
muellerr added 1 commit 2022-07-25 22:14:47 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
c12669fe50
this should fix the mmeory leak
muellerr added 1 commit 2022-07-25 22:22:17 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
db33f9cc7e
maybe this teardown fixes the leak
muellerr added 1 commit 2022-07-25 22:29:10 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
747243684d
more leaks
muellerr added 1 commit 2022-07-25 22:36:47 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
e48b6f1432
possible double delete
muellerr added 1 commit 2022-07-26 10:21:14 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
bdf71d4e66
add new HasReturnvaluesIF features
muellerr added 3 commits 2022-07-26 10:29:41 +02:00
fsfw/fsfw/pipeline/head There was a failure building this commit Details
b827bd8370
update HasReturnvaluesIF
1. Add new retval namespace which contains OK and FAIL returnvalue
2. Also contains makeCode constexpr function
3. Mark HasReturnvaluesIF::makeReturnCode deprecated

This prevents from having to implement an interface just to use a shorter
version of the general returnvalues. A namespace is better suited for this
I think
fsfw/fsfw/pipeline/head Build started... Details
fsfw/fsfw/pipeline/pr-development This commit looks good Details
88ebb67c8d
fix deprecation warnings
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
4ed028000d
Merge branch 'mueller/expand-retval-if' into mueller/refactor-tmtc-stack
muellerr added 1 commit 2022-07-26 11:09:55 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
500a5602bd
added additional TM store and send helper
muellerr added 1 commit 2022-07-26 11:14:34 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
f1c37203a4
some more API improvements and replacements
muellerr added 2 commits 2022-07-26 13:59:06 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
75c824ec80
add new VerificationReporterIF
muellerr added 1 commit 2022-07-26 14:10:17 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
146a0e3828
created PSB mock
muellerr added 1 commit 2022-07-26 14:13:52 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
f14c812aff
removed some obsolete code
muellerr added 1 commit 2022-07-26 16:49:44 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
d98b79cf5e
adapt PSB so it can be unittested properly
muellerr added 1 commit 2022-07-26 17:41:13 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
1954ce0ea4
default PUS receiver set automatically now
muellerr added 1 commit 2022-07-26 18:46:21 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
8bf0fb9885
test auto-initializers
muellerr added 1 commit 2022-07-26 18:58:30 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
152c01b2ec
psb unittests almost complete
muellerr added 1 commit 2022-07-26 19:08:07 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
681738dcc6
PSB unittests complete
muellerr added 1 commit 2022-07-27 10:49:58 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
9eb652e585
some printout fixes
muellerr added 1 commit 2022-07-27 11:26:52 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
18ee2ab903
example compiles again
muellerr added 1 commit 2022-07-27 11:33:16 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
064b195c75
some of the deprecation warnings run amok
muellerr added 1 commit 2022-07-27 11:35:28 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
86692e202d
this gets rid of some warnings
muellerr added 1 commit 2022-07-27 11:41:01 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
059fb10558
add helper methods to disable crc calculation
muellerr added 1 commit 2022-07-27 14:40:42 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
740644f2c8
updates for PusDistributor
muellerr added 2 commits 2022-07-27 17:13:33 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
c5ad9b5fa9
switch off debugging switches
muellerr added 1 commit 2022-07-27 17:33:36 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
f591b9793c
pass timeReader to Pus ZC writer
muellerr added 1 commit 2022-07-27 17:48:51 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
234ccdf764
send time stampers properly now
muellerr added 1 commit 2022-07-27 17:56:04 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
0a38d2e22d
small bugfix
muellerr added 1 commit 2022-07-27 18:03:05 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
356d778743
afmt
muellerr added 1 commit 2022-07-27 19:40:51 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
4e571e5082
some more minor fixes
muellerr added 1 commit 2022-07-27 19:56:04 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
d641d63531
set queue of tm send helper
muellerr added 1 commit 2022-07-27 20:10:06 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
f03b7cd660
another bugfix in CSB
muellerr added 1 commit 2022-07-27 20:37:12 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
7e8afcc12f
remove nullptr check
muellerr added 1 commit 2022-07-27 21:06:16 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
93acac02f5
tests running again
muellerr added 1 commit 2022-07-27 21:07:26 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
85dbef20b0
update serialize IF
muellerr added 1 commit 2022-07-27 21:11:05 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
5bb7023ff3
improvements for creator API
muellerr added 1 commit 2022-07-27 21:35:30 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
b485afea57
Simple SerializeIF adaptions
- Returns serialized or deserialized size
muellerr added 4 commits 2022-07-28 13:00:44 +02:00
muellerr added 1 commit 2022-07-28 13:24:45 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
cb118176a0
completed ZcWriter unittests
muellerr added 1 commit 2022-07-28 13:36:59 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
1b5fa2a8fa
test no crc generation
muellerr added 1 commit 2022-07-28 13:42:25 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
8f6f0e1d45
some more fail tests
muellerr added 1 commit 2022-07-28 15:13:24 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
fc3412fa35
set sec header flag and add unit test for it
muellerr added a new dependency 2022-07-29 09:51:56 +02:00
muellerr added a new dependency 2022-07-29 09:52:03 +02:00
muellerr added 1 commit 2022-07-29 10:23:55 +02:00
fsfw/fsfw/pipeline/head This commit looks good Details
fsfw/fsfw/pipeline/pr-development This commit looks good Details
da106fd96f
do not use TC info for failed TC retrieval
muellerr changed title from WIP: Refactor TMTC Stack, improve test framework to Refactor TMTC Stack, improve test framework 2022-08-01 17:18:24 +02:00
muellerr added a new dependency 2022-08-01 20:51:11 +02:00
muellerr requested review from gaisser 2022-08-09 13:05:56 +02:00
muellerr added 1 commit 2022-08-09 13:06:14 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
9796abfc7d
Merge branch 'development' into mueller/refactor-tmtc-stack
muellerr changed title from Refactor TMTC Stack, improve test framework to WIP: Refactor TMTC Stack, improve test framework 2022-08-15 14:21:59 +02:00
muellerr added 1 commit 2022-08-15 19:05:49 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
d7ec04bf4b
Merge remote-tracking branch 'origin/development' into mueller/refactor-tmtc-stack
muellerr added 1 commit 2022-08-15 19:16:34 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
9e064fe800
fix unittests
muellerr added 1 commit 2022-08-16 17:11:25 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
8fd8a37f59
flip verif reporter ctor arguments
muellerr added 1 commit 2022-08-16 17:17:46 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
875174c4ad
better name for global object
muellerr added 1 commit 2022-08-16 17:23:09 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
239d053562
update changelog
muellerr added 1 commit 2022-08-18 11:20:55 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
ff6de8e378
important bugfix for verif reporter
muellerr added 2 commits 2022-08-22 14:17:31 +02:00
fsfw/fsfw/pipeline/head This commit looks good Details
1037102349
merge retval refactoring
fsfw/fsfw/pipeline/head There was a failure building this commit Details
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
2a4ab0af7b
Merge branch 'mueller/refactor-tmtc-stack' into mueller/refactor-tmtc-stack-with-retval-refactoring
muellerr added 1 commit 2022-08-22 15:02:49 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
fsfw/fsfw/pipeline/head There was a failure building this commit Details
dab1b1d067
apply auto-formatter
muellerr added 1 commit 2022-08-22 15:57:23 +02:00
fsfw/fsfw/pipeline/head There was a failure building this commit Details
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
10f34e5a48
Merge remote-tracking branch 'origin/development' into mueller/refactor-tmtc-stack-with-retval-refactoring
muellerr added 1 commit 2022-08-22 16:23:29 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
ba5c6410d6
tests running again
muellerr changed title from WIP: Refactor TMTC Stack, improve test framework to Refactor TMTC Stack, improve test framework 2022-08-22 16:36:31 +02:00
muellerr added 1 commit 2022-08-22 16:37:45 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
a46d8c34d9
small changelog update
Author
Owner

The changes in this PR are used inside the EIVE OBSW now

The changes in this PR are used inside the EIVE OBSW now
gaisser added 1 commit 2022-08-29 15:11:54 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
6bcb208968
Merge branch 'development' into mueller/refactor-tmtc-stack
muellerr added 2 commits 2022-08-29 15:20:50 +02:00
muellerr added 1 commit 2022-08-29 15:27:54 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
b499dedd76
remove TODO
muellerr added 1 commit 2022-08-29 15:30:54 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
cb23911ccd
default initialization of CDS short struct
gaisser requested changes 2022-08-29 18:39:30 +02:00
gaisser left a comment
Owner

I gave up after 81 files. I cannot review this in a sense that I feel satisfied by the review. This is way to large for a proper review.

I gave up after 81 files. I cannot review this in a sense that I feel satisfied by the review. This is way to large for a proper review.
@ -16,1 +13,3 @@
this->messageSize = this->HEADER_SIZE + size;
: messageSize(MessageQueueMessage::HEADER_SIZE + size) {
if (size <= MessageQueueMessage::MAX_DATA_SIZE) {
std::memcpy(internalBuffer + MessageQueueMessage::HEADER_SIZE, data, size);
Owner

You need to avoud this here? Is this a good idea?

You need to avoud this here? Is this a good idea?
Author
Owner

clang-tidy does not like using virtual member functions in the constructor

clang-tidy does not like using virtual member functions in the constructor
gaisser marked this conversation as resolved
@ -13,7 +13,6 @@ ReturnValue_t MessageQueueSenderIF::sendMessage(MessageQueueId_t sendTo,
MessageQueueMessageIF* message,
MessageQueueId_t sentFrom, bool ignoreFault) {
return MessageQueue::sendMessageFromMessageQueue(sendTo, message, sentFrom, ignoreFault);
return returnvalue::OK;
Owner

Oh this was a dumb one.

Oh this was a dumb one.
gaisser marked this conversation as resolved
@ -148,4 +148,2 @@
// Init our dummy packet and correct endianness of object ID before
// sending it back.
WiretappingPacket TmPacket(DeviceHandlerMessage::getDeviceObjectId(reply), data);
TmPacket.objectId = EndianConverter::convertBigEndian(TmPacket.objectId);
Owner

API change or bug fix?

API change or bug fix?
Author
Owner

The previous API used a function which simply copies the TM data with memcpy. The new one uses this function

ReturnValue_t CommandingServiceBase::sendTmPacket(uint8_t subservice, object_id_t objectId,
                                                  const uint8_t* data, size_t dataLen) {
  telemetry::DataWithObjectIdPrefix dataWithObjId(objectId, data, dataLen);
  ReturnValue_t result = tmHelper.prepareTmPacket(subservice, dataWithObjId);
  if (result != returnvalue::OK) {
    return result;
  }
  return tmHelper.storeAndSendTmPacket();
}

where DataWithObjectIdPrefix implements SerializeIF so there is no need to tweak the endianness manually.

The previous API used a function which simply copies the TM data with `memcpy`. The new one uses this function ```cpp ReturnValue_t CommandingServiceBase::sendTmPacket(uint8_t subservice, object_id_t objectId, const uint8_t* data, size_t dataLen) { telemetry::DataWithObjectIdPrefix dataWithObjId(objectId, data, dataLen); ReturnValue_t result = tmHelper.prepareTmPacket(subservice, dataWithObjId); if (result != returnvalue::OK) { return result; } return tmHelper.storeAndSendTmPacket(); } ``` where `DataWithObjectIdPrefix` implements SerializeIF so there is no need to tweak the endianness manually.
gaisser marked this conversation as resolved
muellerr added 1 commit 2022-08-29 20:09:26 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
2cab73d972
avoid duplicate code
Author
Owner

Local pool specific code will be moved into a separate PR

Local pool specific code will be moved into a separate PR
muellerr added 4 commits 2022-08-30 10:58:10 +02:00
muellerr added a new dependency 2022-08-30 11:04:33 +02:00
muellerr added 1 commit 2022-08-30 11:12:06 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
aea9db75cb
better name
muellerr added 1 commit 2022-08-30 12:04:36 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
a9277622ce
move data wrapper
muellerr added 4 commits 2022-08-30 13:46:02 +02:00
fsfw/fsfw/pipeline/head Build started... Details
fsfw/fsfw/pipeline/pr-development This commit looks good Details
20d42add03
add new data wrapper helper type
fsfw/fsfw/pipeline/pr-development This commit looks good Details
0f27c7e7e7
extend data wrapper
fsfw/fsfw/pipeline/pr-development This commit looks good Details
c756297e5c
data wrapper update
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
8e6cee7761
Merge branch 'mueller/data-wrapper' into mueller/refactor-tmtc-stack
gaisser reviewed 2022-08-31 15:35:52 +02:00
@ -35,3 +34,1 @@
data.data_field.service_subtype = subtype;
TmPacketMinimal testPacket((uint8_t*)&data);
testPacket.setAPID(apid);
mintm::MinimalPusTm data{};
Owner

What does mintm mean?

What does mintm mean?
Author
Owner

minimal tm. I can rename it to minTm:: if that helps..

minimal tm. I can rename it to minTm:: if that helps..
Owner

I think that minTm is better.

I think that minTm is better.
gaisser reviewed 2022-08-31 15:45:00 +02:00
@ -27,3 +30,3 @@
private:
uint8_t subService;
uint8_t subService{};
Owner

{} vs = 0 ?

{} vs = 0 ?
Author
Owner

that was auto-generated. apparently clion prefers this..

that was auto-generated. apparently clion prefers this..
Owner

Ok.

Ok.
gaisser marked this conversation as resolved
Owner
This PR leaks https://egit.irs.uni-stuttgart.de/fsfw/fsfw/pulls/668/files
Author
Owner

This is intentional. This PR requires the features of #668 , I only packaged #668 after using it at two places in the code. It might be worth a thought to replace it to an API similar to #671

This is intentional. This PR requires the features of #668 , I only packaged #668 after using it at two places in the code. It might be worth a thought to replace it to an API similar to https://egit.irs.uni-stuttgart.de/fsfw/fsfw/pulls/671
gaisser added a new dependency 2022-09-01 11:48:47 +02:00
gaisser removed a dependency 2022-09-01 11:48:57 +02:00
gaisser added a new dependency 2022-09-01 11:49:44 +02:00
gaisser reviewed 2022-09-01 11:59:32 +02:00
@ -12,3 +12,3 @@
* addTimeStamp may be called in parallel from a different context.
*/
class TimeStamperIF {
class TimeStamperIF : public SerializeIF, public TimeStampIF {
Owner

Is the TimeStamper Serializable? Or is the product of the timestamp serializable?

Is the TimeStamper Serializable? Or is the product of the timestamp serializable?
Author
Owner

Whatever implements TimeStamperIF should also be serializable.

Whatever implements TimeStamperIF should also be serializable.
Author
Owner

Refactored, now named TimeWriterIF

Refactored, now named `TimeWriterIF`
muellerr added 1 commit 2022-09-01 17:48:37 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
5c20cc804e
Merge remote-tracking branch 'origin/development' into mueller/refactor-tmtc-stack
muellerr added 1 commit 2022-09-01 17:51:04 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
04bff7a522
test fix
muellerr added 1 commit 2022-09-05 14:44:43 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
d64ad71529
Some improvements for time stamper API
muellerr added 1 commit 2022-09-05 14:46:57 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
ee93f4a4ca
Merge branch 'development' into mueller/refactor-tmtc-stack
muellerr added 3 commits 2022-09-05 16:02:31 +02:00
muellerr removed a dependency 2022-09-05 16:02:42 +02:00
muellerr added 1 commit 2022-09-05 16:06:17 +02:00
fsfw/fsfw/pipeline/pr-development There was a failure building this commit Details
4c3f9feb93
explicit include
muellerr added 1 commit 2022-09-05 16:09:59 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
f5421e9abd
refactor tm helper
muellerr added 1 commit 2022-09-05 16:24:58 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
1e395dc402
set buffer expects const pointer now
muellerr added 1 commit 2022-09-05 16:27:16 +02:00
fsfw/fsfw/pipeline/pr-development This commit looks good Details
3583e30ee6
rename const buf setter
muellerr added a new dependency 2022-09-05 16:34:52 +02:00
muellerr added 2 commits 2022-09-05 16:38:50 +02:00
fsfw/fsfw/pipeline/head Build started... Details
fsfw/fsfw/pipeline/pr-development Build started... Details
16688316a8
rename setBuffer to setConstBuffer
mohr approved these changes 2022-09-12 14:14:37 +02:00
mohr left a comment
Owner

Approving this for merge as to keep up with eive.

Approving this for merge as to keep up with eive.
mohr added 1 commit 2022-09-12 14:14:52 +02:00
mohr merged commit a5b5523111 into development 2022-09-12 14:31:23 +02:00
mohr deleted branch mueller/refactor-tmtc-stack 2022-09-12 14:31:27 +02:00
Sign in to join this conversation.
No description provided.