1
0
forked from fsfw/fsfw

Compare commits

..

37 Commits

Author SHA1 Message Date
2ca9eb4204 WIP 2023-02-09 15:54:32 +01:00
45b686a028 Merge remote-tracking branch 'origin/development' into mohr/windows 2023-02-08 22:08:55 +01:00
329e80e7ee enabling win unittests 2023-02-08 14:08:09 +01:00
3772db4753 group id conflict 2023-02-08 11:46:39 +01:00
3d13ead275 moved to newer wine 2023-02-07 21:56:06 +01:00
e7e9ce4baf one more warning suppressed in MSVC 2023-02-07 13:25:13 +01:00
e4c11f8107 fixing problem which causes a looooooong hang in CI by illegaly overrideing internal CMake Variable 2023-02-07 12:26:44 +01:00
4cf52d5dfe Merge pull request 'Time Service 9 update' (#726) from eive/fsfw:updates_fixes_pus_time_service into development
Reviewed-on: fsfw/fsfw#726
2023-02-07 12:19:45 +01:00
46230e6c6d Merge remote-tracking branch 'upstream/development' into updates_fixes_pus_time_service 2023-02-07 12:11:29 +01:00
270622a5f1 no coverage with clang so far; using correct path to push coverage data 2023-02-06 22:49:37 +01:00
4b52e5bec4 windows and clang builds in CI 2023-02-06 22:45:00 +01:00
e2b66df72e Merge pull request 'various fixes related to linux Unittests and memory leaks' (#715) from eive/fsfw:unittest_fix_semaphore into development
Reviewed-on: fsfw/fsfw#715
2023-02-06 16:30:37 +01:00
7b828f233a Merge pull request 'I2C Linux: remove duplicate printout' (#718) from eive/fsfw:i2c_remove_duplicate_printout into development
Reviewed-on: fsfw/fsfw#718
2023-02-06 14:54:58 +01:00
c3d1000cd5 Merge branch 'development' into unittest_fix_semaphore 2023-02-06 14:46:45 +01:00
8e0e57714d Merge pull request 'allow using SO_REUSEADDR and SO_REUSEPORT on TCP server' (#722) from eive/fsfw:tcp_server_reuseaddr_reusesocket into development
Reviewed-on: fsfw/fsfw#722
2023-02-06 14:45:40 +01:00
cc9e54ea6b Merge pull request 'improve srv20 error messages' (#723) from eive/fsfw:srv20_error_msgs into development
Reviewed-on: fsfw/fsfw#723
2023-02-06 14:37:26 +01:00
31465a4e0f Merge pull request 'MGM: small tweak, gain factor was always them same' (#724) from eive/fsfw:mgm_handler_small_fix into development
Reviewed-on: fsfw/fsfw#724
2023-02-06 14:36:34 +01:00
c0e5d1eb99 Merge branch 'development' into tcp_server_reuseaddr_reusesocket 2023-02-06 14:34:52 +01:00
3bc5d4a2e0 Merge remote-tracking branch 'upstream/development' into mgm_handler_small_fix 2023-02-06 14:25:33 +01:00
b1e9dd9e4a Merge remote-tracking branch 'upstream/development' into updates_fixes_pus_time_service 2023-02-06 14:24:38 +01:00
ab86599db3 Merge pull request 'Bugfix DHB setNormalDatapoolEntriesInvalid' (#728) from eive/fsfw:bugfix_dhb_set_datapool_entries_invalid into development
Reviewed-on: fsfw/fsfw#728
2023-02-06 14:20:34 +01:00
034eb34c2e small tweak 2023-02-03 16:05:50 +01:00
4374c7c4f4 changelog 2023-02-03 16:01:56 +01:00
5343844be5 bugfix in setNormalDataPoolEntriesInvalid
Do not forget to call read and write to actually update the
validity state
2023-02-03 16:00:55 +01:00
e300490b93 Merge pull request 'Bugfix PUS packet creators Sequence flags' (#727) from eive/fsfw:bugfix_pus_packets_seq_flags into development
Reviewed-on: fsfw/fsfw#727
2023-02-02 17:22:29 +01:00
0f811777a7 changelog update 2023-02-01 20:49:53 +01:00
e93137939e set sequence flags for PUS TMTC to unsegmented 2023-02-01 20:48:26 +01:00
1f88c006d9 update changelog 2023-02-01 18:42:09 +01:00
7e94baceef service 9 update
- fix time info event
- add time dump subservice
2023-02-01 18:39:23 +01:00
9b05e8f274 re-order fields in TcpConfig 2023-01-30 14:24:48 +01:00
eb223dae88 bump changelog 2023-01-30 14:20:28 +01:00
3656662d88 small tweak, gain factory was always them same 2023-01-30 14:18:03 +01:00
fe71978467 improve srv20 error messages 2023-01-30 14:15:37 +01:00
b646717a76 bump changelog 2023-01-30 14:11:00 +01:00
99d8c845f2 allow using SO_REUSEADDR and SO_REUSEPORT on TCP server 2023-01-30 14:07:41 +01:00
ba62c28b64 adding linux ci and fixing problems 2023-01-12 15:40:52 +01:00
7adb47aecb remove duplicate printout 2023-01-11 08:45:37 +01:00
36 changed files with 212 additions and 88 deletions

View File

@ -12,6 +12,16 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
## Fixes ## Fixes
- `Service9TimeManagement`: Fix the time dump at the `SET_TIME` subservice: Include clock timeval
seconds instead of uptime.
PR: https://egit.irs.uni-stuttgart.de/fsfw/fsfw/pulls/726
- HAL MGM3100 Handler: Use axis specific gain/scaling factors. Previously,
only the X scaling factor was used.
PR: https://egit.irs.uni-stuttgart.de/fsfw/fsfw/pulls/724
- DHB `setNormalDatapoolEntriesInvalid`: The default implementation did not set the validity
to false correctly because the `read` and `write` calls were missing.
- PUS TMTC creator module: Sequence flags were set to continuation segment (0b00) instead
of the correct unsegmented flags (0b11) as specified in the standard.
- TC Scheduler Service 11: Add size and CRC check for contained TC. - TC Scheduler Service 11: Add size and CRC check for contained TC.
- Only delete health table entry in `HealthHelper` destructor if - Only delete health table entry in `HealthHelper` destructor if
health table was set. health table was set.
@ -28,6 +38,11 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
## Added ## Added
- `Service9TimeManagement`: Add `DUMP_TIME` (129) subservice.
- `TcpTmTcServer`: Allow setting the `SO_REUSEADDR` and `SO_REUSEPORT`
option on the TCP server. CTOR prototype has changed and expects an explicit
TCP configuration struct to be passed.
PR: https://egit.irs.uni-stuttgart.de/fsfw/fsfw/pulls/722
- `DleParser` helper class to parse DLE encoded packets from a byte stream. - `DleParser` helper class to parse DLE encoded packets from a byte stream.
PR: https://egit.irs.uni-stuttgart.de/fsfw/fsfw/pulls/711 PR: https://egit.irs.uni-stuttgart.de/fsfw/fsfw/pulls/711
- `UioMapper` is able to resolve symlinks now. - `UioMapper` is able to resolve symlinks now.

View File

@ -66,7 +66,8 @@ endif()
if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC") if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
# Manually tweak MSVC to emit (about) the same warnings as clang and gcc on linux # Manually tweak MSVC to emit (about) the same warnings as clang and gcc on linux
add_compile_options("/permissive-" /wd4267 /wd4244 /wd4244 /wd4305 /wd4805 /wd4267 /wd4646 /wd4065 /Dand=&& /Dor=|| /Dnot=!) # needs to be done here using add_compile_definitions() (as opposed to target_compile_definitions()) to be available for all binaries and libraries
add_compile_options("/permissive-" /wd4267 /wd4244 /wd4244 /wd4305 /wd4805 /wd4267 /wd4646 /wd4065 /wd4996 /Dand=&& /Dor=|| /Dnot=!)
add_compile_definitions(NOMINMAX) add_compile_definitions(NOMINMAX)
endif() endif()
@ -479,7 +480,46 @@ if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
endif() endif()
if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
set(FSFW_WARNING_FLAGS -Wall -Wno-gnu-anonymous-struct) set(FSFW_WARNING_FLAGS
-Weverything
-Wno-gnu-anonymous-struct
-Wno-c++98-compat
-Wno-c++98-compat-pedantic
-Wno-covered-switch-default
-Wno-padded
-Wno-documentation
-Wno-weak-vtables
-Wno-c++98-c++11-compat-binary-literal
-Wno-documentation-unknown-command
-Wno-reserved-macro-identifier
-Wno-global-constructors
-Wno-reserved-identifier
-Wno-switch-enum
-Werror
#WTH?
-Wno-ctad-maybe-unsupported
#WIP
-Wno-undefined-func-template
-Wno-suggest-destructor-override
-Wno-suggest-override
-Wno-inconsistent-missing-destructor-override
-Wno-extra-semi
#could be useful:
-Wno-sign-conversion
-Wno-implicit-int-conversion
-Wno-shorten-64-to-32
-Wno-double-promotion
-Wno-float-conversion
-Wno-implicit-int-float-conversion
-Wno-implicit-float-conversion
-Wno-shadow-field-in-constructor
-Wno-shadow-field
-Wno-shadow
-Wno-unused-parameter
)
endif() endif()
# Required include paths to compile the FSFW # Required include paths to compile the FSFW

View File

@ -5,7 +5,7 @@ RUN apt-get --yes upgrade
#tzdata is a dependency, won't install otherwise #tzdata is a dependency, won't install otherwise
ARG DEBIAN_FRONTEND=noninteractive ARG DEBIAN_FRONTEND=noninteractive
RUN apt-get --yes install ca-certificates clang cmake doxygen g++ gcc git graphviz iputils-ping lcov make msitools nano ninja-build pip python3 python3-simplejson python3-six qemu-system-arm rsync valgrind wget winbind wine64-development RUN apt-get --yes install ca-certificates clang cmake doxygen g++ gcc git graphviz iputils-ping lcov make msitools nano ninja-build pip python3 python3-simplejson python3-six qemu-system-arm rsync valgrind wget winbind
RUN python3 -m pip install sphinx breathe RUN python3 -m pip install sphinx breathe
@ -26,8 +26,18 @@ RUN git clone https://github.com/ETLCPP/etl.git && \
RUN wget -qO- https://buggy.irs.uni-stuttgart.de/rtems_releases/rtems6-12.2.1.tar.bz2 | tar -xj -C /opt/ RUN wget -qO- https://buggy.irs.uni-stuttgart.de/rtems_releases/rtems6-12.2.1.tar.bz2 | tar -xj -C /opt/
ENV PATH="$PATH:/opt/rtems/6/bin" ENV PATH="$PATH:/opt/rtems/6/bin"
# install modern wine for MSVC, removing a conflicting file
RUN dpkg --add-architecture i386 && \
mkdir -pm755 /etc/apt/keyrings && \
wget -O /etc/apt/keyrings/winehq-archive.key https://dl.winehq.org/wine-builds/winehq.key && \
wget -NP /etc/apt/sources.list.d/ https://dl.winehq.org/wine-builds/ubuntu/dists/focal/winehq-focal.sources && \
apt-get update && \
apt-get --yes install winehq-stable
# silence wine
ENV WINEDEBUG=-all
# install msvc using https://github.com/mstorsjo/msvc-wine
# install MSVC using https://github.com/mstorsjo/msvc-wine
# see msvc-wine/LICENSE.txt # see msvc-wine/LICENSE.txt
COPY msvc-wine/lowercase msvc-wine/fixinclude msvc-wine/install.sh msvc-wine/vsdownload.py ./ COPY msvc-wine/lowercase msvc-wine/fixinclude msvc-wine/install.sh msvc-wine/vsdownload.py ./
COPY msvc-wine/wrappers/* ./wrappers/ COPY msvc-wine/wrappers/* ./wrappers/
@ -35,13 +45,12 @@ RUN PYTHONUNBUFFERED=1 ./vsdownload.py --accept-license --dest /opt/msvc && \
./install.sh /opt/msvc && \ ./install.sh /opt/msvc && \
rm lowercase fixinclude install.sh vsdownload.py && \ rm lowercase fixinclude install.sh vsdownload.py && \
rm -rf wrappers rm -rf wrappers
COPY msvc-wine/msvcenv-native.sh /opt/msvc
RUN wine64 wineboot --init && \ RUN wine64 wineboot --init && \
while pgrep wineserver > /dev/null; do sleep 1; done while pgrep wineserver > /dev/null; do sleep 1; done
#ssh needs a valid user to work #ssh needs a valid user to work
RUN adduser -q --uid 114 jenkins RUN addgroup -q --gid 117 jenkins && adduser -q --uid 114 --gid 117 jenkins
#add documentation server to known hosts #add documentation server to known hosts
RUN echo "|1|/LzCV4BuTmTb2wKnD146l9fTKgQ=|NJJtVjvWbtRt8OYqFgcYRnMQyVw= ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBNL8ssTonYtgiR/6RRlSIK9WU1ywOcJmxFTLcEblAwH7oifZzmYq3XRfwXrgfMpylEfMFYfCU8JRqtmi19xc21A=" >> /etc/ssh/ssh_known_hosts RUN echo "|1|/LzCV4BuTmTb2wKnD146l9fTKgQ=|NJJtVjvWbtRt8OYqFgcYRnMQyVw= ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBNL8ssTonYtgiR/6RRlSIK9WU1ywOcJmxFTLcEblAwH7oifZzmYq3XRfwXrgfMpylEfMFYfCU8JRqtmi19xc21A=" >> /etc/ssh/ssh_known_hosts

View File

@ -4,28 +4,28 @@ pipeline {
BUILDDIR_LINUX = 'cmake-build-tests-linux' BUILDDIR_LINUX = 'cmake-build-tests-linux'
BUILDDIR_FREERTOS = 'cmake-build-tests-freertos' BUILDDIR_FREERTOS = 'cmake-build-tests-freertos'
BUILDDIR_RTEMS = 'cmake-build-tests-rtems' BUILDDIR_RTEMS = 'cmake-build-tests-rtems'
BUILDDIR_WIN = 'cmake-build-tests-windows'
DOCDDIR = 'cmake-build-documentation' DOCDDIR = 'cmake-build-documentation'
} }
agent { agent {
docker { docker {
image 'fsfw-ci:d7' image 'fsfw-ci:d9'
args '--network host --sysctl fs.mqueue.msg_max=100' args '--network host --sysctl fs.mqueue.msg_max=100'
} }
} }
stages { stages {
stage('Host') { stage('Host-clang') {
steps { steps {
sh 'rm -rf $BUILDDIR_HOST' sh 'rm -rf $BUILDDIR_HOST'
dir(BUILDDIR_HOST) { dir(BUILDDIR_HOST) {
sh 'cmake -DFSFW_OSAL=host -DFSFW_BUILD_TESTS=ON -DFSFW_CICD_BUILD=ON ..' sh 'CC=clang CXX=clang++ cmake -DFSFW_OSAL=host -DFSFW_BUILD_TESTS=ON -DFSFW_CICD_BUILD=ON ..'
sh 'cmake --build . -j4' sh 'cmake --build . -j4'
sh 'cmake --build . -- fsfw-tests_coverage -j4'
sh 'valgrind --leak-check=full --error-exitcode=1 ./fsfw-tests' sh 'valgrind --leak-check=full --error-exitcode=1 ./fsfw-tests'
} }
} }
} }
stage('Linux') { stage('Linux-gcc') {
steps { steps {
sh 'rm -rf $BUILDDIR_LINUX' sh 'rm -rf $BUILDDIR_LINUX'
@ -37,19 +37,19 @@ pipeline {
} }
} }
} }
stage('FreeRTOS') { stage('FreeRTOS-gcc') {
steps { steps {
sh 'rm -rf $BUILDDIR_FREERTOS' sh 'rm -rf $BUILDDIR_FREERTOS'
dir(BUILDDIR_FREERTOS) { dir(BUILDDIR_FREERTOS) {
sh 'cmake -DFSFW_OSAL=freertos -DFSFW_BUILD_TESTS=ON -DFSFW_CICD_BUILD=ON ..' sh 'cmake -DFSFW_OSAL=freertos -DFSFW_BUILD_TESTS=ON -DFSFW_CICD_BUILD=ON ..'
sh 'cmake --build . -j4' sh 'cmake --build . -j4'
sh 'cmake --build . -- fsfw-tests_coverage -j4' sh './fsfw-tests'
//sh 'valgrind --leak-check=full --error-exitcode=1 ./fsfw-tests' //sh 'valgrind --leak-check=full --error-exitcode=1 ./fsfw-tests'
} }
} }
} }
stage('rtems') { stage('rtems-gcc') {
steps { steps {
sh 'rm -rf $BUILDDIR_RTEMS' sh 'rm -rf $BUILDDIR_RTEMS'
@ -60,6 +60,17 @@ pipeline {
} }
} }
} }
stage('Host-msvc') {
steps {
sh 'rm -rf $BUILDDIR_WIN'
dir(BUILDDIR_WIN) {
sh 'cmake -DFSFW_OSAL=host -DFSFW_BUILD_TESTS=ON -DFSFW_TESTS_GEN_COV=OFF -DFSFW_CICD_BUILD=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=../unittests/testcfg/windows/cmake/x64-windows-toolchain.cmake -GNinja ..'
sh 'cmake --build . -j4'
sh 'wine64 fsfw-tests.exe'
}
}
}
stage('Documentation') { stage('Documentation') {
when { when {
branch 'development' branch 'development'
@ -72,7 +83,7 @@ pipeline {
sh 'rsync -r --delete docs/sphinx/* buildfix@documentation.irs.uni-stuttgart.de:/fsfw/development' sh 'rsync -r --delete docs/sphinx/* buildfix@documentation.irs.uni-stuttgart.de:/fsfw/development'
} }
} }
dir(BUILDDIR) { dir(BUILDDIR_LINUX) {
sshagent(credentials: ['documentation-buildfix']) { sshagent(credentials: ['documentation-buildfix']) {
sh 'rsync -r --delete fsfw-tests_coverage/* buildfix@documentation.irs.uni-stuttgart.de:/fsfw/coverage/development' sh 'rsync -r --delete fsfw-tests_coverage/* buildfix@documentation.irs.uni-stuttgart.de:/fsfw/coverage/development'
} }
@ -91,7 +102,7 @@ pipeline {
sh 'rsync -r --delete docs/sphinx/* buildfix@documentation.irs.uni-stuttgart.de:/fsfw/master' sh 'rsync -r --delete docs/sphinx/* buildfix@documentation.irs.uni-stuttgart.de:/fsfw/master'
} }
} }
dir(BUILDDIR) { dir(BUILDDIR_LINUX) {
sshagent(credentials: ['documentation-buildfix']) { sshagent(credentials: ['documentation-buildfix']) {
sh 'rsync -r --delete fsfw-tests_coverage/* buildfix@documentation.irs.uni-stuttgart.de:/fsfw/coverage/master' sh 'rsync -r --delete fsfw-tests_coverage/* buildfix@documentation.irs.uni-stuttgart.de:/fsfw/coverage/master'
} }

View File

@ -68,6 +68,7 @@ class UserBase {
public: public:
explicit UserBase(HasFileSystemIF& vfs); explicit UserBase(HasFileSystemIF& vfs);
virtual ~UserBase() = default;
virtual void transactionIndication(const TransactionId& id) = 0; virtual void transactionIndication(const TransactionId& id) = 0;
virtual void eofSentIndication(const TransactionId& id) = 0; virtual void eofSentIndication(const TransactionId& id) = 0;

View File

@ -1,6 +1,6 @@
#include "helpers.h" #include "helpers.h"
const char* COND_CODE_STRINGS[14] = {"Unknown", static const char* COND_CODE_STRINGS[14] = {"Unknown",
"No Error", "No Error",
"Positive ACK Limit Reached", "Positive ACK Limit Reached",
"Keep Alive Limit Reached", "Keep Alive Limit Reached",

View File

@ -8,7 +8,7 @@
template <typename Tp> template <typename Tp>
class BinaryNode { class BinaryNode {
public: public:
BinaryNode(Tp* setValue) : value(setValue), left(NULL), right(NULL), parent(NULL) {} BinaryNode(Tp* setValue) : value(setValue), left(nullptr), right(nullptr), parent(nullptr) {}
Tp* value; Tp* value;
BinaryNode* left; BinaryNode* left;
BinaryNode* right; BinaryNode* right;
@ -23,31 +23,31 @@ class ExplicitNodeIterator {
typedef Tp value_type; typedef Tp value_type;
typedef Tp* pointer; typedef Tp* pointer;
typedef Tp& reference; typedef Tp& reference;
ExplicitNodeIterator() : element(NULL) {} ExplicitNodeIterator() : element(nullptr) {}
ExplicitNodeIterator(_Node* node) : element(node) {} ExplicitNodeIterator(_Node* node) : element(node) {}
BinaryNode<Tp>* element; BinaryNode<Tp>* element;
_Self up() { return _Self(element->parent); } _Self up() { return _Self(element->parent); }
_Self left() { _Self left() {
if (element != NULL) { if (element != nullptr) {
return _Self(element->left); return _Self(element->left);
} else { } else {
return _Self(NULL); return _Self(nullptr);
} }
} }
_Self right() { _Self right() {
if (element != NULL) { if (element != nullptr) {
return _Self(element->right); return _Self(element->right);
} else { } else {
return _Self(NULL); return _Self(nullptr);
} }
} }
bool operator==(const _Self& __x) const { return element == __x.element; } bool operator==(const _Self& __x) const { return element == __x.element; }
bool operator!=(const _Self& __x) const { return element != __x.element; } bool operator!=(const _Self& __x) const { return element != __x.element; }
pointer operator->() const { pointer operator->() const {
if (element != NULL) { if (element != nullptr) {
return element->value; return element->value;
} else { } else {
return NULL; return nullptr;
} }
} }
pointer operator*() const { return this->operator->(); } pointer operator*() const { return this->operator->(); }
@ -62,13 +62,13 @@ class BinaryTree {
typedef ExplicitNodeIterator<Tp> iterator; typedef ExplicitNodeIterator<Tp> iterator;
typedef BinaryNode<Tp> Node; typedef BinaryNode<Tp> Node;
typedef std::pair<iterator, iterator> children; typedef std::pair<iterator, iterator> children;
BinaryTree() : rootNode(NULL) {} BinaryTree() : rootNode(nullptr) {}
BinaryTree(Node* rootNode) : rootNode(rootNode) {} BinaryTree(Node* rootNode) : rootNode(rootNode) {}
iterator begin() const { return iterator(rootNode); } iterator begin() const { return iterator(rootNode); }
static iterator end() { return iterator(NULL); } static iterator end() { return iterator(nullptr); }
iterator insert(bool insertLeft, iterator parentNode, Node* newNode) { iterator insert(bool insertLeft, iterator parentNode, Node* newNode) {
newNode->parent = parentNode.element; newNode->parent = parentNode.element;
if (parentNode.element != NULL) { if (parentNode.element != nullptr) {
if (insertLeft) { if (insertLeft) {
parentNode.element->left = newNode; parentNode.element->left = newNode;
} else { } else {
@ -84,13 +84,13 @@ class BinaryTree {
children erase(iterator node) { children erase(iterator node) {
if (node.element == rootNode) { if (node.element == rootNode) {
// We're root node // We're root node
rootNode = NULL; rootNode = nullptr;
} else { } else {
// Delete parent's reference // Delete parent's reference
if (node.up().left() == node) { if (node.up().left() == node) {
node.up().element->left = NULL; node.up().element->left = nullptr;
} else { } else {
node.up().element->right = NULL; node.up().element->right = nullptr;
} }
} }
return children(node.element->left, node.element->right); return children(node.element->left, node.element->right);

View File

@ -61,7 +61,7 @@ class PlacementFactory {
// Need to call destructor first, in case something was allocated by the object (shouldn't do // Need to call destructor first, in case something was allocated by the object (shouldn't do
// that, however). // that, however).
thisElement->~T(); thisElement->~T();
uint8_t* pointer = (uint8_t*)(thisElement); uint8_t* pointer = static_cast<uint8_t*>(thisElement);
return dataBackend->deleteData(pointer, sizeof(T)); return dataBackend->deleteData(pointer, sizeof(T));
} }

View File

@ -286,7 +286,6 @@ ReturnValue_t LocalDataPoolManager::addUpdateToStore(HousekeepingSnapshot& updat
result = updatePacket.serialize(&storePtr, &serializedSize, updatePacketSize, result = updatePacket.serialize(&storePtr, &serializedSize, updatePacketSize,
SerializeIF::Endianness::MACHINE); SerializeIF::Endianness::MACHINE);
return result; return result;
;
} }
void LocalDataPoolManager::handleChangeResetLogic(DataType type, DataId dataId, void LocalDataPoolManager::handleChangeResetLogic(DataType type, DataId dataId,

View File

@ -27,7 +27,7 @@ ReturnValue_t ChildHandlerBase::initialize() {
if (parentId != objects::NO_OBJECT) { if (parentId != objects::NO_OBJECT) {
SubsystemBase* parent = ObjectManager::instance()->get<SubsystemBase>(parentId); SubsystemBase* parent = ObjectManager::instance()->get<SubsystemBase>(parentId);
if (parent == NULL) { if (parent == nullptr) {
return returnvalue::FAILED; return returnvalue::FAILED;
} }
parentQueue = parent->getCommandQueue(); parentQueue = parent->getCommandQueue();

View File

@ -1,5 +1,6 @@
#include "fsfw/devicehandlers/DeviceHandlerBase.h" #include "fsfw/devicehandlers/DeviceHandlerBase.h"
#include "fsfw/datapool/PoolReadGuard.h"
#include "fsfw/datapoollocal/LocalPoolVariable.h" #include "fsfw/datapoollocal/LocalPoolVariable.h"
#include "fsfw/devicehandlers/AcceptsDeviceResponsesIF.h" #include "fsfw/devicehandlers/AcceptsDeviceResponsesIF.h"
#include "fsfw/devicehandlers/DeviceTmReportingWrapper.h" #include "fsfw/devicehandlers/DeviceTmReportingWrapper.h"
@ -933,19 +934,14 @@ DeviceHandlerIF::CommunicationAction DeviceHandlerBase::getComAction() {
switch (pstStep) { switch (pstStep) {
case 0: case 0:
return CommunicationAction::PERFORM_OPERATION; return CommunicationAction::PERFORM_OPERATION;
break;
case 1: case 1:
return CommunicationAction::SEND_WRITE; return CommunicationAction::SEND_WRITE;
break;
case 2: case 2:
return CommunicationAction::GET_WRITE; return CommunicationAction::GET_WRITE;
break;
case 3: case 3:
return CommunicationAction::SEND_READ; return CommunicationAction::SEND_READ;
break;
case 4: case 4:
return CommunicationAction::GET_READ; return CommunicationAction::GET_READ;
break;
default: default:
break; break;
} }
@ -961,7 +957,7 @@ void DeviceHandlerBase::buildRawDeviceCommand(CommandMessage* commandMessage) {
replyReturnvalueToCommand(result, RAW_COMMAND_ID); replyReturnvalueToCommand(result, RAW_COMMAND_ID);
storedRawData.raw = StorageManagerIF::INVALID_ADDRESS; storedRawData.raw = StorageManagerIF::INVALID_ADDRESS;
} else { } else {
cookieInfo.pendingCommand = deviceCommandMap.find((DeviceCommandId_t)RAW_COMMAND_ID); cookieInfo.pendingCommand = deviceCommandMap.find(static_cast<DeviceCommandId_t>(RAW_COMMAND_ID));
cookieInfo.pendingCommand->second.isExecuting = true; cookieInfo.pendingCommand->second.isExecuting = true;
cookieInfo.state = COOKIE_WRITE_READY; cookieInfo.state = COOKIE_WRITE_READY;
} }
@ -1505,7 +1501,10 @@ DeviceCommandId_t DeviceHandlerBase::getPendingCommand() const {
void DeviceHandlerBase::setNormalDatapoolEntriesInvalid() { void DeviceHandlerBase::setNormalDatapoolEntriesInvalid() {
for (const auto& reply : deviceReplyMap) { for (const auto& reply : deviceReplyMap) {
if (reply.second.dataSet != nullptr) { if (reply.second.dataSet != nullptr) {
reply.second.dataSet->setValidity(false, true); PoolReadGuard pg(reply.second.dataSet);
if (pg.getReadResult() == returnvalue::OK) {
reply.second.dataSet->setValidity(false, true);
}
} }
} }
} }

View File

@ -72,7 +72,7 @@ void DeviceHandlerMessage::clear(CommandMessage* message) {
ipcStore->deleteData(getStoreAddress(message)); ipcStore->deleteData(getStoreAddress(message));
} }
} }
/* NO BREAK falls through*/ [[fallthrough]];
case CMD_SWITCH_ADDRESS: case CMD_SWITCH_ADDRESS:
case CMD_WIRETAPPING: case CMD_WIRETAPPING:
message->setCommand(CommandMessage::CMD_NONE); message->setCommand(CommandMessage::CMD_NONE);

View File

@ -7,10 +7,10 @@
InternalErrorReporter::InternalErrorReporter(object_id_t setObjectId, uint32_t messageQueueDepth) InternalErrorReporter::InternalErrorReporter(object_id_t setObjectId, uint32_t messageQueueDepth)
: SystemObject(setObjectId), : SystemObject(setObjectId),
commandQueue(QueueFactory::instance()->createMessageQueue(messageQueueDepth)),
poolManager(this, commandQueue), poolManager(this, commandQueue),
internalErrorSid(setObjectId, InternalErrorDataset::ERROR_SET_ID), internalErrorSid(setObjectId, InternalErrorDataset::ERROR_SET_ID),
internalErrorDataset(this) { internalErrorDataset(this) {
commandQueue = QueueFactory::instance()->createMessageQueue(messageQueueDepth);
mutex = MutexFactory::instance()->createMutex(); mutex = MutexFactory::instance()->createMutex();
} }

View File

@ -48,7 +48,7 @@ class CommandMessage : public MessageQueueMessage, public CommandMessageIF {
/** /**
* @brief Default Destructor * @brief Default Destructor
*/ */
virtual ~CommandMessage() {} ~CommandMessage() override {}
/** /**
* Read the DeviceHandlerCommand_t that is stored in the message, * Read the DeviceHandlerCommand_t that is stored in the message,

View File

@ -37,7 +37,7 @@ class CommandMessageIF {
//! par1 should contain the error code //! par1 should contain the error code
static const Command_t REPLY_REJECTED = MAKE_COMMAND_ID(2); static const Command_t REPLY_REJECTED = MAKE_COMMAND_ID(2);
virtual ~CommandMessageIF(){}; virtual ~CommandMessageIF() = default;
/** /**
* A command message shall have a uint16_t command ID field. * A command message shall have a uint16_t command ID field.

View File

@ -5,7 +5,7 @@
#include <fsfw/objectmanager/frameworkObjects.h> #include <fsfw/objectmanager/frameworkObjects.h>
struct MqArgs { struct MqArgs {
MqArgs(){}; MqArgs(){}
MqArgs(object_id_t objectId, void* args = nullptr) : objectId(objectId), args(args) {} MqArgs(object_id_t objectId, void* args = nullptr) : objectId(objectId), args(args) {}
object_id_t objectId = objects::NO_OBJECT; object_id_t objectId = objects::NO_OBJECT;
void* args = nullptr; void* args = nullptr;

View File

@ -40,7 +40,7 @@ class ObjectManagerIF {
/** /**
* @brief This is the empty virtual destructor as requested by C++ interfaces. * @brief This is the empty virtual destructor as requested by C++ interfaces.
*/ */
virtual ~ObjectManagerIF(void){}; virtual ~ObjectManagerIF(void){}
/** /**
* @brief With this call, new objects are inserted to the list. * @brief With this call, new objects are inserted to the list.
* @details The implementation shall return an error code in case the * @details The implementation shall return an error code in case the

View File

@ -45,7 +45,7 @@ class SystemObject : public SystemObjectIF {
/** /**
* @brief On destruction, the object removes itself from the list. * @brief On destruction, the object removes itself from the list.
*/ */
virtual ~SystemObject(); ~SystemObject() override;
object_id_t getObjectId() const override; object_id_t getObjectId() const override;
virtual ReturnValue_t initialize() override; virtual ReturnValue_t initialize() override;
virtual ReturnValue_t checkObjectConnections() override; virtual ReturnValue_t checkObjectConnections() override;

View File

@ -36,7 +36,7 @@ class SystemObjectIF : public EventReportingProxyIF {
/** /**
* The empty virtual destructor as required for C++ interfaces. * The empty virtual destructor as required for C++ interfaces.
*/ */
virtual ~SystemObjectIF() {} ~SystemObjectIF() override {}
/** /**
* @brief Initializes the object. * @brief Initializes the object.
* There are initialization steps which can also be done in the constructor. * There are initialization steps which can also be done in the constructor.

View File

@ -26,12 +26,12 @@ typedef SSIZE_T ssize_t;
const std::string TcpTmTcServer::DEFAULT_SERVER_PORT = tcpip::DEFAULT_SERVER_PORT; const std::string TcpTmTcServer::DEFAULT_SERVER_PORT = tcpip::DEFAULT_SERVER_PORT;
TcpTmTcServer::TcpTmTcServer(object_id_t objectId, object_id_t tmtcTcpBridge, TcpTmTcServer::TcpTmTcServer(object_id_t objectId, object_id_t tmtcTcpBridge,
size_t receptionBufferSize, size_t ringBufferSize, TcpTmTcServer::TcpConfig cfg, size_t receptionBufferSize,
std::string customTcpServerPort, ReceptionModes receptionMode) size_t ringBufferSize, ReceptionModes receptionMode)
: SystemObject(objectId), : SystemObject(objectId),
tmtcBridgeId(tmtcTcpBridge), tmtcBridgeId(tmtcTcpBridge),
receptionMode(receptionMode), receptionMode(receptionMode),
tcpConfig(std::move(customTcpServerPort)), tcpConfig(cfg),
receptionBuffer(receptionBufferSize), receptionBuffer(receptionBufferSize),
ringBuffer(ringBufferSize, true) {} ringBuffer(ringBufferSize, true) {}
@ -91,6 +91,15 @@ ReturnValue_t TcpTmTcServer::initialize() {
return returnvalue::FAILED; return returnvalue::FAILED;
} }
if (tcpConfig.reuseAddr) {
unsigned int enable = 1;
setsockopt(listenerTcpSocket, SOL_SOCKET, SO_REUSEADDR, &enable, sizeof(enable));
}
if (tcpConfig.reusePort) {
unsigned int enable = 1;
setsockopt(listenerTcpSocket, SOL_SOCKET, SO_REUSEPORT, &enable, sizeof(enable));
}
// Bind to the address found by getaddrinfo // Bind to the address found by getaddrinfo
retval = bind(listenerTcpSocket, addrResult->ai_addr, static_cast<int>(addrResult->ai_addrlen)); retval = bind(listenerTcpSocket, addrResult->ai_addr, static_cast<int>(addrResult->ai_addrlen));
if (retval == SOCKET_ERROR) { if (retval == SOCKET_ERROR) {

View File

@ -41,11 +41,11 @@ class SpacePacketParser;
*/ */
class TcpTmTcServer : public SystemObject, public TcpIpBase, public ExecutableObjectIF { class TcpTmTcServer : public SystemObject, public TcpIpBase, public ExecutableObjectIF {
public: public:
enum class ReceptionModes { SPACE_PACKETS };
struct TcpConfig { struct TcpConfig {
public: public:
explicit TcpConfig(std::string tcpPort) : tcpPort(std::move(tcpPort)) {} TcpConfig(bool reuseAddr, bool reusePort) : reuseAddr(reuseAddr), reusePort(reusePort) {}
TcpConfig(std::string tcpPort, bool reuseAddr, bool reusePort)
: tcpPort(std::move(tcpPort)), reuseAddr(reuseAddr), reusePort(reusePort) {}
/** /**
* Passed to the recv call * Passed to the recv call
@ -63,8 +63,24 @@ class TcpTmTcServer : public SystemObject, public TcpIpBase, public ExecutableOb
*/ */
int tcpTmFlags = 0; int tcpTmFlags = 0;
const std::string tcpPort; std::string tcpPort = DEFAULT_SERVER_PORT;
/**
* Sets the SO_REUSEADDR option on the socket. See
* https://man7.org/linux/man-pages/man7/socket.7.html for more details. This option is
* especially useful in a debugging and development environment where an OBSW image might be
* re-flashed oftentimes and where all incoming telecommands are received on a dedicated TCP
* port.
*/
bool reuseAddr = false;
/**
* Sets the SO_REUSEPORT option on the socket. See
* https://man7.org/linux/man-pages/man7/socket.7.html for more details.
*/
bool reusePort = false;
}; };
enum class ReceptionModes { SPACE_PACKETS };
static const std::string DEFAULT_SERVER_PORT; static const std::string DEFAULT_SERVER_PORT;
@ -80,10 +96,9 @@ class TcpTmTcServer : public SystemObject, public TcpIpBase, public ExecutableOb
* size will be the Ethernet MTU size * size will be the Ethernet MTU size
* @param customTcpServerPort The user can specify another port than the default (7301) here. * @param customTcpServerPort The user can specify another port than the default (7301) here.
*/ */
TcpTmTcServer(object_id_t objectId, object_id_t tmtcTcpBridge, TcpTmTcServer(object_id_t objectId, object_id_t tmtcTcpBridge, TcpTmTcServer::TcpConfig cfg,
size_t receptionBufferSize = RING_BUFFER_SIZE, size_t receptionBufferSize = RING_BUFFER_SIZE,
size_t ringBufferSize = RING_BUFFER_SIZE, size_t ringBufferSize = RING_BUFFER_SIZE,
std::string customTcpServerPort = DEFAULT_SERVER_PORT,
ReceptionModes receptionMode = ReceptionModes::SPACE_PACKETS); ReceptionModes receptionMode = ReceptionModes::SPACE_PACKETS);
~TcpTmTcServer() override; ~TcpTmTcServer() override;

View File

@ -69,14 +69,14 @@ ReturnValue_t Service20ParameterManagement::checkInterfaceAndAcquireMessageQueue
#if FSFW_CPP_OSTREAM_ENABLED == 1 #if FSFW_CPP_OSTREAM_ENABLED == 1
sif::error << "Service20ParameterManagement::checkInterfaceAndAcquire" sif::error << "Service20ParameterManagement::checkInterfaceAndAcquire"
<< "MessageQueue: Can't access object" << std::endl; << "MessageQueue: Can't access object" << std::endl;
sif::error << "Object ID: " << std::hex << objectId << std::dec << std::endl; sif::error << "Object ID: 0x" << std::hex << *objectId << std::dec << std::endl;
sif::error << "Make sure it implements ReceivesParameterMessagesIF!" << std::endl; sif::error << "Make sure it implements ReceivesParameterMessagesIF" << std::endl;
#else #else
sif::printError( sif::printError(
"Service20ParameterManagement::checkInterfaceAndAcquire" "Service20ParameterManagement::checkInterfaceAndAcquire"
"MessageQueue: Can't access object\n"); "MessageQueue: Can't access object\n");
sif::printError("Object ID: 0x%08x\n", *objectId); sif::printError("Object ID: 0x%08x\n", *objectId);
sif::printError("Make sure it implements ReceivesParameterMessagesIF!\n"); sif::printError("Make sure it implements ReceivesParameterMessagesIF\n");
#endif #endif
return CommandingServiceBase::INVALID_OBJECT; return CommandingServiceBase::INVALID_OBJECT;

View File

@ -1,5 +1,7 @@
#include "fsfw/pus/Service9TimeManagement.h" #include "fsfw/pus/Service9TimeManagement.h"
#include <cmath>
#include "fsfw/events/EventManagerIF.h" #include "fsfw/events/EventManagerIF.h"
#include "fsfw/pus/servicepackets/Service9Packets.h" #include "fsfw/pus/servicepackets/Service9Packets.h"
#include "fsfw/serviceinterface/ServiceInterface.h" #include "fsfw/serviceinterface/ServiceInterface.h"
@ -15,9 +17,17 @@ ReturnValue_t Service9TimeManagement::performService() { return returnvalue::OK;
ReturnValue_t Service9TimeManagement::handleRequest(uint8_t subservice) { ReturnValue_t Service9TimeManagement::handleRequest(uint8_t subservice) {
switch (subservice) { switch (subservice) {
case SUBSERVICE::SET_TIME: { case Subservice::SET_TIME: {
return setTime(); return setTime();
} }
case Subservice::DUMP_TIME: {
timeval newTime;
Clock::getClock_timeval(&newTime);
uint32_t subsecondMs =
static_cast<uint32_t>(std::floor(static_cast<double>(newTime.tv_usec) / 1000.0));
triggerEvent(CLOCK_DUMP, newTime.tv_sec, subsecondMs);
return returnvalue::OK;
}
default: default:
return AcceptsTelecommandsIF::INVALID_SUBSERVICE; return AcceptsTelecommandsIF::INVALID_SUBSERVICE;
} }
@ -33,13 +43,14 @@ ReturnValue_t Service9TimeManagement::setTime() {
return result; return result;
} }
// TODO maybe switch to getClock_usecs to report more meaningful data timeval time;
uint32_t formerUptime = Clock::getUptime_ms(); Clock::getClock_timeval(&time);
result = Clock::setClock(&timeToSet); result = Clock::setClock(&timeToSet);
if (result == returnvalue::OK) { if (result == returnvalue::OK) {
uint32_t newUptime = Clock::getUptime_ms(); timeval newTime;
triggerEvent(CLOCK_SET, newUptime, formerUptime); Clock::getClock_timeval(&newTime);
triggerEvent(CLOCK_SET, time.tv_sec, newTime.tv_sec);
return returnvalue::OK; return returnvalue::OK;
} else { } else {
triggerEvent(CLOCK_SET_FAILURE, result, 0); triggerEvent(CLOCK_SET_FAILURE, result, 0);

View File

@ -6,10 +6,13 @@
class Service9TimeManagement : public PusServiceBase { class Service9TimeManagement : public PusServiceBase {
public: public:
static constexpr uint8_t SUBSYSTEM_ID = SUBSYSTEM_ID::PUS_SERVICE_9; static constexpr uint8_t SUBSYSTEM_ID = SUBSYSTEM_ID::PUS_SERVICE_9;
static constexpr Event CLOCK_SET =
MAKE_EVENT(0, severity::INFO); //!< Clock has been set. P1: New Uptime. P2: Old Uptime //!< Clock has been set. P1: old timeval seconds. P2: new timeval seconds.
static constexpr Event CLOCK_SET_FAILURE = static constexpr Event CLOCK_SET = MAKE_EVENT(0, severity::INFO);
MAKE_EVENT(1, severity::LOW); //!< Clock could not be set. P1: Returncode. //!< Clock dump event. P1: timeval seconds P2: timeval milliseconds.
static constexpr Event CLOCK_DUMP = MAKE_EVENT(1, severity::INFO);
//!< Clock could not be set. P1: Returncode.
static constexpr Event CLOCK_SET_FAILURE = MAKE_EVENT(2, severity::LOW);
static constexpr uint8_t CLASS_ID = CLASS_ID::PUS_SERVICE_9; static constexpr uint8_t CLASS_ID = CLASS_ID::PUS_SERVICE_9;
@ -30,8 +33,9 @@ class Service9TimeManagement : public PusServiceBase {
virtual ReturnValue_t setTime(); virtual ReturnValue_t setTime();
private: private:
enum SUBSERVICE { enum Subservice {
SET_TIME = 128 //!< [EXPORT] : [COMMAND] Time command in ASCII, CUC or CDS format SET_TIME = 128, //!< [EXPORT] : [COMMAND] Time command in ASCII, CUC or CDS format
DUMP_TIME = 129,
}; };
}; };

View File

@ -20,9 +20,6 @@ SerialBufferAdapter<count_t>::SerialBufferAdapter(uint8_t* buffer, count_t buffe
buffer(buffer), buffer(buffer),
bufferLength(bufferLength) {} bufferLength(bufferLength) {}
template <typename count_t>
SerialBufferAdapter<count_t>::~SerialBufferAdapter() = default;
template <typename count_t> template <typename count_t>
ReturnValue_t SerialBufferAdapter<count_t>::serialize(uint8_t** buffer_, size_t* size, ReturnValue_t SerialBufferAdapter<count_t>::serialize(uint8_t** buffer_, size_t* size,
size_t maxSize, size_t maxSize,

View File

@ -41,7 +41,7 @@ class SerialBufferAdapter : public SerializeIF {
*/ */
SerialBufferAdapter(uint8_t* buffer, count_t bufferLength, bool serializeLength = false); SerialBufferAdapter(uint8_t* buffer, count_t bufferLength, bool serializeLength = false);
~SerialBufferAdapter() override; ~SerialBufferAdapter() override = default;
ReturnValue_t serialize(uint8_t** buffer, size_t* size, size_t maxSize, ReturnValue_t serialize(uint8_t** buffer, size_t* size, size_t maxSize,
Endianness streamEndianness) const override; Endianness streamEndianness) const override;
@ -74,4 +74,10 @@ class SerialBufferAdapter : public SerializeIF {
count_t bufferLength = 0; count_t bufferLength = 0;
}; };
// declaration of explicit instantiations (which are in the cpp)
extern template class SerialBufferAdapter<uint8_t>;
extern template class SerialBufferAdapter<uint16_t>;
extern template class SerialBufferAdapter<uint32_t>;
extern template class SerialBufferAdapter<uint64_t>;
#endif /* SERIALBUFFERADAPTER_H_ */ #endif /* SERIALBUFFERADAPTER_H_ */

View File

@ -35,6 +35,12 @@ class SerializeIF {
MAKE_RETURN_CODE(3); // !< There are too many elements to be deserialized MAKE_RETURN_CODE(3); // !< There are too many elements to be deserialized
virtual ~SerializeIF() = default; virtual ~SerializeIF() = default;
// C++11 deprecates automatic generation of copy ctor and assignment operator when
// a destructor is defined, so we need to explicitely set them to default
SerializeIF(const SerializeIF&) = default;
SerializeIF() = default;
SerializeIF& operator= ( const SerializeIF & ) = default;
/** /**
* @brief * @brief
* Function to serialize the object into a buffer with maxSize. Size represents the written * Function to serialize the object into a buffer with maxSize. Size represents the written

View File

@ -22,7 +22,7 @@ union store_address_t {
*/ */
explicit store_address_t(uint32_t rawAddress) : raw(rawAddress) {} explicit store_address_t(uint32_t rawAddress) : raw(rawAddress) {}
static store_address_t invalid() { return {}; }; static store_address_t invalid() { return {}; }
/** /**
* Constructor to create an address object using pool * Constructor to create an address object using pool

View File

@ -34,7 +34,7 @@ class ExecutableObjectIF {
* a reference to the executing task * a reference to the executing task
* @param task_ Pointer to the taskIF of this task * @param task_ Pointer to the taskIF of this task
*/ */
virtual void setTaskIF(PeriodicTaskIF* task_){}; virtual void setTaskIF(PeriodicTaskIF* task_){}
/** /**
* This function should be called after the object was assigned to a * This function should be called after the object was assigned to a

View File

@ -6,7 +6,7 @@
class RawUserDataReaderIF { class RawUserDataReaderIF {
public: public:
~RawUserDataReaderIF() = default; virtual ~RawUserDataReaderIF() = default;
[[nodiscard]] virtual const uint8_t* getUserData() const = 0; [[nodiscard]] virtual const uint8_t* getUserData() const = 0;
[[nodiscard]] virtual size_t getUserDataLen() const = 0; [[nodiscard]] virtual size_t getUserDataLen() const = 0;
}; };

View File

@ -100,5 +100,6 @@ ReturnValue_t PusTcCreator::setSerializableUserData(const SerializeIF &serializa
void PusTcCreator::setup() { void PusTcCreator::setup() {
spCreator.setPacketType(ccsds::PacketType::TC); spCreator.setPacketType(ccsds::PacketType::TC);
spCreator.setSecHeaderFlag(); spCreator.setSecHeaderFlag();
spCreator.setSeqFlags(ccsds::SequenceFlags::UNSEGMENTED);
updateSpLengthField(); updateSpLengthField();
} }

View File

@ -119,6 +119,7 @@ void PusTmCreator::setup() {
updateSpLengthField(); updateSpLengthField();
spCreator.setPacketType(ccsds::PacketType::TM); spCreator.setPacketType(ccsds::PacketType::TM);
spCreator.setSecHeaderFlag(); spCreator.setSecHeaderFlag();
spCreator.setSeqFlags(ccsds::SequenceFlags::UNSEGMENTED);
} }
void PusTmCreator::setMessageTypeCounter(uint16_t messageTypeCounter) { void PusTmCreator::setMessageTypeCounter(uint16_t messageTypeCounter) {

View File

@ -180,10 +180,6 @@ ReturnValue_t I2cComIF::requestReceiveMessage(CookieIF* cookie, size_t requestLe
} }
#else #else
#endif #endif
#endif
#if FSFW_CPP_OSTREAM_ENABLED == 1
sif::debug << "I2cComIF::requestReceiveMessage: Read " << readLen << " of " << requestLen
<< " bytes" << std::endl;
#endif #endif
return returnvalue::FAILED; return returnvalue::FAILED;
} }

View File

@ -30,4 +30,4 @@ TEST_CASE("Binary Semaphore Test", "[BinSemaphore]") {
TEST_CASE("Counting Semaphore Test", "[CountingSemaph]") { TEST_CASE("Counting Semaphore Test", "[CountingSemaph]") {
SECTION("Simple Test") {} SECTION("Simple Test") {}
} }

View File

@ -7,7 +7,7 @@
namespace addresses { namespace addresses {
/* Logical addresses have uint32_t datatype */ /* Logical addresses have uint32_t datatype */
enum logicalAddresses : address_t {}; enum LogicAddress : address_t {};
} // namespace addresses } // namespace addresses
#endif /* CONFIG_DEVICES_LOGICALADDRESSES_H_ */ #endif /* CONFIG_DEVICES_LOGICALADDRESSES_H_ */

View File

@ -5,9 +5,13 @@ set(CMAKE_C_COMPILER /opt/msvc/bin/x64/cl)
set(CMAKE_CXX_COMPILER /opt/msvc/bin/x64/cl) set(CMAKE_CXX_COMPILER /opt/msvc/bin/x64/cl)
# built in tests fail # built in tests fail
set(CMAKE_C_COMPILER_WORKS 1) set(CMAKE_C_COMPILER_WORKS ON)
set(CMAKE_CXX_COMPILER_WORKS 1) set(CMAKE_CXX_COMPILER_WORKS ON)
# fails somewhere caused by wine
# overriding internal variable DO NOT TRY THIS AT HOME!
set(CMAKE_C_ABI_COMPILED ON)
set(CMAKE_CXX_ABI_COMPILED ON)
# adjust the default behavior of the FIND_XXX() commands: # adjust the default behavior of the FIND_XXX() commands:
# search programs in the host environment # search programs in the host environment