Merge branch 'main' into sus-fdir-reduce-events
All checks were successful
EIVE/eive-obsw/pipeline/pr-main This commit looks good
All checks were successful
EIVE/eive-obsw/pipeline/pr-main This commit looks good
This commit is contained in:
commit
65bb860fb2
@ -22,6 +22,7 @@ will consitute of a breaking change warranting a new major release:
|
||||
CFDP interface.
|
||||
- Proper back pressure handling for the CFDP handler, where the `LiveTmTask` is able to throttle
|
||||
the CFDP handler.
|
||||
- Added CFDP fault handler events.
|
||||
- The EIVE system will command the payload OFF explicitely again when receiving the
|
||||
`power::POWER_LEVEL_CRITICAL` event.
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
/**
|
||||
* @brief Auto-generated event translation file. Contains 314 translations.
|
||||
* @brief Auto-generated event translation file. Contains 315 translations.
|
||||
* @details
|
||||
* Generated on: 2023-10-13 15:23:30
|
||||
* Generated on: 2023-10-19 11:29:35
|
||||
*/
|
||||
#include "translateEvents.h"
|
||||
|
||||
@ -319,6 +319,7 @@ const char *DUMP_HK_CANCELLED_STRING = "DUMP_HK_CANCELLED";
|
||||
const char *DUMP_CFDP_CANCELLED_STRING = "DUMP_CFDP_CANCELLED";
|
||||
const char *TEMPERATURE_ALL_ONES_START_STRING = "TEMPERATURE_ALL_ONES_START";
|
||||
const char *TEMPERATURE_ALL_ONES_RECOVERY_STRING = "TEMPERATURE_ALL_ONES_RECOVERY";
|
||||
const char *FAULT_HANDLER_TRIGGERED_STRING = "FAULT_HANDLER_TRIGGERED";
|
||||
|
||||
const char *translateEvents(Event event) {
|
||||
switch ((event & 0xFFFF)) {
|
||||
@ -950,6 +951,8 @@ const char *translateEvents(Event event) {
|
||||
return TEMPERATURE_ALL_ONES_START_STRING;
|
||||
case (14501):
|
||||
return TEMPERATURE_ALL_ONES_RECOVERY_STRING;
|
||||
case (14600):
|
||||
return FAULT_HANDLER_TRIGGERED_STRING;
|
||||
default:
|
||||
return "UNKNOWN_EVENT";
|
||||
}
|
||||
|
@ -1,8 +1,8 @@
|
||||
/**
|
||||
* @brief Auto-generated object translation file.
|
||||
* @details
|
||||
* Contains 174 translations.
|
||||
* Generated on: 2023-10-13 15:23:30
|
||||
* Contains 175 translations.
|
||||
* Generated on: 2023-10-19 11:29:35
|
||||
*/
|
||||
#include "translateObjects.h"
|
||||
|
||||
@ -161,6 +161,7 @@ const char *PUS_TM_FUNNEL_STRING = "PUS_TM_FUNNEL";
|
||||
const char *CFDP_TM_FUNNEL_STRING = "CFDP_TM_FUNNEL";
|
||||
const char *CFDP_HANDLER_STRING = "CFDP_HANDLER";
|
||||
const char *CFDP_DISTRIBUTOR_STRING = "CFDP_DISTRIBUTOR";
|
||||
const char *CFDP_FAULT_HANDLER_STRING = "CFDP_FAULT_HANDLER";
|
||||
const char *EIVE_SYSTEM_STRING = "EIVE_SYSTEM";
|
||||
const char *ACS_SUBSYSTEM_STRING = "ACS_SUBSYSTEM";
|
||||
const char *PL_SUBSYSTEM_STRING = "PL_SUBSYSTEM";
|
||||
@ -493,6 +494,8 @@ const char *translateObject(object_id_t object) {
|
||||
return CFDP_HANDLER_STRING;
|
||||
case 0x73000206:
|
||||
return CFDP_DISTRIBUTOR_STRING;
|
||||
case 0x73000207:
|
||||
return CFDP_FAULT_HANDLER_STRING;
|
||||
case 0x73010000:
|
||||
return EIVE_SYSTEM_STRING;
|
||||
case 0x73010001:
|
||||
|
@ -41,6 +41,7 @@ enum : uint8_t {
|
||||
PERSISTENT_TM_STORE = 143,
|
||||
SYRLINKS_COM = 144,
|
||||
SUS_HANDLER = 145,
|
||||
CFDP_APP = 146,
|
||||
COMMON_SUBSYSTEM_ID_END
|
||||
|
||||
};
|
||||
|
@ -166,6 +166,7 @@ enum commonObjects : uint32_t {
|
||||
CFDP_TM_FUNNEL = 0x73000102,
|
||||
CFDP_HANDLER = 0x73000205,
|
||||
CFDP_DISTRIBUTOR = 0x73000206,
|
||||
CFDP_FAULT_HANDLER = 0x73000207,
|
||||
MISC_TM_STORE = 0x73020001,
|
||||
OK_TM_STORE = 0x73020002,
|
||||
NOT_OK_TM_STORE = 0x73020003,
|
||||
|
@ -313,3 +313,4 @@ Event ID (dec); Event ID (hex); Name; Severity; Description; File Path
|
||||
14314;0x37ea;DUMP_CFDP_CANCELLED;LOW;P1: Number of dumped packets. P2: Total dumped bytes.;mission/persistentTmStoreDefs.h
|
||||
14500;0x38a4;TEMPERATURE_ALL_ONES_START;MEDIUM;Detected invalid values, starting invalid message counting;mission/acs/SusHandler.h
|
||||
14501;0x38a5;TEMPERATURE_ALL_ONES_RECOVERY;INFO;Detected valid values again, resetting invalid message counter. P1: Invalid message counter.;mission/acs/SusHandler.h
|
||||
14600;0x3908;FAULT_HANDLER_TRIGGERED;LOW;P1: CFDP fault handler code. P2: CFDP condition code.;mission/cfdp/defs.h
|
||||
|
|
@ -153,6 +153,7 @@
|
||||
0x73000102;CFDP_TM_FUNNEL
|
||||
0x73000205;CFDP_HANDLER
|
||||
0x73000206;CFDP_DISTRIBUTOR
|
||||
0x73000207;CFDP_FAULT_HANDLER
|
||||
0x73010000;EIVE_SYSTEM
|
||||
0x73010001;ACS_SUBSYSTEM
|
||||
0x73010002;PL_SUBSYSTEM
|
||||
|
|
@ -61,3 +61,4 @@
|
||||
143;PERSISTENT_TM_STORE
|
||||
144;SYRLINKS_COM
|
||||
145;SUS_HANDLER
|
||||
146;CFDP_APP
|
||||
|
|
@ -313,3 +313,4 @@ Event ID (dec); Event ID (hex); Name; Severity; Description; File Path
|
||||
14314;0x37ea;DUMP_CFDP_CANCELLED;LOW;P1: Number of dumped packets. P2: Total dumped bytes.;mission/persistentTmStoreDefs.h
|
||||
14500;0x38a4;TEMPERATURE_ALL_ONES_START;MEDIUM;Detected invalid values, starting invalid message counting;mission/acs/SusHandler.h
|
||||
14501;0x38a5;TEMPERATURE_ALL_ONES_RECOVERY;INFO;Detected valid values again, resetting invalid message counter. P1: Invalid message counter.;mission/acs/SusHandler.h
|
||||
14600;0x3908;FAULT_HANDLER_TRIGGERED;LOW;P1: CFDP fault handler code. P2: CFDP condition code.;mission/cfdp/defs.h
|
||||
|
|
@ -158,6 +158,7 @@
|
||||
0x73000102;CFDP_TM_FUNNEL
|
||||
0x73000205;CFDP_HANDLER
|
||||
0x73000206;CFDP_DISTRIBUTOR
|
||||
0x73000207;CFDP_FAULT_HANDLER
|
||||
0x73010000;EIVE_SYSTEM
|
||||
0x73010001;ACS_SUBSYSTEM
|
||||
0x73010002;PL_SUBSYSTEM
|
||||
|
|
@ -61,3 +61,4 @@
|
||||
143;PERSISTENT_TM_STORE
|
||||
144;SYRLINKS_COM
|
||||
145;SUS_HANDLER
|
||||
146;CFDP_APP
|
||||
|
|
@ -1,7 +1,7 @@
|
||||
/**
|
||||
* @brief Auto-generated event translation file. Contains 314 translations.
|
||||
* @brief Auto-generated event translation file. Contains 315 translations.
|
||||
* @details
|
||||
* Generated on: 2023-10-13 15:23:30
|
||||
* Generated on: 2023-10-19 11:29:35
|
||||
*/
|
||||
#include "translateEvents.h"
|
||||
|
||||
@ -319,6 +319,7 @@ const char *DUMP_HK_CANCELLED_STRING = "DUMP_HK_CANCELLED";
|
||||
const char *DUMP_CFDP_CANCELLED_STRING = "DUMP_CFDP_CANCELLED";
|
||||
const char *TEMPERATURE_ALL_ONES_START_STRING = "TEMPERATURE_ALL_ONES_START";
|
||||
const char *TEMPERATURE_ALL_ONES_RECOVERY_STRING = "TEMPERATURE_ALL_ONES_RECOVERY";
|
||||
const char *FAULT_HANDLER_TRIGGERED_STRING = "FAULT_HANDLER_TRIGGERED";
|
||||
|
||||
const char *translateEvents(Event event) {
|
||||
switch ((event & 0xFFFF)) {
|
||||
@ -950,6 +951,8 @@ const char *translateEvents(Event event) {
|
||||
return TEMPERATURE_ALL_ONES_START_STRING;
|
||||
case (14501):
|
||||
return TEMPERATURE_ALL_ONES_RECOVERY_STRING;
|
||||
case (14600):
|
||||
return FAULT_HANDLER_TRIGGERED_STRING;
|
||||
default:
|
||||
return "UNKNOWN_EVENT";
|
||||
}
|
||||
|
@ -1,8 +1,8 @@
|
||||
/**
|
||||
* @brief Auto-generated object translation file.
|
||||
* @details
|
||||
* Contains 178 translations.
|
||||
* Generated on: 2023-10-13 15:23:30
|
||||
* Contains 179 translations.
|
||||
* Generated on: 2023-10-19 11:29:35
|
||||
*/
|
||||
#include "translateObjects.h"
|
||||
|
||||
@ -166,6 +166,7 @@ const char *PUS_TM_FUNNEL_STRING = "PUS_TM_FUNNEL";
|
||||
const char *CFDP_TM_FUNNEL_STRING = "CFDP_TM_FUNNEL";
|
||||
const char *CFDP_HANDLER_STRING = "CFDP_HANDLER";
|
||||
const char *CFDP_DISTRIBUTOR_STRING = "CFDP_DISTRIBUTOR";
|
||||
const char *CFDP_FAULT_HANDLER_STRING = "CFDP_FAULT_HANDLER";
|
||||
const char *EIVE_SYSTEM_STRING = "EIVE_SYSTEM";
|
||||
const char *ACS_SUBSYSTEM_STRING = "ACS_SUBSYSTEM";
|
||||
const char *PL_SUBSYSTEM_STRING = "PL_SUBSYSTEM";
|
||||
@ -507,6 +508,8 @@ const char *translateObject(object_id_t object) {
|
||||
return CFDP_HANDLER_STRING;
|
||||
case 0x73000206:
|
||||
return CFDP_DISTRIBUTOR_STRING;
|
||||
case 0x73000207:
|
||||
return CFDP_FAULT_HANDLER_STRING;
|
||||
case 0x73010000:
|
||||
return EIVE_SYSTEM_STRING;
|
||||
case 0x73010001:
|
||||
|
@ -1,7 +1,7 @@
|
||||
/**
|
||||
* @brief Auto-generated event translation file. Contains 314 translations.
|
||||
* @brief Auto-generated event translation file. Contains 315 translations.
|
||||
* @details
|
||||
* Generated on: 2023-10-13 15:23:30
|
||||
* Generated on: 2023-10-19 11:29:35
|
||||
*/
|
||||
#include "translateEvents.h"
|
||||
|
||||
@ -319,6 +319,7 @@ const char *DUMP_HK_CANCELLED_STRING = "DUMP_HK_CANCELLED";
|
||||
const char *DUMP_CFDP_CANCELLED_STRING = "DUMP_CFDP_CANCELLED";
|
||||
const char *TEMPERATURE_ALL_ONES_START_STRING = "TEMPERATURE_ALL_ONES_START";
|
||||
const char *TEMPERATURE_ALL_ONES_RECOVERY_STRING = "TEMPERATURE_ALL_ONES_RECOVERY";
|
||||
const char *FAULT_HANDLER_TRIGGERED_STRING = "FAULT_HANDLER_TRIGGERED";
|
||||
|
||||
const char *translateEvents(Event event) {
|
||||
switch ((event & 0xFFFF)) {
|
||||
@ -950,6 +951,8 @@ const char *translateEvents(Event event) {
|
||||
return TEMPERATURE_ALL_ONES_START_STRING;
|
||||
case (14501):
|
||||
return TEMPERATURE_ALL_ONES_RECOVERY_STRING;
|
||||
case (14600):
|
||||
return FAULT_HANDLER_TRIGGERED_STRING;
|
||||
default:
|
||||
return "UNKNOWN_EVENT";
|
||||
}
|
||||
|
@ -1,8 +1,8 @@
|
||||
/**
|
||||
* @brief Auto-generated object translation file.
|
||||
* @details
|
||||
* Contains 178 translations.
|
||||
* Generated on: 2023-10-13 15:23:30
|
||||
* Contains 179 translations.
|
||||
* Generated on: 2023-10-19 11:29:35
|
||||
*/
|
||||
#include "translateObjects.h"
|
||||
|
||||
@ -166,6 +166,7 @@ const char *PUS_TM_FUNNEL_STRING = "PUS_TM_FUNNEL";
|
||||
const char *CFDP_TM_FUNNEL_STRING = "CFDP_TM_FUNNEL";
|
||||
const char *CFDP_HANDLER_STRING = "CFDP_HANDLER";
|
||||
const char *CFDP_DISTRIBUTOR_STRING = "CFDP_DISTRIBUTOR";
|
||||
const char *CFDP_FAULT_HANDLER_STRING = "CFDP_FAULT_HANDLER";
|
||||
const char *EIVE_SYSTEM_STRING = "EIVE_SYSTEM";
|
||||
const char *ACS_SUBSYSTEM_STRING = "ACS_SUBSYSTEM";
|
||||
const char *PL_SUBSYSTEM_STRING = "PL_SUBSYSTEM";
|
||||
@ -507,6 +508,8 @@ const char *translateObject(object_id_t object) {
|
||||
return CFDP_HANDLER_STRING;
|
||||
case 0x73000206:
|
||||
return CFDP_DISTRIBUTOR_STRING;
|
||||
case 0x73000207:
|
||||
return CFDP_FAULT_HANDLER_STRING;
|
||||
case 0x73010000:
|
||||
return EIVE_SYSTEM_STRING;
|
||||
case 0x73010001:
|
||||
|
@ -1,28 +1,35 @@
|
||||
#ifndef MISSION_CFDP_CFDPFAULTHANDLER_H_
|
||||
#define MISSION_CFDP_CFDPFAULTHANDLER_H_
|
||||
|
||||
#include "defs.h"
|
||||
#include "fsfw/cfdp.h"
|
||||
|
||||
namespace cfdp {
|
||||
|
||||
class EiveFaultHandler : public cfdp::FaultHandlerBase {
|
||||
class EiveFaultHandler : public cfdp::FaultHandlerBase, public SystemObject {
|
||||
public:
|
||||
EiveFaultHandler(object_id_t objectId) : SystemObject(objectId) {}
|
||||
|
||||
void noticeOfSuspensionCb(cfdp::TransactionId& id, cfdp::ConditionCode code) override {
|
||||
sif::warning << "Notice of suspension detected for transaction " << id
|
||||
<< " with condition code: " << cfdp::getConditionCodeString(code) << std::endl;
|
||||
triggerEvent(cfdp::FAULT_HANDLER_TRIGGERED, FaultHandlerCode::NOTICE_OF_SUSPENSION, code);
|
||||
}
|
||||
void noticeOfCancellationCb(cfdp::TransactionId& id, cfdp::ConditionCode code) override {
|
||||
sif::warning << "Notice of suspension detected for transaction " << id
|
||||
<< " with condition code: " << cfdp::getConditionCodeString(code) << std::endl;
|
||||
triggerEvent(cfdp::FAULT_HANDLER_TRIGGERED, FaultHandlerCode::NOTICE_OF_CANCELLATION, code);
|
||||
}
|
||||
void abandonCb(cfdp::TransactionId& id, cfdp::ConditionCode code) override {
|
||||
sif::warning << "Transaction " << id
|
||||
<< " was abandoned, condition code : " << cfdp::getConditionCodeString(code)
|
||||
<< std::endl;
|
||||
triggerEvent(cfdp::FAULT_HANDLER_TRIGGERED, FaultHandlerCode::ABANDON_TRANSACTION, code);
|
||||
}
|
||||
void ignoreCb(cfdp::TransactionId& id, cfdp::ConditionCode code) override {
|
||||
sif::warning << "Fault ignored for transaction " << id
|
||||
<< ", condition code: " << cfdp::getConditionCodeString(code) << std::endl;
|
||||
triggerEvent(cfdp::FAULT_HANDLER_TRIGGERED, FaultHandlerCode::IGNORE_ERROR, code);
|
||||
}
|
||||
};
|
||||
|
||||
|
16
mission/cfdp/defs.h
Normal file
16
mission/cfdp/defs.h
Normal file
@ -0,0 +1,16 @@
|
||||
#ifndef MISSION_CFDP_DEFS_H_
|
||||
#define MISSION_CFDP_DEFS_H_
|
||||
|
||||
#include "eive/eventSubsystemIds.h"
|
||||
#include "fsfw/events/Event.h"
|
||||
|
||||
namespace cfdp {
|
||||
|
||||
static constexpr uint8_t SUBSYSTEM_ID = SUBSYSTEM_ID::CFDP_APP;
|
||||
|
||||
//! [EXPORT] : [COMMENT] P1: CFDP fault handler code. P2: CFDP condition code.
|
||||
static constexpr Event FAULT_HANDLER_TRIGGERED = event::makeEvent(SUBSYSTEM_ID, 0, severity::LOW);
|
||||
|
||||
} // namespace cfdp
|
||||
|
||||
#endif /* MISSION_CFDP_DEFS_H_ */
|
@ -86,7 +86,6 @@ EntityId REMOTE_CFDP_ID(UnsignedByteField<uint16_t>(config::EIVE_GROUND_CFDP_ENT
|
||||
RemoteEntityCfg GROUND_REMOTE_CFG(REMOTE_CFDP_ID);
|
||||
OneRemoteConfigProvider REMOTE_CFG_PROVIDER(GROUND_REMOTE_CFG);
|
||||
HostFilesystem HOST_FS;
|
||||
EiveFaultHandler EIVE_FAULT_HANDLER;
|
||||
|
||||
} // namespace cfdp
|
||||
|
||||
@ -290,7 +289,8 @@ void ObjectFactory::produceGenericObjects(HealthTableIF** healthTable_, PusTmFun
|
||||
cfdp::EntityId localId(apid);
|
||||
GROUND_REMOTE_CFG.defaultChecksum = cfdp::ChecksumType::CRC_32;
|
||||
GROUND_REMOTE_CFG.maxFileSegmentLen = config::CFDP_MAX_FILE_SEGMENT_LEN;
|
||||
CfdpHandlerCfg cfdpCfg(localId, indicationCfg, *eiveUserHandler, EIVE_FAULT_HANDLER, PACKET_LIST,
|
||||
auto eiveFaultHandler = new EiveFaultHandler(objects::CFDP_FAULT_HANDLER);
|
||||
CfdpHandlerCfg cfdpCfg(localId, indicationCfg, *eiveUserHandler, *eiveFaultHandler, PACKET_LIST,
|
||||
LOST_SEGMENTS, REMOTE_CFG_PROVIDER);
|
||||
auto* cfdpHandler = new CfdpHandler(params, cfdpCfg, signals::CFDP_CHANNEL_THROTTLE_SIGNAL);
|
||||
// All CFDP packets arrive wrapped inside CCSDS space packets
|
||||
|
2
tmtc
2
tmtc
@ -1 +1 @@
|
||||
Subproject commit 60f7ae5453b387ee5ebcf6a338c34284004dbce7
|
||||
Subproject commit 43d6b986953a815c7c020cf73a957f1678c76549
|
Loading…
Reference in New Issue
Block a user