v1.9.0 #175

Merged
muellerr merged 623 commits from develop into main 2022-03-08 10:32:41 +01:00
4 changed files with 10 additions and 10 deletions
Showing only changes of commit 521b47d9fc - Show all commits

View File

@ -147,6 +147,7 @@ void ObjectFactory::produce(void* args) {
new I2cCookie(addresses::IMTQ, IMTQ::MAX_REPLY_SIZE, q7s::I2C_DEFAULT_DEV); new I2cCookie(addresses::IMTQ, IMTQ::MAX_REPLY_SIZE, q7s::I2C_DEFAULT_DEV);
auto imtqHandler = new IMTQHandler(objects::IMTQ_HANDLER, objects::I2C_COM_IF, imtqI2cCookie); auto imtqHandler = new IMTQHandler(objects::IMTQ_HANDLER, objects::I2C_COM_IF, imtqI2cCookie);
#if OBSW_DEBUG_IMTQ == 1 #if OBSW_DEBUG_IMTQ == 1
imtqHandler->setToGoToNormal();
imtqHandler->setStartUpImmediately(); imtqHandler->setStartUpImmediately();
#endif #endif
#endif #endif

View File

@ -517,7 +517,6 @@ ReturnValue_t pst::pstSpi(FixedTimeslotTaskIF *thisSequence) {
} }
ReturnValue_t pst::pstI2c(FixedTimeslotTaskIF *thisSequence) { ReturnValue_t pst::pstI2c(FixedTimeslotTaskIF *thisSequence) {
// Length of a communication cycle // Length of a communication cycle
uint32_t length = thisSequence->getPeriodMs(); uint32_t length = thisSequence->getPeriodMs();
#if OBSW_ADD_MGT == 1 #if OBSW_ADD_MGT == 1

View File

@ -2,9 +2,8 @@
#include <fsfw/datapool/PoolReadGuard.h> #include <fsfw/datapool/PoolReadGuard.h>
#include <fsfw/globalfunctions/CRC.h> #include <fsfw/globalfunctions/CRC.h>
#include <math.h>
#include "OBSWConfig.h" #include <cmath>
IMTQHandler::IMTQHandler(object_id_t objectId, object_id_t comIF, CookieIF* comCookie) IMTQHandler::IMTQHandler(object_id_t objectId, object_id_t comIF, CookieIF* comCookie)
: DeviceHandlerBase(objectId, comIF, comCookie), : DeviceHandlerBase(objectId, comIF, comCookie),
@ -25,11 +24,11 @@ IMTQHandler::IMTQHandler(object_id_t objectId, object_id_t comIF, CookieIF* comC
IMTQHandler::~IMTQHandler() {} IMTQHandler::~IMTQHandler() {}
void IMTQHandler::doStartUp() { void IMTQHandler::doStartUp() {
#if OBSW_SWITCH_TO_NORMAL_MODE_AFTER_STARTUP == 1 if (goToNormalMode) {
setMode(MODE_NORMAL); setMode(MODE_NORMAL);
#else } else {
setMode(_MODE_TO_ON); setMode(_MODE_TO_ON);
#endif }
} }
void IMTQHandler::doShutDown() { setMode(_MODE_POWER_DOWN); } void IMTQHandler::doShutDown() { setMode(_MODE_POWER_DOWN); }
@ -694,7 +693,7 @@ void IMTQHandler::fillEngHkDataset(const uint8_t* packet) {
#endif #endif
} }
void IMTQHandler::setModeNormal() { mode = MODE_NORMAL; } void IMTQHandler::setToGoToNormal() { mode = MODE_NORMAL; }
void IMTQHandler::handleDeviceTM(const uint8_t* data, size_t dataSize, DeviceCommandId_t replyId) { void IMTQHandler::handleDeviceTM(const uint8_t* data, size_t dataSize, DeviceCommandId_t replyId) {
if (wiretappingMode == RAW) { if (wiretappingMode == RAW) {

View File

@ -18,7 +18,7 @@ class IMTQHandler : public DeviceHandlerBase {
/** /**
* @brief Sets mode to MODE_NORMAL. Can be used for debugging. * @brief Sets mode to MODE_NORMAL. Can be used for debugging.
*/ */
void setModeNormal(); void setToGoToNormal();
protected: protected:
void doStartUp() override; void doStartUp() override;
@ -96,6 +96,7 @@ class IMTQHandler : public DeviceHandlerBase {
IMTQ::NegZSelfTestSet negZselfTestDataset; IMTQ::NegZSelfTestSet negZselfTestDataset;
uint8_t commandBuffer[IMTQ::MAX_COMMAND_SIZE]; uint8_t commandBuffer[IMTQ::MAX_COMMAND_SIZE];
bool goToNormalMode = false;
enum class CommunicationStep { enum class CommunicationStep {
GET_ENG_HK_DATA, GET_ENG_HK_DATA,