This commit is contained in:
parent
433373e6b7
commit
b8e7363744
@ -348,10 +348,17 @@ void PlocMpsocHandler::fillCommandAndReplyMap() {
|
|||||||
|
|
||||||
ReturnValue_t PlocMpsocHandler::scanForReply(const uint8_t* start, size_t remainingSize,
|
ReturnValue_t PlocMpsocHandler::scanForReply(const uint8_t* start, size_t remainingSize,
|
||||||
DeviceCommandId_t* foundId, size_t* foundLen) {
|
DeviceCommandId_t* foundId, size_t* foundLen) {
|
||||||
|
// sif::debug << "received reply with length" << remainingSize << std::endl;
|
||||||
|
// arrayprinter::print(start, remainingSize);
|
||||||
ReturnValue_t result = returnvalue::OK;
|
ReturnValue_t result = returnvalue::OK;
|
||||||
|
|
||||||
SpacePacketReader spacePacket;
|
SpacePacketReader spacePacket;
|
||||||
spacePacket.setReadOnlyData(start, remainingSize);
|
spacePacket.setReadOnlyData(start, remainingSize);
|
||||||
|
if (DEBUG_MPSOC_COMMUNICATION) {
|
||||||
|
sif::debug << "RECV MPSOC packet. APID 0x" << std::hex << std::setw(3) << spacePacket.getApid()
|
||||||
|
<< std::dec << " Size " << spacePacket.getFullPacketLen() << " SSC "
|
||||||
|
<< spacePacket.getSequenceCount() << std::endl;
|
||||||
|
}
|
||||||
if (spacePacket.isNull()) {
|
if (spacePacket.isNull()) {
|
||||||
return returnvalue::FAILED;
|
return returnvalue::FAILED;
|
||||||
}
|
}
|
||||||
@ -467,7 +474,7 @@ void PlocMpsocHandler::setNormalDatapoolEntriesInvalid() {
|
|||||||
hkReport.setValidity(false, true);
|
hkReport.setValidity(false, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
uint32_t PlocMpsocHandler::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return 10000; }
|
uint32_t PlocMpsocHandler::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return 15000; }
|
||||||
|
|
||||||
ReturnValue_t PlocMpsocHandler::initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
|
ReturnValue_t PlocMpsocHandler::initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
|
||||||
LocalDataPoolManager& poolManager) {
|
LocalDataPoolManager& poolManager) {
|
||||||
@ -700,6 +707,12 @@ ReturnValue_t PlocMpsocHandler::finishTcPrep(mpsoc::TcBase& tcBase) {
|
|||||||
rawPacket = commandBuffer;
|
rawPacket = commandBuffer;
|
||||||
rawPacketLen = tcBase.getFullPacketLen();
|
rawPacketLen = tcBase.getFullPacketLen();
|
||||||
sequenceCount++;
|
sequenceCount++;
|
||||||
|
|
||||||
|
if (DEBUG_MPSOC_COMMUNICATION) {
|
||||||
|
sif::debug << "SEND MPSOC packet. APID 0x" << std::hex << std::setw(3) << tcBase.getApid()
|
||||||
|
<< " Size " << std::dec << tcBase.getFullPacketLen() << " SSC "
|
||||||
|
<< tcBase.getSeqCount() << std::endl;
|
||||||
|
}
|
||||||
return returnvalue::OK;
|
return returnvalue::OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1223,10 +1236,12 @@ void PlocMpsocHandler::dataReceived(ActionId_t actionId, const uint8_t* data, ui
|
|||||||
|
|
||||||
void PlocMpsocHandler::completionSuccessfulReceived(ActionId_t actionId) {
|
void PlocMpsocHandler::completionSuccessfulReceived(ActionId_t actionId) {
|
||||||
if (actionId == supv::ACK_REPORT) {
|
if (actionId == supv::ACK_REPORT) {
|
||||||
sif::warning
|
// I seriously don't know why this happens..
|
||||||
<< "PlocMpsocHandler::completionSuccessfulReceived: Only received ACK report. Consider "
|
// sif::warning
|
||||||
"increasing the MPSoC boot timer."
|
// << "PlocMpsocHandler::completionSuccessfulReceived: Only received ACK report. Consider
|
||||||
<< std::endl;
|
// "
|
||||||
|
// "increasing the MPSoC boot timer."
|
||||||
|
// << std::endl;
|
||||||
} else if (actionId != supv::EXE_REPORT) {
|
} else if (actionId != supv::EXE_REPORT) {
|
||||||
sif::warning << "PlocMpsocHandler::completionSuccessfulReceived: Did not expect the action "
|
sif::warning << "PlocMpsocHandler::completionSuccessfulReceived: Did not expect the action "
|
||||||
<< "ID " << actionId << std::endl;
|
<< "ID " << actionId << std::endl;
|
||||||
|
@ -17,6 +17,8 @@
|
|||||||
#include "fsfw_hal/linux/gpio/Gpio.h"
|
#include "fsfw_hal/linux/gpio/Gpio.h"
|
||||||
#include "fsfw_hal/linux/serial/SerialComIF.h"
|
#include "fsfw_hal/linux/serial/SerialComIF.h"
|
||||||
|
|
||||||
|
static constexpr bool DEBUG_MPSOC_COMMUNICATION = true;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief This is the device handler for the MPSoC of the payload computer.
|
* @brief This is the device handler for the MPSoC of the payload computer.
|
||||||
*
|
*
|
||||||
|
Loading…
Reference in New Issue
Block a user