applied clanf formatting
Some checks are pending
EIVE/eive-obsw/pipeline/head Build started...
EIVE/eive-obsw/pipeline/pr-develop This commit looks good

This commit is contained in:
Jakob Meier 2022-01-31 08:09:58 +01:00
parent c1726f897b
commit 1651926efa
8 changed files with 28 additions and 33 deletions

View File

@ -263,7 +263,7 @@ void initmission::createPstTasks(TaskFactory& factory,
sif::error << "InitMission::initTasks: GomSpace PST initialization failed!" << std::endl;
}
taskVec.push_back(gomSpacePstTask);
#else /* BOARD_TE7020 == 0 */
#else /* BOARD_TE7020 == 0 */
FixedTimeslotTaskIF* pollingSequenceTaskTE0720 = factory.createFixedTimeslotTask(
"PST_TASK_TE0720", 30, PeriodicTaskIF::MINIMUM_STACK_SIZE * 8, 3.0, missedDeadlineFunc);
result = pst::pollingSequenceTE0720(pollingSequenceTaskTE0720);

View File

@ -75,10 +75,10 @@
#include "linux/boardtest/LibgpiodTest.h"
#endif
#include <linux/obc/AxiPtmeConfig.h>
#include <linux/obc/PapbVcInterface.h>
#include <linux/obc/PdecHandler.h>
#include <linux/obc/Ptme.h>
#include <linux/obc/AxiPtmeConfig.h>
#include <linux/obc/PtmeConfig.h>
ResetArgs resetArgsGnss0;

View File

@ -109,8 +109,8 @@ ReturnValue_t AxiPtmeConfig::writeBit(uint32_t regOffset, bool bitVal, BitPos bi
if (result != HasReturnvaluesIF::RETURN_OK) {
return result;
}
uint32_t writeVal = (readVal & ~(1 << static_cast<uint32_t>(bitPos))) |
bitVal << static_cast<uint32_t>(bitPos);
uint32_t writeVal =
(readVal & ~(1 << static_cast<uint32_t>(bitPos))) | bitVal << static_cast<uint32_t>(bitPos);
result = writeReg(regOffset, writeVal);
if (result != HasReturnvaluesIF::RETURN_OK) {
return result;

View File

@ -58,10 +58,7 @@ class AxiPtmeConfig : public SystemObject {
static const uint32_t COMMON_CONFIG_REG = 0x4;
static const uint32_t ADRESS_DIVIDER = 4;
enum class BitPos : uint32_t {
EN_TX_CLK_MANIPULATOR,
INVERT_CLOCK
};
enum class BitPos : uint32_t { EN_TX_CLK_MANIPULATOR, INVERT_CLOCK };
std::string axiUio;
std::string uioMap;

View File

@ -27,26 +27,24 @@ ReturnValue_t PtmeConfig::setRate(uint32_t bitRate) {
}
ReturnValue_t PtmeConfig::invertTxClock(bool invert) {
ReturnValue_t result = RETURN_OK;
if (invert) {
result = axiPtmeConfig->enableTxclockInversion();
}
else {
result = axiPtmeConfig->disableTxclockInversion();
}
if (result != RETURN_OK) {
return CLK_INVERSION_FAILED;
}
return result;
ReturnValue_t result = RETURN_OK;
if (invert) {
result = axiPtmeConfig->enableTxclockInversion();
} else {
result = axiPtmeConfig->disableTxclockInversion();
}
if (result != RETURN_OK) {
return CLK_INVERSION_FAILED;
}
return result;
}
ReturnValue_t PtmeConfig::configTxManipulator(bool enable) {
ReturnValue_t result = RETURN_OK;
if (enable) {
result = axiPtmeConfig->enableTxclockManipulator();
}
else {
result = axiPtmeConfig->disableTxclockManipulator();
}
return result;
ReturnValue_t result = RETURN_OK;
if (enable) {
result = axiPtmeConfig->enableTxclockManipulator();
} else {
result = axiPtmeConfig->disableTxclockManipulator();
}
return result;
}

View File

@ -1,10 +1,10 @@
#ifndef LINUX_OBC_PTMECONFIG_H_
#define LINUX_OBC_PTMECONFIG_H_
#include "AxiPtmeConfig.h"
#include "fsfw/objectmanager/SystemObject.h"
#include "fsfw/returnvalues/HasReturnvaluesIF.h"
#include "linux/obc/PtmeConfig.h"
#include "AxiPtmeConfig.h"
/**
* @brief Class to configure donwlink specific parameters in the PTME IP core.
@ -59,10 +59,11 @@ class PtmeConfig : public SystemObject, public HasReturnvaluesIF {
static const ReturnValue_t RATE_NOT_SUPPORTED = MAKE_RETURN_CODE(0xA0);
//! [EXPORT] : [COMMENT] Bad bitrate has been commanded (e.g. 0)
static const ReturnValue_t BAD_BIT_RATE = MAKE_RETURN_CODE(0xA1);
//! [EXPORT] : [COMMENT] Failed to invert clock and thus change the time the data is updated with respect to the tx clock
//! [EXPORT] : [COMMENT] Failed to invert clock and thus change the time the data is updated with
//! respect to the tx clock
static const ReturnValue_t CLK_INVERSION_FAILED = MAKE_RETURN_CODE(0xA2);
//! [EXPORT] : [COMMENT] Failed to change configuration bit of tx clock manipulator
static const ReturnValue_t TX_MANIPULATOR_CONFIG_FAILED = MAKE_RETURN_CODE(0xA3);
static const ReturnValue_t TX_MANIPULATOR_CONFIG_FAILED = MAKE_RETURN_CODE(0xA3);
// Bitrate register field is only 8 bit wide
static const uint32_t MAX_BITRATE = 0xFF;

View File

@ -51,8 +51,7 @@ class CCSDSHandler : public SystemObject,
* @param enTxData GPIO ID of RS485 tx data enable
*/
CCSDSHandler(object_id_t objectId, object_id_t ptmeId, object_id_t tcDestination,
PtmeConfig* ptmeConfig, GpioIF* gpioIF, gpioId_t enTxClock,
gpioId_t enTxData);
PtmeConfig* ptmeConfig, GpioIF* gpioIF, gpioId_t enTxClock, gpioId_t enTxData);
~CCSDSHandler();

2
tmtc

@ -1 +1 @@
Subproject commit c50ef12729309f9851d91621e2f289d574735ab8
Subproject commit 2e326da175bb0e806b460507ddcf2977cd1a2372