PLOC SUPV Update to newer firmware #316

Merged
muellerr merged 99 commits from mueller/tas_ploc_supv_update into develop 2022-11-18 14:27:13 +01:00
2 changed files with 10 additions and 2 deletions
Showing only changes of commit 74837753bf - Show all commits

View File

@ -27,7 +27,9 @@
using namespace returnvalue;
PlocSupvHelper::PlocSupvHelper(object_id_t objectId)
: SystemObject(objectId), recRingBuf(4096, true) {
: SystemObject(objectId),
recRingBuf(4096, true),
ipcRingBuf(1200 * MAX_STORED_DECODED_PACKETS, true) {
spParams.maxSize = sizeof(commandBuffer);
resetSpParams();
semaphore = SemaphoreFactory::instance()->createBinarySemaphore();

View File

@ -7,6 +7,7 @@
#include <string>
#include "OBSWConfig.h"
#include "fsfw/container/FIFO.h"
#include "fsfw/devicehandlers/CookieIF.h"
#include "fsfw/objectmanager/SystemObject.h"
#include "fsfw/osal/linux/BinarySemaphore.h"
@ -172,6 +173,7 @@ class PlocSupvHelper : public DeviceCommunicationIF,
static const uint32_t CRC_EXECUTION_TIMEOUT = 60000;
static const uint32_t PREPARE_UPDATE_EXECUTION_REPORT = 2000;
static constexpr uint8_t MAX_STORED_DECODED_PACKETS = 4;
static constexpr uint8_t HDLC_START_MARKER = 0x7C;
static constexpr uint8_t HDLC_END_MARKER = 0x7E;
@ -224,10 +226,14 @@ class PlocSupvHelper : public DeviceCommunicationIF,
#ifdef XIPHOS_Q7S
SdCardManager* sdcMan = nullptr;
#endif
SimpleRingBuffer recRingBuf;
std::array<uint8_t, 2048> recBuf = {};
std::array<uint8_t, 2048> encodedBuf = {};
std::array<uint8_t, 1200> decodedBuf = {};
SimpleRingBuffer recRingBuf;
std::array<uint8_t, 1200> ipcBuffer = {};
SimpleRingBuffer ipcRingBuf;
FIFO<size_t, MAX_STORED_DECODED_PACKETS> ipcQueue;
uint8_t commandBuffer[supv::MAX_COMMAND_SIZE]{};
SpacePacketCreator creator;
ploc::SpTcParams spParams = ploc::SpTcParams(creator);