relax sus fdir
This commit is contained in:
@ -87,6 +87,21 @@ ReturnValue_t SusHandler::interpretDeviceReply(DeviceCommandId_t id, const uint8
|
||||
commandExecuted = true;
|
||||
}
|
||||
PoolReadGuard pg(&dataset);
|
||||
// In a previous stricter FDIR variant, this was considered faulty communication and was already
|
||||
// handled in the communication interface. However, the SUS devices probably glitch in orbit,
|
||||
// so the FDIR was relaxed. The fault case check previously used now only leads to the dataset
|
||||
// being marked invalid, shifting more responsibility of determining and setting SUS devices
|
||||
// faulty to the operator.
|
||||
|
||||
// UPDATE: Step1: First determine how often and whether this happens at all
|
||||
if (reply->tempRaw == 0xfff) {
|
||||
if (faultyDataEventCd.hasTimedOut()) {
|
||||
triggerEvent(TEMPERATURE_IS_ALL_ONES);
|
||||
faultyDataEventCd.resetTimer();
|
||||
}
|
||||
// dataset.setValidity(false, true);
|
||||
// return returnvalue::OK;
|
||||
}
|
||||
dataset.setValidity(true, true);
|
||||
dataset.tempC = max1227::getTemperature(reply->tempRaw);
|
||||
std::memcpy(dataset.channels.value, reply->channelsRaw, sizeof(reply->channelsRaw));
|
||||
|
@ -15,7 +15,9 @@ class SusHandler : public DeviceHandlerBase {
|
||||
static constexpr DeviceCommandId_t REPLY = 0x77;
|
||||
|
||||
static const uint8_t INTERFACE_ID = CLASS_ID::SUS_HANDLER;
|
||||
static const uint8_t SUBSYSTEM_ID = SUBSYSTEM_ID::SUS_BOARD_ASS;
|
||||
static const uint8_t SUBSYSTEM_ID = SUBSYSTEM_ID::SUS_HANDLER;
|
||||
|
||||
static constexpr Event TEMPERATURE_IS_ALL_ONES = event::makeEvent(SUBSYSTEM_ID, 0, severity::LOW);
|
||||
|
||||
SusHandler(uint32_t objectId, uint8_t susIdx, object_id_t deviceCommunication,
|
||||
CookieIF *comCookie);
|
||||
@ -43,6 +45,7 @@ class SusHandler : public DeviceHandlerBase {
|
||||
LocalPoolDataSetBase *getDataSetHandle(sid_t sid) override;
|
||||
|
||||
private:
|
||||
Countdown faultyDataEventCd = Countdown(60000);
|
||||
susMax1227::SusDataset dataset;
|
||||
acs::SusRequest request{};
|
||||
uint8_t susIdx;
|
||||
|
Reference in New Issue
Block a user