I2C reboot procedure for EIVE system #578

Merged
muellerr merged 17 commits from feature_i2c_reboot_procedure into develop 2023-04-07 11:07:05 +02:00
45 changed files with 620 additions and 402 deletions

View File

@ -1,7 +1,7 @@
/** /**
* @brief Auto-generated event translation file. Contains 284 translations. * @brief Auto-generated event translation file. Contains 285 translations.
* @details * @details
* Generated on: 2023-04-04 13:59:07 * Generated on: 2023-04-07 11:06:14
*/ */
#include "translateEvents.h" #include "translateEvents.h"
@ -266,7 +266,8 @@ const char *VERSION_INFO_STRING = "VERSION_INFO";
const char *CURRENT_IMAGE_INFO_STRING = "CURRENT_IMAGE_INFO"; const char *CURRENT_IMAGE_INFO_STRING = "CURRENT_IMAGE_INFO";
const char *REBOOT_COUNTER_STRING = "REBOOT_COUNTER"; const char *REBOOT_COUNTER_STRING = "REBOOT_COUNTER";
const char *INDIVIDUAL_BOOT_COUNTS_STRING = "INDIVIDUAL_BOOT_COUNTS"; const char *INDIVIDUAL_BOOT_COUNTS_STRING = "INDIVIDUAL_BOOT_COUNTS";
const char *I2C_UNAVAILABLE_REBOOT_STRING = "I2C_UNAVAILABLE_REBOOT"; const char *TRYING_I2C_RECOVERY_STRING = "TRYING_I2C_RECOVERY";
const char *I2C_REBOOT_STRING = "I2C_REBOOT";
const char *NO_VALID_SENSOR_TEMPERATURE_STRING = "NO_VALID_SENSOR_TEMPERATURE"; const char *NO_VALID_SENSOR_TEMPERATURE_STRING = "NO_VALID_SENSOR_TEMPERATURE";
const char *NO_HEALTHY_HEATER_AVAILABLE_STRING = "NO_HEALTHY_HEATER_AVAILABLE"; const char *NO_HEALTHY_HEATER_AVAILABLE_STRING = "NO_HEALTHY_HEATER_AVAILABLE";
const char *SYRLINKS_OVERHEATING_STRING = "SYRLINKS_OVERHEATING"; const char *SYRLINKS_OVERHEATING_STRING = "SYRLINKS_OVERHEATING";
@ -815,7 +816,9 @@ const char *translateEvents(Event event) {
case (14008): case (14008):
return INDIVIDUAL_BOOT_COUNTS_STRING; return INDIVIDUAL_BOOT_COUNTS_STRING;
case (14010): case (14010):
return I2C_UNAVAILABLE_REBOOT_STRING; return TRYING_I2C_RECOVERY_STRING;
case (14011):
return I2C_REBOOT_STRING;
case (14100): case (14100):
return NO_VALID_SENSOR_TEMPERATURE_STRING; return NO_VALID_SENSOR_TEMPERATURE_STRING;
case (14101): case (14101):

View File

@ -2,7 +2,7 @@
* @brief Auto-generated object translation file. * @brief Auto-generated object translation file.
* @details * @details
* Contains 171 translations. * Contains 171 translations.
* Generated on: 2023-04-04 13:59:07 * Generated on: 2023-04-07 11:06:14
*/ */
#include "translateObjects.h" #include "translateObjects.h"

View File

@ -9,6 +9,7 @@
#include "fsfw/serviceinterface/ServiceInterface.h" #include "fsfw/serviceinterface/ServiceInterface.h"
#include "fsfw/timemanager/Stopwatch.h" #include "fsfw/timemanager/Stopwatch.h"
#include "fsfw/version.h" #include "fsfw/version.h"
#include "mission/sysDefs.h"
#include "watchdog/definitions.h" #include "watchdog/definitions.h"
#if OBSW_ADD_TMTC_UDP_SERVER == 1 #if OBSW_ADD_TMTC_UDP_SERVER == 1
#include "fsfw/osal/common/UdpTmTcBridge.h" #include "fsfw/osal/common/UdpTmTcBridge.h"
@ -31,8 +32,7 @@
xsc::Chip CoreController::CURRENT_CHIP = xsc::Chip::NO_CHIP; xsc::Chip CoreController::CURRENT_CHIP = xsc::Chip::NO_CHIP;
xsc::Copy CoreController::CURRENT_COPY = xsc::Copy::NO_COPY; xsc::Copy CoreController::CURRENT_COPY = xsc::Copy::NO_COPY;
CoreController::CoreController(object_id_t objectId, const std::atomic_uint16_t &i2cErrors, CoreController::CoreController(object_id_t objectId, bool enableHkSet)
bool enableHkSet)
: ExtendedControllerBase(objectId, 5), : ExtendedControllerBase(objectId, 5),
enableHkSet(enableHkSet), enableHkSet(enableHkSet),
cmdExecutor(4096), cmdExecutor(4096),
@ -40,8 +40,7 @@ CoreController::CoreController(object_id_t objectId, const std::atomic_uint16_t
cmdRepliesSizes(128), cmdRepliesSizes(128),
opDivider5(5), opDivider5(5),
opDivider10(10), opDivider10(10),
hkSet(this), hkSet(this) {
i2cErrors(i2cErrors) {
cmdExecutor.setRingBuffer(&cmdReplyBuf, &cmdRepliesSizes); cmdExecutor.setRingBuffer(&cmdReplyBuf, &cmdRepliesSizes);
try { try {
sdcMan = SdCardManager::instance(); sdcMan = SdCardManager::instance();
@ -110,17 +109,12 @@ void CoreController::performControlOperation() {
sdStateMachine(); sdStateMachine();
performMountedSdCardOperations(); performMountedSdCardOperations();
readHkData(); readHkData();
if (i2cErrors >= 5) {
bool protOpPerformed = false;
triggerEvent(I2C_UNAVAILABLE_REBOOT);
gracefulShutdownTasks(CURRENT_CHIP, CURRENT_COPY, protOpPerformed);
std::system("xsc_boot_copy -r");
}
if (shellCmdIsExecuting) { if (shellCmdIsExecuting) {
bool replyReceived = false; bool replyReceived = false;
// TODO: We could read the data in the ring buffer and send it as an action data reply. // TODO: We could read the data in the ring buffer and send it as an action data reply.
if (cmdExecutor.check(replyReceived) == CommandExecutor::EXECUTION_FINISHED) { if (cmdExecutor.check(replyReceived) == CommandExecutor::EXECUTION_FINISHED) {
actionHelper.finish(true, successRecipient, EXECUTE_SHELL_CMD); actionHelper.finish(true, successRecipient, core::EXECUTE_SHELL_CMD);
shellCmdIsExecuting = false; shellCmdIsExecuting = false;
cmdReplyBuf.clear(); cmdReplyBuf.clear();
while (not cmdRepliesSizes.empty()) { while (not cmdRepliesSizes.empty()) {
@ -163,7 +157,7 @@ ReturnValue_t CoreController::initialize() {
sdStateMachine(); sdStateMachine();
triggerEvent(REBOOT_SW, CURRENT_CHIP, CURRENT_COPY); triggerEvent(core::REBOOT_SW, CURRENT_CHIP, CURRENT_COPY);
EventManagerIF *eventManager = EventManagerIF *eventManager =
ObjectManager::instance()->get<EventManagerIF>(objects::EVENT_MANAGER); ObjectManager::instance()->get<EventManagerIF>(objects::EVENT_MANAGER);
if (eventManager == nullptr or eventQueue == nullptr) { if (eventManager == nullptr or eventQueue == nullptr) {
@ -202,6 +196,7 @@ ReturnValue_t CoreController::initializeAfterTaskCreation() {
ReturnValue_t CoreController::executeAction(ActionId_t actionId, MessageQueueId_t commandedBy, ReturnValue_t CoreController::executeAction(ActionId_t actionId, MessageQueueId_t commandedBy,
const uint8_t *data, size_t size) { const uint8_t *data, size_t size) {
using namespace core;
switch (actionId) { switch (actionId) {
case (ANNOUNCE_VERSION): { case (ANNOUNCE_VERSION): {
uint32_t p1 = (common::OBSW_VERSION_MAJOR << 24) | (common::OBSW_VERSION_MINOR << 16) | uint32_t p1 = (common::OBSW_VERSION_MAJOR << 24) | (common::OBSW_VERSION_MINOR << 16) |
@ -1324,7 +1319,7 @@ ReturnValue_t CoreController::performSdCardCheck() {
someSdCardActive = true; someSdCardActive = true;
} }
if (not someSdCardActive and remountAttemptFlag) { if (not someSdCardActive and remountAttemptFlag) {
triggerEvent(NO_SD_CARD_ACTIVE); triggerEvent(core::NO_SD_CARD_ACTIVE);
initSdCardBlocking(); initSdCardBlocking();
remountAttemptFlag = false; remountAttemptFlag = false;
} }
@ -1378,7 +1373,7 @@ void CoreController::performRebootFileHandling(bool recreateFile) {
if (rebootFile.bootFlag) { if (rebootFile.bootFlag) {
// Trigger event to inform ground that a reboot was triggered // Trigger event to inform ground that a reboot was triggered
uint32_t p1 = rebootFile.lastChip << 16 | rebootFile.lastCopy; uint32_t p1 = rebootFile.lastChip << 16 | rebootFile.lastCopy;
triggerEvent(REBOOT_MECHANISM_TRIGGERED, p1, 0); triggerEvent(core::REBOOT_MECHANISM_TRIGGERED, p1, 0);
// Clear the boot flag // Clear the boot flag
rebootFile.bootFlag = false; rebootFile.bootFlag = false;
} }
@ -2047,8 +2042,9 @@ void CoreController::announceBootCounts() {
rebootFile.img00Cnt + rebootFile.img01Cnt + rebootFile.img10Cnt + rebootFile.img11Cnt; rebootFile.img00Cnt + rebootFile.img01Cnt + rebootFile.img10Cnt + rebootFile.img11Cnt;
uint32_t individualBootCountsP1 = (rebootFile.img00Cnt << 16) | rebootFile.img01Cnt; uint32_t individualBootCountsP1 = (rebootFile.img00Cnt << 16) | rebootFile.img01Cnt;
uint32_t individualBootCountsP2 = (rebootFile.img10Cnt << 16) | rebootFile.img11Cnt; uint32_t individualBootCountsP2 = (rebootFile.img10Cnt << 16) | rebootFile.img11Cnt;
triggerEvent(INDIVIDUAL_BOOT_COUNTS, individualBootCountsP1, individualBootCountsP2); triggerEvent(core::INDIVIDUAL_BOOT_COUNTS, individualBootCountsP1, individualBootCountsP2);
triggerEvent(REBOOT_COUNTER, (totalBootCount >> 32) & 0xffffffff, totalBootCount & 0xffffffff); triggerEvent(core::REBOOT_COUNTER, (totalBootCount >> 32) & 0xffffffff,
totalBootCount & 0xffffffff);
} }
bool CoreController::isNumber(const std::string &s) { bool CoreController::isNumber(const std::string &s) {

View File

@ -78,64 +78,7 @@ class CoreController : public ExtendedControllerBase {
static constexpr dur_millis_t INIT_SD_CARD_CHECK_TIMEOUT = 5000; static constexpr dur_millis_t INIT_SD_CARD_CHECK_TIMEOUT = 5000;
static constexpr dur_millis_t DEFAULT_SD_CARD_CHECK_TIMEOUT = 60000; static constexpr dur_millis_t DEFAULT_SD_CARD_CHECK_TIMEOUT = 60000;
static constexpr ActionId_t LIST_DIRECTORY_INTO_FILE = 0; CoreController(object_id_t objectId, bool enableHkSet);
static constexpr ActionId_t ANNOUNCE_VERSION = 1;
static constexpr ActionId_t ANNOUNCE_CURRENT_IMAGE = 2;
static constexpr ActionId_t ANNOUNCE_BOOT_COUNTS = 3;
static constexpr ActionId_t SWITCH_REBOOT_FILE_HANDLING = 5;
static constexpr ActionId_t RESET_REBOOT_COUNTERS = 6;
static constexpr ActionId_t SWITCH_IMG_LOCK = 7;
static constexpr ActionId_t SET_MAX_REBOOT_CNT = 8;
static constexpr ActionId_t OBSW_UPDATE_FROM_SD_0 = 10;
static constexpr ActionId_t OBSW_UPDATE_FROM_SD_1 = 11;
static constexpr ActionId_t OBSW_UPDATE_FROM_TMP = 12;
static constexpr ActionId_t SWITCH_TO_SD_0 = 16;
static constexpr ActionId_t SWITCH_TO_SD_1 = 17;
static constexpr ActionId_t SWITCH_TO_BOTH_SD_CARDS = 18;
//! Reboot using the xsc_boot_copy command
static constexpr ActionId_t XSC_REBOOT_OBC = 32;
static constexpr ActionId_t MOUNT_OTHER_COPY = 33;
//! Reboot using the reboot command
static constexpr ActionId_t REBOOT_OBC = 34;
static constexpr ActionId_t EXECUTE_SHELL_CMD = 40;
static constexpr uint8_t SUBSYSTEM_ID = SUBSYSTEM_ID::CORE;
static constexpr Event ALLOC_FAILURE = event::makeEvent(SUBSYSTEM_ID, 0, severity::MEDIUM);
//! [EXPORT] : [COMMENT] Software reboot occurred. Can also be a systemd reboot.
//! P1: Current Chip, P2: Current Copy
static constexpr Event REBOOT_SW = event::makeEvent(SUBSYSTEM_ID, 1, severity::LOW);
//! [EXPORT] : [COMMENT] The reboot mechanism was triggered.
//! P1: First 16 bits: Last Chip, Last 16 bits: Last Copy,
//! P2: Each byte is the respective reboot count for the slots
static constexpr Event REBOOT_MECHANISM_TRIGGERED =
event::makeEvent(SUBSYSTEM_ID, 2, severity::MEDIUM);
//! Trying to find a way how to determine that the reboot came from ProASIC3 or PCDU..
static constexpr Event REBOOT_HW = event::makeEvent(SUBSYSTEM_ID, 3, severity::MEDIUM);
//! [EXPORT] : [COMMENT] No SD card was active. Core controller will attempt to re-initialize
//! a SD card.
static constexpr Event NO_SD_CARD_ACTIVE = event::makeEvent(SUBSYSTEM_ID, 4, severity::HIGH);
//! [EXPORT] : [COMMENT]
//! P1: Byte 0: Major, Byte 1: Minor, Byte 2: Patch, Byte 3: Has Git Hash
//! P2: First four letters of Git SHA is the last byte of P1 is set.
static constexpr Event VERSION_INFO = event::makeEvent(SUBSYSTEM_ID, 5, severity::INFO);
//! [EXPORT] : [COMMENT] P1: Current Chip, P2: Current Copy
static constexpr Event CURRENT_IMAGE_INFO = event::makeEvent(SUBSYSTEM_ID, 6, severity::INFO);
//! [EXPORT] : [COMMENT] Total reboot counter, which is the sum of the boot count of all
//! individual images.
static constexpr Event REBOOT_COUNTER = event::makeEvent(SUBSYSTEM_ID, 7, severity::INFO);
//! [EXPORT] : [COMMENT] Get the boot count of the individual images.
//! P1: First 16 bits boot count of image 0 0, last 16 bits boot count of image 0 1.
//! P2: First 16 bits boot count of image 1 0, last 16 bits boot count of image 1 1.
static constexpr Event INDIVIDUAL_BOOT_COUNTS = event::makeEvent(SUBSYSTEM_ID, 8, severity::INFO);
static constexpr Event I2C_UNAVAILABLE_REBOOT =
event::makeEvent(SUBSYSTEM_ID, 10, severity::MEDIUM);
CoreController(object_id_t objectId, const std::atomic_uint16_t& i2cErrors, bool enableHkSet);
virtual ~CoreController(); virtual ~CoreController();
ReturnValue_t initialize() override; ReturnValue_t initialize() override;
@ -266,7 +209,6 @@ class CoreController : public ExtendedControllerBase {
PoolEntry<float> plVoltageEntry = PoolEntry<float>(0.0); PoolEntry<float> plVoltageEntry = PoolEntry<float>(0.0);
core::HkSet hkSet; core::HkSet hkSet;
const std::atomic_uint16_t& i2cErrors;
#if OBSW_SD_CARD_MUST_BE_ON == 1 #if OBSW_SD_CARD_MUST_BE_ON == 1
bool remountAttemptFlag = true; bool remountAttemptFlag = true;

View File

@ -23,7 +23,6 @@ class HealthTableIF;
class AcsBoardAssembly; class AcsBoardAssembly;
class GpioIF; class GpioIF;
extern std::atomic_uint16_t I2C_FATAL_ERRORS;
extern std::atomic_bool PTME_LOCKED; extern std::atomic_bool PTME_LOCKED;
namespace ObjectFactory { namespace ObjectFactory {

View File

@ -5,7 +5,7 @@
#include <fsfw/power/DummyPowerSwitcher.h> #include <fsfw/power/DummyPowerSwitcher.h>
#include <fsfw_hal/common/gpio/GpioCookie.h> #include <fsfw_hal/common/gpio/GpioCookie.h>
#include <mission/power/gsDefs.h> #include <mission/power/gsDefs.h>
#include <mission/system/tree/system.h> #include <mission/system/systemTree.h>
#include <mission/utility/DummySdCardManager.h> #include <mission/utility/DummySdCardManager.h>
#include "OBSWConfig.h" #include "OBSWConfig.h"
@ -71,7 +71,7 @@ void ObjectFactory::produce(void* args) {
dummy::createDummies(dummyCfg, *pwrSwitcher, gpioComIF); dummy::createDummies(dummyCfg, *pwrSwitcher, gpioComIF);
new CoreController(objects::CORE_CONTROLLER, I2C_FATAL_ERRORS, enableHkSets); new CoreController(objects::CORE_CONTROLLER, enableHkSets);
// Regular FM code, does not work for EM if the hardware is not connected // Regular FM code, does not work for EM if the hardware is not connected
// createPcduComponents(gpioComIF, &pwrSwitcher); // createPcduComponents(gpioComIF, &pwrSwitcher);

View File

@ -2,6 +2,7 @@
#include <fsfw/storagemanager/LocalPool.h> #include <fsfw/storagemanager/LocalPool.h>
#include <fsfw/storagemanager/PoolManager.h> #include <fsfw/storagemanager/PoolManager.h>
#include <mission/power/gsDefs.h> #include <mission/power/gsDefs.h>
#include <mission/system/EiveSystem.h>
#include "OBSWConfig.h" #include "OBSWConfig.h"
#include "bsp_q7s/core/CoreController.h" #include "bsp_q7s/core/CoreController.h"
@ -13,7 +14,7 @@
#include "linux/ObjectFactory.h" #include "linux/ObjectFactory.h"
#include "linux/callbacks/gpioCallbacks.h" #include "linux/callbacks/gpioCallbacks.h"
#include "mission/genericFactory.h" #include "mission/genericFactory.h"
#include "mission/system/tree/system.h" #include "mission/system/systemTree.h"
#include "mission/tmtc/tmFilters.h" #include "mission/tmtc/tmFilters.h"
void ObjectFactory::produce(void* args) { void ObjectFactory::produce(void* args) {
@ -43,8 +44,10 @@ void ObjectFactory::produce(void* args) {
q7s::gpioCallbacks::initSpiCsDecoder(gpioComIF); q7s::gpioCallbacks::initSpiCsDecoder(gpioComIF);
gpioCallbacks::disableAllDecoder(gpioComIF); gpioCallbacks::disableAllDecoder(gpioComIF);
new CoreController(objects::CORE_CONTROLLER, I2C_FATAL_ERRORS, enableHkSets); new CoreController(objects::CORE_CONTROLLER, enableHkSets);
createPcduComponents(gpioComIF, &pwrSwitcher, enableHkSets); createPcduComponents(gpioComIF, &pwrSwitcher, enableHkSets);
satsystem::EIVE_SYSTEM.setI2cRecoveryParams(pwrSwitcher);
auto* stackHandler = new Stack5VHandler(*pwrSwitcher); auto* stackHandler = new Stack5VHandler(*pwrSwitcher);
#if OBSW_ADD_RAD_SENSORS == 1 #if OBSW_ADD_RAD_SENSORS == 1

View File

@ -16,7 +16,7 @@
#include "fsfw/version.h" #include "fsfw/version.h"
#include "mission/acs/defs.h" #include "mission/acs/defs.h"
#include "mission/com/defs.h" #include "mission/com/defs.h"
#include "mission/system/tree/system.h" #include "mission/system/systemTree.h"
#include "q7sConfig.h" #include "q7sConfig.h"
#include "watchdog/definitions.h" #include "watchdog/definitions.h"

View File

@ -37,19 +37,19 @@ uint32_t BpxDummy::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo) { return
ReturnValue_t BpxDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap, ReturnValue_t BpxDummy::initializeLocalDataPool(localpool::DataPool &localDataPoolMap,
LocalDataPoolManager &poolManager) { LocalDataPoolManager &poolManager) {
localDataPoolMap.emplace(BpxBattery::BATT_TEMP_1, &battTemp1); localDataPoolMap.emplace(bpxBat::BATT_TEMP_1, &battTemp1);
localDataPoolMap.emplace(BpxBattery::BATT_TEMP_2, &battTemp2); localDataPoolMap.emplace(bpxBat::BATT_TEMP_2, &battTemp2);
localDataPoolMap.emplace(BpxBattery::BATT_TEMP_3, &battTemp3); localDataPoolMap.emplace(bpxBat::BATT_TEMP_3, &battTemp3);
localDataPoolMap.emplace(BpxBattery::BATT_TEMP_4, &battTemp4); localDataPoolMap.emplace(bpxBat::BATT_TEMP_4, &battTemp4);
localDataPoolMap.emplace(BpxBattery::CHARGE_CURRENT, &chargeCurrent); localDataPoolMap.emplace(bpxBat::CHARGE_CURRENT, &chargeCurrent);
localDataPoolMap.emplace(BpxBattery::DISCHARGE_CURRENT, &dischargeCurrent); localDataPoolMap.emplace(bpxBat::DISCHARGE_CURRENT, &dischargeCurrent);
localDataPoolMap.emplace(BpxBattery::HEATER_CURRENT, &heaterCurrent); localDataPoolMap.emplace(bpxBat::HEATER_CURRENT, &heaterCurrent);
localDataPoolMap.emplace(BpxBattery::BATT_VOLTAGE, &battVolt); localDataPoolMap.emplace(bpxBat::BATT_VOLTAGE, &battVolt);
localDataPoolMap.emplace(BpxBattery::REBOOT_COUNTER, &rebootCounter); localDataPoolMap.emplace(bpxBat::REBOOT_COUNTER, &rebootCounter);
localDataPoolMap.emplace(BpxBattery::BOOTCAUSE, &bootCause); localDataPoolMap.emplace(bpxBat::BOOTCAUSE, &bootCause);
localDataPoolMap.emplace(BpxBattery::BATTERY_HEATER_MODE, &battheatMode); localDataPoolMap.emplace(bpxBat::BATTERY_HEATER_MODE, &battheatMode);
localDataPoolMap.emplace(BpxBattery::BATTHEAT_LOW_LIMIT, &battheatLow); localDataPoolMap.emplace(bpxBat::BATTHEAT_LOW_LIMIT, &battheatLow);
localDataPoolMap.emplace(BpxBattery::BATTHEAT_HIGH_LIMIT, &battheatHigh); localDataPoolMap.emplace(bpxBat::BATTHEAT_HIGH_LIMIT, &battheatHigh);
return returnvalue::OK; return returnvalue::OK;
} }

2
fsfw

@ -1 +1 @@
Subproject commit 6650c293da09d8851c2bd6c4d6e6c5a8390d003e Subproject commit e97fa5ac84db7ab5c10a31c2c78b26057cfacb71

View File

@ -101,8 +101,8 @@ Event ID (dec); Event ID (hex); Name; Severity; Description; File Path
11401;0x2c89;GPIO_PULL_LOW_FAILED;LOW;No description;mission/tcs/HeaterHandler.h 11401;0x2c89;GPIO_PULL_LOW_FAILED;LOW;No description;mission/tcs/HeaterHandler.h
11402;0x2c8a;HEATER_WENT_ON;INFO;No description;mission/tcs/HeaterHandler.h 11402;0x2c8a;HEATER_WENT_ON;INFO;No description;mission/tcs/HeaterHandler.h
11403;0x2c8b;HEATER_WENT_OFF;INFO;No description;mission/tcs/HeaterHandler.h 11403;0x2c8b;HEATER_WENT_OFF;INFO;No description;mission/tcs/HeaterHandler.h
11404;0x2c8c;SWITCH_ALREADY_ON;LOW;No description;mission/tcs/HeaterHandler.h 11404;0x2c8c;SWITCH_ALREADY_ON;INFO;No description;mission/tcs/HeaterHandler.h
11405;0x2c8d;SWITCH_ALREADY_OFF;LOW;No description;mission/tcs/HeaterHandler.h 11405;0x2c8d;SWITCH_ALREADY_OFF;INFO;No description;mission/tcs/HeaterHandler.h
11406;0x2c8e;MAIN_SWITCH_TIMEOUT;MEDIUM;No description;mission/tcs/HeaterHandler.h 11406;0x2c8e;MAIN_SWITCH_TIMEOUT;MEDIUM;No description;mission/tcs/HeaterHandler.h
11407;0x2c8f;FAULTY_HEATER_WAS_ON;LOW;No description;mission/tcs/HeaterHandler.h 11407;0x2c8f;FAULTY_HEATER_WAS_ON;LOW;No description;mission/tcs/HeaterHandler.h
11500;0x2cec;BURN_PHASE_START;INFO;P1: Burn duration in milliseconds, P2: Dry run flag;mission/SolarArrayDeploymentHandler.h 11500;0x2cec;BURN_PHASE_START;INFO;P1: Burn duration in milliseconds, P2: Dry run flag;mission/SolarArrayDeploymentHandler.h
@ -251,16 +251,17 @@ Event ID (dec); Event ID (hex); Name; Severity; Description; File Path
13903;0x364f;INSERT_CONFIGFILEVALUE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h 13903;0x364f;INSERT_CONFIGFILEVALUE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h
13904;0x3650;WRITE_CONFIGFILE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h 13904;0x3650;WRITE_CONFIGFILE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h
13905;0x3651;READ_CONFIGFILE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h 13905;0x3651;READ_CONFIGFILE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h
14000;0x36b0;ALLOC_FAILURE;MEDIUM;No description;bsp_q7s/core/CoreController.h 14000;0x36b0;ALLOC_FAILURE;MEDIUM;No description;mission/sysDefs.h
14001;0x36b1;REBOOT_SW;LOW; Software reboot occurred. Can also be a systemd reboot. P1: Current Chip, P2: Current Copy;bsp_q7s/core/CoreController.h 14001;0x36b1;REBOOT_SW;LOW; Software reboot occurred. Can also be a systemd reboot. P1: Current Chip, P2: Current Copy;mission/sysDefs.h
14002;0x36b2;REBOOT_MECHANISM_TRIGGERED;MEDIUM;The reboot mechanism was triggered. P1: First 16 bits: Last Chip, Last 16 bits: Last Copy, P2: Each byte is the respective reboot count for the slots;bsp_q7s/core/CoreController.h 14002;0x36b2;REBOOT_MECHANISM_TRIGGERED;MEDIUM;The reboot mechanism was triggered. P1: First 16 bits: Last Chip, Last 16 bits: Last Copy, P2: Each byte is the respective reboot count for the slots;mission/sysDefs.h
14003;0x36b3;REBOOT_HW;MEDIUM;No description;bsp_q7s/core/CoreController.h 14003;0x36b3;REBOOT_HW;MEDIUM;No description;mission/sysDefs.h
14004;0x36b4;NO_SD_CARD_ACTIVE;HIGH;No SD card was active. Core controller will attempt to re-initialize a SD card.;bsp_q7s/core/CoreController.h 14004;0x36b4;NO_SD_CARD_ACTIVE;HIGH;No SD card was active. Core controller will attempt to re-initialize a SD card.;mission/sysDefs.h
14005;0x36b5;VERSION_INFO;INFO;P1: Byte 0: Major, Byte 1: Minor, Byte 2: Patch, Byte 3: Has Git Hash P2: First four letters of Git SHA is the last byte of P1 is set.;bsp_q7s/core/CoreController.h 14005;0x36b5;VERSION_INFO;INFO;P1: Byte 0: Major, Byte 1: Minor, Byte 2: Patch, Byte 3: Has Git Hash P2: First four letters of Git SHA is the last byte of P1 is set.;mission/sysDefs.h
14006;0x36b6;CURRENT_IMAGE_INFO;INFO;P1: Current Chip, P2: Current Copy;bsp_q7s/core/CoreController.h 14006;0x36b6;CURRENT_IMAGE_INFO;INFO;P1: Current Chip, P2: Current Copy;mission/sysDefs.h
14007;0x36b7;REBOOT_COUNTER;INFO;Total reboot counter, which is the sum of the boot count of all individual images.;bsp_q7s/core/CoreController.h 14007;0x36b7;REBOOT_COUNTER;INFO;Total reboot counter, which is the sum of the boot count of all individual images.;mission/sysDefs.h
14008;0x36b8;INDIVIDUAL_BOOT_COUNTS;INFO;Get the boot count of the individual images. P1: First 16 bits boot count of image 0 0, last 16 bits boot count of image 0 1. P2: First 16 bits boot count of image 1 0, last 16 bits boot count of image 1 1.;bsp_q7s/core/CoreController.h 14008;0x36b8;INDIVIDUAL_BOOT_COUNTS;INFO;Get the boot count of the individual images. P1: First 16 bits boot count of image 0 0, last 16 bits boot count of image 0 1. P2: First 16 bits boot count of image 1 0, last 16 bits boot count of image 1 1.;mission/sysDefs.h
14010;0x36ba;I2C_UNAVAILABLE_REBOOT;MEDIUM;No description;bsp_q7s/core/CoreController.h 14010;0x36ba;TRYING_I2C_RECOVERY;MEDIUM;I2C is unavailable. Trying recovery of I2C bus by power cycling all I2C devices.;mission/sysDefs.h
14011;0x36bb;I2C_REBOOT;MEDIUM;I2C is unavailable. Recovery did not work, performing full reboot.;mission/sysDefs.h
14100;0x3714;NO_VALID_SENSOR_TEMPERATURE;MEDIUM;No description;mission/controller/tcsDefs.h 14100;0x3714;NO_VALID_SENSOR_TEMPERATURE;MEDIUM;No description;mission/controller/tcsDefs.h
14101;0x3715;NO_HEALTHY_HEATER_AVAILABLE;MEDIUM;No description;mission/controller/tcsDefs.h 14101;0x3715;NO_HEALTHY_HEATER_AVAILABLE;MEDIUM;No description;mission/controller/tcsDefs.h
14102;0x3716;SYRLINKS_OVERHEATING;HIGH;No description;mission/controller/tcsDefs.h 14102;0x3716;SYRLINKS_OVERHEATING;HIGH;No description;mission/controller/tcsDefs.h

1 Event ID (dec) Event ID (hex) Name Severity Description File Path
101 11401 0x2c89 GPIO_PULL_LOW_FAILED LOW No description mission/tcs/HeaterHandler.h
102 11402 0x2c8a HEATER_WENT_ON INFO No description mission/tcs/HeaterHandler.h
103 11403 0x2c8b HEATER_WENT_OFF INFO No description mission/tcs/HeaterHandler.h
104 11404 0x2c8c SWITCH_ALREADY_ON LOW INFO No description mission/tcs/HeaterHandler.h
105 11405 0x2c8d SWITCH_ALREADY_OFF LOW INFO No description mission/tcs/HeaterHandler.h
106 11406 0x2c8e MAIN_SWITCH_TIMEOUT MEDIUM No description mission/tcs/HeaterHandler.h
107 11407 0x2c8f FAULTY_HEATER_WAS_ON LOW No description mission/tcs/HeaterHandler.h
108 11500 0x2cec BURN_PHASE_START INFO P1: Burn duration in milliseconds, P2: Dry run flag mission/SolarArrayDeploymentHandler.h
251 13903 0x364f INSERT_CONFIGFILEVALUE_FAILED MEDIUM No description mission/utility/GlobalConfigHandler.h
252 13904 0x3650 WRITE_CONFIGFILE_FAILED MEDIUM No description mission/utility/GlobalConfigHandler.h
253 13905 0x3651 READ_CONFIGFILE_FAILED MEDIUM No description mission/utility/GlobalConfigHandler.h
254 14000 0x36b0 ALLOC_FAILURE MEDIUM No description bsp_q7s/core/CoreController.h mission/sysDefs.h
255 14001 0x36b1 REBOOT_SW LOW Software reboot occurred. Can also be a systemd reboot. P1: Current Chip, P2: Current Copy bsp_q7s/core/CoreController.h mission/sysDefs.h
256 14002 0x36b2 REBOOT_MECHANISM_TRIGGERED MEDIUM The reboot mechanism was triggered. P1: First 16 bits: Last Chip, Last 16 bits: Last Copy, P2: Each byte is the respective reboot count for the slots bsp_q7s/core/CoreController.h mission/sysDefs.h
257 14003 0x36b3 REBOOT_HW MEDIUM No description bsp_q7s/core/CoreController.h mission/sysDefs.h
258 14004 0x36b4 NO_SD_CARD_ACTIVE HIGH No SD card was active. Core controller will attempt to re-initialize a SD card. bsp_q7s/core/CoreController.h mission/sysDefs.h
259 14005 0x36b5 VERSION_INFO INFO P1: Byte 0: Major, Byte 1: Minor, Byte 2: Patch, Byte 3: Has Git Hash P2: First four letters of Git SHA is the last byte of P1 is set. bsp_q7s/core/CoreController.h mission/sysDefs.h
260 14006 0x36b6 CURRENT_IMAGE_INFO INFO P1: Current Chip, P2: Current Copy bsp_q7s/core/CoreController.h mission/sysDefs.h
261 14007 0x36b7 REBOOT_COUNTER INFO Total reboot counter, which is the sum of the boot count of all individual images. bsp_q7s/core/CoreController.h mission/sysDefs.h
262 14008 0x36b8 INDIVIDUAL_BOOT_COUNTS INFO Get the boot count of the individual images. P1: First 16 bits boot count of image 0 0, last 16 bits boot count of image 0 1. P2: First 16 bits boot count of image 1 0, last 16 bits boot count of image 1 1. bsp_q7s/core/CoreController.h mission/sysDefs.h
263 14010 0x36ba I2C_UNAVAILABLE_REBOOT TRYING_I2C_RECOVERY MEDIUM No description I2C is unavailable. Trying recovery of I2C bus by power cycling all I2C devices. bsp_q7s/core/CoreController.h mission/sysDefs.h
264 14011 0x36bb I2C_REBOOT MEDIUM I2C is unavailable. Recovery did not work, performing full reboot. mission/sysDefs.h
265 14100 0x3714 NO_VALID_SENSOR_TEMPERATURE MEDIUM No description mission/controller/tcsDefs.h
266 14101 0x3715 NO_HEALTHY_HEATER_AVAILABLE MEDIUM No description mission/controller/tcsDefs.h
267 14102 0x3716 SYRLINKS_OVERHEATING HIGH No description mission/controller/tcsDefs.h

View File

@ -371,8 +371,8 @@ Full ID (hex); Name; Description; Unique ID; Subsytem Name; File Path
0x3e03;HKM_PeriodicHelperInvalid;No description;3;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h 0x3e03;HKM_PeriodicHelperInvalid;No description;3;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
0x3e04;HKM_PoolobjectNotFound;No description;4;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h 0x3e04;HKM_PoolobjectNotFound;No description;4;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
0x3e05;HKM_DatasetNotFound;No description;5;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h 0x3e05;HKM_DatasetNotFound;No description;5;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
0x3f01;DLEE_NoPacketFound;No description;1;DLE_ENCODER;fsfw/src/fsfw/globalfunctions/DleParser.h 0x3f01;DLEE_StreamTooShort;No description;1;DLE_ENCODER;fsfw/src/fsfw/globalfunctions/DleEncoder.h
0x3f02;DLEE_PossiblePacketLoss;No description;2;DLE_ENCODER;fsfw/src/fsfw/globalfunctions/DleParser.h 0x3f02;DLEE_DecodingError;No description;2;DLE_ENCODER;fsfw/src/fsfw/globalfunctions/DleEncoder.h
0x4201;PUS11_InvalidTypeTimeWindow;No description;1;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h 0x4201;PUS11_InvalidTypeTimeWindow;No description;1;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
0x4202;PUS11_InvalidTimeWindow;No description;2;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h 0x4202;PUS11_InvalidTimeWindow;No description;2;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
0x4203;PUS11_TimeshiftingNotPossible;No description;3;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h 0x4203;PUS11_TimeshiftingNotPossible;No description;3;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
@ -402,9 +402,9 @@ Full ID (hex); Name; Description; Unique ID; Subsytem Name; File Path
0x4403;UXOS_CommandError;Command execution failed;3;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h 0x4403;UXOS_CommandError;Command execution failed;3;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h
0x4404;UXOS_NoCommandLoadedOrPending;;4;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h 0x4404;UXOS_NoCommandLoadedOrPending;;4;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h
0x4406;UXOS_PcloseCallError;No description;6;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h 0x4406;UXOS_PcloseCallError;No description;6;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h
0x4500;HSPI_OpeningFileFailed;No description;0;HAL_SPI;fsfw/src/fsfw_hal/linux/spi/SpiComIF.h 0x4500;HSPI_HalTimeoutRetval;No description;0;HAL_SPI;fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
0x4501;HSPI_FullDuplexTransferFailed;No description;1;HAL_SPI;fsfw/src/fsfw_hal/linux/spi/SpiComIF.h 0x4501;HSPI_HalBusyRetval;No description;1;HAL_SPI;fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
0x4502;HSPI_HalfDuplexTransferFailed;No description;2;HAL_SPI;fsfw/src/fsfw_hal/linux/spi/SpiComIF.h 0x4502;HSPI_HalErrorRetval;No description;2;HAL_SPI;fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
0x4601;HURT_UartReadFailure;No description;1;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h 0x4601;HURT_UartReadFailure;No description;1;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h
0x4602;HURT_UartReadSizeMissmatch;No description;2;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h 0x4602;HURT_UartReadSizeMissmatch;No description;2;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h
0x4603;HURT_UartRxBufferTooSmall;No description;3;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h 0x4603;HURT_UartRxBufferTooSmall;No description;3;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h

1 Full ID (hex) Name Description Unique ID Subsytem Name File Path
371 0x3e03 HKM_PeriodicHelperInvalid No description 3 HOUSEKEEPING_MANAGER fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
372 0x3e04 HKM_PoolobjectNotFound No description 4 HOUSEKEEPING_MANAGER fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
373 0x3e05 HKM_DatasetNotFound No description 5 HOUSEKEEPING_MANAGER fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
374 0x3f01 DLEE_NoPacketFound DLEE_StreamTooShort No description 1 DLE_ENCODER fsfw/src/fsfw/globalfunctions/DleParser.h fsfw/src/fsfw/globalfunctions/DleEncoder.h
375 0x3f02 DLEE_PossiblePacketLoss DLEE_DecodingError No description 2 DLE_ENCODER fsfw/src/fsfw/globalfunctions/DleParser.h fsfw/src/fsfw/globalfunctions/DleEncoder.h
376 0x4201 PUS11_InvalidTypeTimeWindow No description 1 PUS_SERVICE_11 fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
377 0x4202 PUS11_InvalidTimeWindow No description 2 PUS_SERVICE_11 fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
378 0x4203 PUS11_TimeshiftingNotPossible No description 3 PUS_SERVICE_11 fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
402 0x4403 UXOS_CommandError Command execution failed 3 LINUX_OSAL fsfw/src/fsfw_hal/linux/CommandExecutor.h
403 0x4404 UXOS_NoCommandLoadedOrPending 4 LINUX_OSAL fsfw/src/fsfw_hal/linux/CommandExecutor.h
404 0x4406 UXOS_PcloseCallError No description 6 LINUX_OSAL fsfw/src/fsfw_hal/linux/CommandExecutor.h
405 0x4500 HSPI_OpeningFileFailed HSPI_HalTimeoutRetval No description 0 HAL_SPI fsfw/src/fsfw_hal/linux/spi/SpiComIF.h fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
406 0x4501 HSPI_FullDuplexTransferFailed HSPI_HalBusyRetval No description 1 HAL_SPI fsfw/src/fsfw_hal/linux/spi/SpiComIF.h fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
407 0x4502 HSPI_HalfDuplexTransferFailed HSPI_HalErrorRetval No description 2 HAL_SPI fsfw/src/fsfw_hal/linux/spi/SpiComIF.h fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
408 0x4601 HURT_UartReadFailure No description 1 HAL_UART fsfw/src/fsfw_hal/linux/serial/SerialComIF.h
409 0x4602 HURT_UartReadSizeMissmatch No description 2 HAL_UART fsfw/src/fsfw_hal/linux/serial/SerialComIF.h
410 0x4603 HURT_UartRxBufferTooSmall No description 3 HAL_UART fsfw/src/fsfw_hal/linux/serial/SerialComIF.h

View File

@ -101,8 +101,8 @@ Event ID (dec); Event ID (hex); Name; Severity; Description; File Path
11401;0x2c89;GPIO_PULL_LOW_FAILED;LOW;No description;mission/tcs/HeaterHandler.h 11401;0x2c89;GPIO_PULL_LOW_FAILED;LOW;No description;mission/tcs/HeaterHandler.h
11402;0x2c8a;HEATER_WENT_ON;INFO;No description;mission/tcs/HeaterHandler.h 11402;0x2c8a;HEATER_WENT_ON;INFO;No description;mission/tcs/HeaterHandler.h
11403;0x2c8b;HEATER_WENT_OFF;INFO;No description;mission/tcs/HeaterHandler.h 11403;0x2c8b;HEATER_WENT_OFF;INFO;No description;mission/tcs/HeaterHandler.h
11404;0x2c8c;SWITCH_ALREADY_ON;LOW;No description;mission/tcs/HeaterHandler.h 11404;0x2c8c;SWITCH_ALREADY_ON;INFO;No description;mission/tcs/HeaterHandler.h
11405;0x2c8d;SWITCH_ALREADY_OFF;LOW;No description;mission/tcs/HeaterHandler.h 11405;0x2c8d;SWITCH_ALREADY_OFF;INFO;No description;mission/tcs/HeaterHandler.h
11406;0x2c8e;MAIN_SWITCH_TIMEOUT;MEDIUM;No description;mission/tcs/HeaterHandler.h 11406;0x2c8e;MAIN_SWITCH_TIMEOUT;MEDIUM;No description;mission/tcs/HeaterHandler.h
11407;0x2c8f;FAULTY_HEATER_WAS_ON;LOW;No description;mission/tcs/HeaterHandler.h 11407;0x2c8f;FAULTY_HEATER_WAS_ON;LOW;No description;mission/tcs/HeaterHandler.h
11500;0x2cec;BURN_PHASE_START;INFO;P1: Burn duration in milliseconds, P2: Dry run flag;mission/SolarArrayDeploymentHandler.h 11500;0x2cec;BURN_PHASE_START;INFO;P1: Burn duration in milliseconds, P2: Dry run flag;mission/SolarArrayDeploymentHandler.h
@ -251,16 +251,17 @@ Event ID (dec); Event ID (hex); Name; Severity; Description; File Path
13903;0x364f;INSERT_CONFIGFILEVALUE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h 13903;0x364f;INSERT_CONFIGFILEVALUE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h
13904;0x3650;WRITE_CONFIGFILE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h 13904;0x3650;WRITE_CONFIGFILE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h
13905;0x3651;READ_CONFIGFILE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h 13905;0x3651;READ_CONFIGFILE_FAILED;MEDIUM;No description;mission/utility/GlobalConfigHandler.h
14000;0x36b0;ALLOC_FAILURE;MEDIUM;No description;bsp_q7s/core/CoreController.h 14000;0x36b0;ALLOC_FAILURE;MEDIUM;No description;mission/sysDefs.h
14001;0x36b1;REBOOT_SW;LOW; Software reboot occurred. Can also be a systemd reboot. P1: Current Chip, P2: Current Copy;bsp_q7s/core/CoreController.h 14001;0x36b1;REBOOT_SW;LOW; Software reboot occurred. Can also be a systemd reboot. P1: Current Chip, P2: Current Copy;mission/sysDefs.h
14002;0x36b2;REBOOT_MECHANISM_TRIGGERED;MEDIUM;The reboot mechanism was triggered. P1: First 16 bits: Last Chip, Last 16 bits: Last Copy, P2: Each byte is the respective reboot count for the slots;bsp_q7s/core/CoreController.h 14002;0x36b2;REBOOT_MECHANISM_TRIGGERED;MEDIUM;The reboot mechanism was triggered. P1: First 16 bits: Last Chip, Last 16 bits: Last Copy, P2: Each byte is the respective reboot count for the slots;mission/sysDefs.h
14003;0x36b3;REBOOT_HW;MEDIUM;No description;bsp_q7s/core/CoreController.h 14003;0x36b3;REBOOT_HW;MEDIUM;No description;mission/sysDefs.h
14004;0x36b4;NO_SD_CARD_ACTIVE;HIGH;No SD card was active. Core controller will attempt to re-initialize a SD card.;bsp_q7s/core/CoreController.h 14004;0x36b4;NO_SD_CARD_ACTIVE;HIGH;No SD card was active. Core controller will attempt to re-initialize a SD card.;mission/sysDefs.h
14005;0x36b5;VERSION_INFO;INFO;P1: Byte 0: Major, Byte 1: Minor, Byte 2: Patch, Byte 3: Has Git Hash P2: First four letters of Git SHA is the last byte of P1 is set.;bsp_q7s/core/CoreController.h 14005;0x36b5;VERSION_INFO;INFO;P1: Byte 0: Major, Byte 1: Minor, Byte 2: Patch, Byte 3: Has Git Hash P2: First four letters of Git SHA is the last byte of P1 is set.;mission/sysDefs.h
14006;0x36b6;CURRENT_IMAGE_INFO;INFO;P1: Current Chip, P2: Current Copy;bsp_q7s/core/CoreController.h 14006;0x36b6;CURRENT_IMAGE_INFO;INFO;P1: Current Chip, P2: Current Copy;mission/sysDefs.h
14007;0x36b7;REBOOT_COUNTER;INFO;Total reboot counter, which is the sum of the boot count of all individual images.;bsp_q7s/core/CoreController.h 14007;0x36b7;REBOOT_COUNTER;INFO;Total reboot counter, which is the sum of the boot count of all individual images.;mission/sysDefs.h
14008;0x36b8;INDIVIDUAL_BOOT_COUNTS;INFO;Get the boot count of the individual images. P1: First 16 bits boot count of image 0 0, last 16 bits boot count of image 0 1. P2: First 16 bits boot count of image 1 0, last 16 bits boot count of image 1 1.;bsp_q7s/core/CoreController.h 14008;0x36b8;INDIVIDUAL_BOOT_COUNTS;INFO;Get the boot count of the individual images. P1: First 16 bits boot count of image 0 0, last 16 bits boot count of image 0 1. P2: First 16 bits boot count of image 1 0, last 16 bits boot count of image 1 1.;mission/sysDefs.h
14010;0x36ba;I2C_UNAVAILABLE_REBOOT;MEDIUM;No description;bsp_q7s/core/CoreController.h 14010;0x36ba;TRYING_I2C_RECOVERY;MEDIUM;I2C is unavailable. Trying recovery of I2C bus by power cycling all I2C devices.;mission/sysDefs.h
14011;0x36bb;I2C_REBOOT;MEDIUM;I2C is unavailable. Recovery did not work, performing full reboot.;mission/sysDefs.h
14100;0x3714;NO_VALID_SENSOR_TEMPERATURE;MEDIUM;No description;mission/controller/tcsDefs.h 14100;0x3714;NO_VALID_SENSOR_TEMPERATURE;MEDIUM;No description;mission/controller/tcsDefs.h
14101;0x3715;NO_HEALTHY_HEATER_AVAILABLE;MEDIUM;No description;mission/controller/tcsDefs.h 14101;0x3715;NO_HEALTHY_HEATER_AVAILABLE;MEDIUM;No description;mission/controller/tcsDefs.h
14102;0x3716;SYRLINKS_OVERHEATING;HIGH;No description;mission/controller/tcsDefs.h 14102;0x3716;SYRLINKS_OVERHEATING;HIGH;No description;mission/controller/tcsDefs.h

1 Event ID (dec) Event ID (hex) Name Severity Description File Path
101 11401 0x2c89 GPIO_PULL_LOW_FAILED LOW No description mission/tcs/HeaterHandler.h
102 11402 0x2c8a HEATER_WENT_ON INFO No description mission/tcs/HeaterHandler.h
103 11403 0x2c8b HEATER_WENT_OFF INFO No description mission/tcs/HeaterHandler.h
104 11404 0x2c8c SWITCH_ALREADY_ON LOW INFO No description mission/tcs/HeaterHandler.h
105 11405 0x2c8d SWITCH_ALREADY_OFF LOW INFO No description mission/tcs/HeaterHandler.h
106 11406 0x2c8e MAIN_SWITCH_TIMEOUT MEDIUM No description mission/tcs/HeaterHandler.h
107 11407 0x2c8f FAULTY_HEATER_WAS_ON LOW No description mission/tcs/HeaterHandler.h
108 11500 0x2cec BURN_PHASE_START INFO P1: Burn duration in milliseconds, P2: Dry run flag mission/SolarArrayDeploymentHandler.h
251 13903 0x364f INSERT_CONFIGFILEVALUE_FAILED MEDIUM No description mission/utility/GlobalConfigHandler.h
252 13904 0x3650 WRITE_CONFIGFILE_FAILED MEDIUM No description mission/utility/GlobalConfigHandler.h
253 13905 0x3651 READ_CONFIGFILE_FAILED MEDIUM No description mission/utility/GlobalConfigHandler.h
254 14000 0x36b0 ALLOC_FAILURE MEDIUM No description bsp_q7s/core/CoreController.h mission/sysDefs.h
255 14001 0x36b1 REBOOT_SW LOW Software reboot occurred. Can also be a systemd reboot. P1: Current Chip, P2: Current Copy bsp_q7s/core/CoreController.h mission/sysDefs.h
256 14002 0x36b2 REBOOT_MECHANISM_TRIGGERED MEDIUM The reboot mechanism was triggered. P1: First 16 bits: Last Chip, Last 16 bits: Last Copy, P2: Each byte is the respective reboot count for the slots bsp_q7s/core/CoreController.h mission/sysDefs.h
257 14003 0x36b3 REBOOT_HW MEDIUM No description bsp_q7s/core/CoreController.h mission/sysDefs.h
258 14004 0x36b4 NO_SD_CARD_ACTIVE HIGH No SD card was active. Core controller will attempt to re-initialize a SD card. bsp_q7s/core/CoreController.h mission/sysDefs.h
259 14005 0x36b5 VERSION_INFO INFO P1: Byte 0: Major, Byte 1: Minor, Byte 2: Patch, Byte 3: Has Git Hash P2: First four letters of Git SHA is the last byte of P1 is set. bsp_q7s/core/CoreController.h mission/sysDefs.h
260 14006 0x36b6 CURRENT_IMAGE_INFO INFO P1: Current Chip, P2: Current Copy bsp_q7s/core/CoreController.h mission/sysDefs.h
261 14007 0x36b7 REBOOT_COUNTER INFO Total reboot counter, which is the sum of the boot count of all individual images. bsp_q7s/core/CoreController.h mission/sysDefs.h
262 14008 0x36b8 INDIVIDUAL_BOOT_COUNTS INFO Get the boot count of the individual images. P1: First 16 bits boot count of image 0 0, last 16 bits boot count of image 0 1. P2: First 16 bits boot count of image 1 0, last 16 bits boot count of image 1 1. bsp_q7s/core/CoreController.h mission/sysDefs.h
263 14010 0x36ba I2C_UNAVAILABLE_REBOOT TRYING_I2C_RECOVERY MEDIUM No description I2C is unavailable. Trying recovery of I2C bus by power cycling all I2C devices. bsp_q7s/core/CoreController.h mission/sysDefs.h
264 14011 0x36bb I2C_REBOOT MEDIUM I2C is unavailable. Recovery did not work, performing full reboot. mission/sysDefs.h
265 14100 0x3714 NO_VALID_SENSOR_TEMPERATURE MEDIUM No description mission/controller/tcsDefs.h
266 14101 0x3715 NO_HEALTHY_HEATER_AVAILABLE MEDIUM No description mission/controller/tcsDefs.h
267 14102 0x3716 SYRLINKS_OVERHEATING HIGH No description mission/controller/tcsDefs.h

View File

@ -371,8 +371,8 @@ Full ID (hex); Name; Description; Unique ID; Subsytem Name; File Path
0x3e03;HKM_PeriodicHelperInvalid;No description;3;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h 0x3e03;HKM_PeriodicHelperInvalid;No description;3;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
0x3e04;HKM_PoolobjectNotFound;No description;4;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h 0x3e04;HKM_PoolobjectNotFound;No description;4;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
0x3e05;HKM_DatasetNotFound;No description;5;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h 0x3e05;HKM_DatasetNotFound;No description;5;HOUSEKEEPING_MANAGER;fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
0x3f01;DLEE_NoPacketFound;No description;1;DLE_ENCODER;fsfw/src/fsfw/globalfunctions/DleParser.h 0x3f01;DLEE_StreamTooShort;No description;1;DLE_ENCODER;fsfw/src/fsfw/globalfunctions/DleEncoder.h
0x3f02;DLEE_PossiblePacketLoss;No description;2;DLE_ENCODER;fsfw/src/fsfw/globalfunctions/DleParser.h 0x3f02;DLEE_DecodingError;No description;2;DLE_ENCODER;fsfw/src/fsfw/globalfunctions/DleEncoder.h
0x4201;PUS11_InvalidTypeTimeWindow;No description;1;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h 0x4201;PUS11_InvalidTypeTimeWindow;No description;1;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
0x4202;PUS11_InvalidTimeWindow;No description;2;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h 0x4202;PUS11_InvalidTimeWindow;No description;2;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
0x4203;PUS11_TimeshiftingNotPossible;No description;3;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h 0x4203;PUS11_TimeshiftingNotPossible;No description;3;PUS_SERVICE_11;fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
@ -402,9 +402,9 @@ Full ID (hex); Name; Description; Unique ID; Subsytem Name; File Path
0x4403;UXOS_CommandError;Command execution failed;3;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h 0x4403;UXOS_CommandError;Command execution failed;3;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h
0x4404;UXOS_NoCommandLoadedOrPending;;4;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h 0x4404;UXOS_NoCommandLoadedOrPending;;4;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h
0x4406;UXOS_PcloseCallError;No description;6;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h 0x4406;UXOS_PcloseCallError;No description;6;LINUX_OSAL;fsfw/src/fsfw_hal/linux/CommandExecutor.h
0x4500;HSPI_OpeningFileFailed;No description;0;HAL_SPI;fsfw/src/fsfw_hal/linux/spi/SpiComIF.h 0x4500;HSPI_HalTimeoutRetval;No description;0;HAL_SPI;fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
0x4501;HSPI_FullDuplexTransferFailed;No description;1;HAL_SPI;fsfw/src/fsfw_hal/linux/spi/SpiComIF.h 0x4501;HSPI_HalBusyRetval;No description;1;HAL_SPI;fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
0x4502;HSPI_HalfDuplexTransferFailed;No description;2;HAL_SPI;fsfw/src/fsfw_hal/linux/spi/SpiComIF.h 0x4502;HSPI_HalErrorRetval;No description;2;HAL_SPI;fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
0x4601;HURT_UartReadFailure;No description;1;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h 0x4601;HURT_UartReadFailure;No description;1;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h
0x4602;HURT_UartReadSizeMissmatch;No description;2;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h 0x4602;HURT_UartReadSizeMissmatch;No description;2;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h
0x4603;HURT_UartRxBufferTooSmall;No description;3;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h 0x4603;HURT_UartRxBufferTooSmall;No description;3;HAL_UART;fsfw/src/fsfw_hal/linux/serial/SerialComIF.h
@ -493,8 +493,6 @@ Full ID (hex); Name; Description; Unique ID; Subsytem Name; File Path
0x58a3;SUSS_ExecutionFailed;Command execution failed;163;SUS_HANDLER;mission/acs/RwHandler.h 0x58a3;SUSS_ExecutionFailed;Command execution failed;163;SUS_HANDLER;mission/acs/RwHandler.h
0x58a4;SUSS_CrcError;Reaction wheel reply has invalid crc;164;SUS_HANDLER;mission/acs/RwHandler.h 0x58a4;SUSS_CrcError;Reaction wheel reply has invalid crc;164;SUS_HANDLER;mission/acs/RwHandler.h
0x58a5;SUSS_ValueNotRead;No description;165;SUS_HANDLER;mission/acs/RwHandler.h 0x58a5;SUSS_ValueNotRead;No description;165;SUS_HANDLER;mission/acs/RwHandler.h
0x5900;IPCI_NoReplyAvailable;No description;0;CCSDS_IP_CORE_BRIDGE;linux/acs/ImtqPollingTask.h
0x5901;IPCI_NoPacketFound;No description;1;CCSDS_IP_CORE_BRIDGE;linux/com/SyrlinksComHandler.h
0x59a0;IPCI_PapbBusy;No description;160;CCSDS_IP_CORE_BRIDGE;linux/ipcore/PapbVcInterface.h 0x59a0;IPCI_PapbBusy;No description;160;CCSDS_IP_CORE_BRIDGE;linux/ipcore/PapbVcInterface.h
0x5aa0;PTME_UnknownVcId;No description;160;PTME;linux/ipcore/Ptme.h 0x5aa0;PTME_UnknownVcId;No description;160;PTME;linux/ipcore/Ptme.h
0x5c01;STRHLP_SdNotMounted;SD card specified in path string not mounted;1;STR_HELPER;linux/acs/StrComHandler.h 0x5c01;STRHLP_SdNotMounted;SD card specified in path string not mounted;1;STR_HELPER;linux/acs/StrComHandler.h
@ -542,7 +540,6 @@ Full ID (hex); Name; Description; Unique ID; Subsytem Name; File Path
0x63a0;NVMB_KeyNotExists;Specified key does not exist in json file;160;NVM_PARAM_BASE;mission/memory/NvmParameterBase.h 0x63a0;NVMB_KeyNotExists;Specified key does not exist in json file;160;NVM_PARAM_BASE;mission/memory/NvmParameterBase.h
0x64a0;FSHLP_SdNotMounted;SD card specified with path string not mounted;160;FILE_SYSTEM_HELPER;bsp_q7s/fs/FilesystemHelper.h 0x64a0;FSHLP_SdNotMounted;SD card specified with path string not mounted;160;FILE_SYSTEM_HELPER;bsp_q7s/fs/FilesystemHelper.h
0x64a1;FSHLP_FileNotExists;Specified file does not exist on filesystem;161;FILE_SYSTEM_HELPER;bsp_q7s/fs/FilesystemHelper.h 0x64a1;FSHLP_FileNotExists;Specified file does not exist on filesystem;161;FILE_SYSTEM_HELPER;bsp_q7s/fs/FilesystemHelper.h
0x6502;PLMPHLP_InvalidCrc;No description;2;PLOC_MPSOC_HELPER;linux/payload/ScexHelper.h
0x65a0;PLMPHLP_FileClosedAccidentally;File accidentally close;160;PLOC_MPSOC_HELPER;linux/payload/PlocMpsocHelper.h 0x65a0;PLMPHLP_FileClosedAccidentally;File accidentally close;160;PLOC_MPSOC_HELPER;linux/payload/PlocMpsocHelper.h
0x66a0;SADPL_CommandNotSupported;No description;160;SA_DEPL_HANDLER;mission/SolarArrayDeploymentHandler.h 0x66a0;SADPL_CommandNotSupported;No description;160;SA_DEPL_HANDLER;mission/SolarArrayDeploymentHandler.h
0x66a1;SADPL_DeploymentAlreadyExecuting;No description;161;SA_DEPL_HANDLER;mission/SolarArrayDeploymentHandler.h 0x66a1;SADPL_DeploymentAlreadyExecuting;No description;161;SA_DEPL_HANDLER;mission/SolarArrayDeploymentHandler.h

1 Full ID (hex) Name Description Unique ID Subsytem Name File Path
371 0x3e03 HKM_PeriodicHelperInvalid No description 3 HOUSEKEEPING_MANAGER fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
372 0x3e04 HKM_PoolobjectNotFound No description 4 HOUSEKEEPING_MANAGER fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
373 0x3e05 HKM_DatasetNotFound No description 5 HOUSEKEEPING_MANAGER fsfw/src/fsfw/datapoollocal/LocalDataPoolManager.h
374 0x3f01 DLEE_NoPacketFound DLEE_StreamTooShort No description 1 DLE_ENCODER fsfw/src/fsfw/globalfunctions/DleParser.h fsfw/src/fsfw/globalfunctions/DleEncoder.h
375 0x3f02 DLEE_PossiblePacketLoss DLEE_DecodingError No description 2 DLE_ENCODER fsfw/src/fsfw/globalfunctions/DleParser.h fsfw/src/fsfw/globalfunctions/DleEncoder.h
376 0x4201 PUS11_InvalidTypeTimeWindow No description 1 PUS_SERVICE_11 fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
377 0x4202 PUS11_InvalidTimeWindow No description 2 PUS_SERVICE_11 fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
378 0x4203 PUS11_TimeshiftingNotPossible No description 3 PUS_SERVICE_11 fsfw/src/fsfw/pus/Service11TelecommandScheduling.h
402 0x4403 UXOS_CommandError Command execution failed 3 LINUX_OSAL fsfw/src/fsfw_hal/linux/CommandExecutor.h
403 0x4404 UXOS_NoCommandLoadedOrPending 4 LINUX_OSAL fsfw/src/fsfw_hal/linux/CommandExecutor.h
404 0x4406 UXOS_PcloseCallError No description 6 LINUX_OSAL fsfw/src/fsfw_hal/linux/CommandExecutor.h
405 0x4500 HSPI_OpeningFileFailed HSPI_HalTimeoutRetval No description 0 HAL_SPI fsfw/src/fsfw_hal/linux/spi/SpiComIF.h fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
406 0x4501 HSPI_FullDuplexTransferFailed HSPI_HalBusyRetval No description 1 HAL_SPI fsfw/src/fsfw_hal/linux/spi/SpiComIF.h fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
407 0x4502 HSPI_HalfDuplexTransferFailed HSPI_HalErrorRetval No description 2 HAL_SPI fsfw/src/fsfw_hal/linux/spi/SpiComIF.h fsfw/src/fsfw_hal/stm32h7/spi/spiDefinitions.h
408 0x4601 HURT_UartReadFailure No description 1 HAL_UART fsfw/src/fsfw_hal/linux/serial/SerialComIF.h
409 0x4602 HURT_UartReadSizeMissmatch No description 2 HAL_UART fsfw/src/fsfw_hal/linux/serial/SerialComIF.h
410 0x4603 HURT_UartRxBufferTooSmall No description 3 HAL_UART fsfw/src/fsfw_hal/linux/serial/SerialComIF.h
493 0x58a3 SUSS_ExecutionFailed Command execution failed 163 SUS_HANDLER mission/acs/RwHandler.h
494 0x58a4 SUSS_CrcError Reaction wheel reply has invalid crc 164 SUS_HANDLER mission/acs/RwHandler.h
495 0x58a5 SUSS_ValueNotRead No description 165 SUS_HANDLER mission/acs/RwHandler.h
0x5900 IPCI_NoReplyAvailable No description 0 CCSDS_IP_CORE_BRIDGE linux/acs/ImtqPollingTask.h
0x5901 IPCI_NoPacketFound No description 1 CCSDS_IP_CORE_BRIDGE linux/com/SyrlinksComHandler.h
496 0x59a0 IPCI_PapbBusy No description 160 CCSDS_IP_CORE_BRIDGE linux/ipcore/PapbVcInterface.h
497 0x5aa0 PTME_UnknownVcId No description 160 PTME linux/ipcore/Ptme.h
498 0x5c01 STRHLP_SdNotMounted SD card specified in path string not mounted 1 STR_HELPER linux/acs/StrComHandler.h
540 0x63a0 NVMB_KeyNotExists Specified key does not exist in json file 160 NVM_PARAM_BASE mission/memory/NvmParameterBase.h
541 0x64a0 FSHLP_SdNotMounted SD card specified with path string not mounted 160 FILE_SYSTEM_HELPER bsp_q7s/fs/FilesystemHelper.h
542 0x64a1 FSHLP_FileNotExists Specified file does not exist on filesystem 161 FILE_SYSTEM_HELPER bsp_q7s/fs/FilesystemHelper.h
0x6502 PLMPHLP_InvalidCrc No description 2 PLOC_MPSOC_HELPER linux/payload/ScexHelper.h
543 0x65a0 PLMPHLP_FileClosedAccidentally File accidentally close 160 PLOC_MPSOC_HELPER linux/payload/PlocMpsocHelper.h
544 0x66a0 SADPL_CommandNotSupported No description 160 SA_DEPL_HANDLER mission/SolarArrayDeploymentHandler.h
545 0x66a1 SADPL_DeploymentAlreadyExecuting No description 161 SA_DEPL_HANDLER mission/SolarArrayDeploymentHandler.h

View File

@ -1,7 +1,7 @@
/** /**
* @brief Auto-generated event translation file. Contains 284 translations. * @brief Auto-generated event translation file. Contains 285 translations.
* @details * @details
* Generated on: 2023-04-04 13:59:07 * Generated on: 2023-04-07 11:06:14
*/ */
#include "translateEvents.h" #include "translateEvents.h"
@ -266,7 +266,8 @@ const char *VERSION_INFO_STRING = "VERSION_INFO";
const char *CURRENT_IMAGE_INFO_STRING = "CURRENT_IMAGE_INFO"; const char *CURRENT_IMAGE_INFO_STRING = "CURRENT_IMAGE_INFO";
const char *REBOOT_COUNTER_STRING = "REBOOT_COUNTER"; const char *REBOOT_COUNTER_STRING = "REBOOT_COUNTER";
const char *INDIVIDUAL_BOOT_COUNTS_STRING = "INDIVIDUAL_BOOT_COUNTS"; const char *INDIVIDUAL_BOOT_COUNTS_STRING = "INDIVIDUAL_BOOT_COUNTS";
const char *I2C_UNAVAILABLE_REBOOT_STRING = "I2C_UNAVAILABLE_REBOOT"; const char *TRYING_I2C_RECOVERY_STRING = "TRYING_I2C_RECOVERY";
const char *I2C_REBOOT_STRING = "I2C_REBOOT";
const char *NO_VALID_SENSOR_TEMPERATURE_STRING = "NO_VALID_SENSOR_TEMPERATURE"; const char *NO_VALID_SENSOR_TEMPERATURE_STRING = "NO_VALID_SENSOR_TEMPERATURE";
const char *NO_HEALTHY_HEATER_AVAILABLE_STRING = "NO_HEALTHY_HEATER_AVAILABLE"; const char *NO_HEALTHY_HEATER_AVAILABLE_STRING = "NO_HEALTHY_HEATER_AVAILABLE";
const char *SYRLINKS_OVERHEATING_STRING = "SYRLINKS_OVERHEATING"; const char *SYRLINKS_OVERHEATING_STRING = "SYRLINKS_OVERHEATING";
@ -815,7 +816,9 @@ const char *translateEvents(Event event) {
case (14008): case (14008):
return INDIVIDUAL_BOOT_COUNTS_STRING; return INDIVIDUAL_BOOT_COUNTS_STRING;
case (14010): case (14010):
return I2C_UNAVAILABLE_REBOOT_STRING; return TRYING_I2C_RECOVERY_STRING;
case (14011):
return I2C_REBOOT_STRING;
case (14100): case (14100):
return NO_VALID_SENSOR_TEMPERATURE_STRING; return NO_VALID_SENSOR_TEMPERATURE_STRING;
case (14101): case (14101):

View File

@ -2,7 +2,7 @@
* @brief Auto-generated object translation file. * @brief Auto-generated object translation file.
* @details * @details
* Contains 175 translations. * Contains 175 translations.
* Generated on: 2023-04-04 13:59:07 * Generated on: 2023-04-07 11:06:14
*/ */
#include "translateObjects.h" #include "translateObjects.h"

View File

@ -22,6 +22,7 @@ class ImtqPollingTask : public SystemObject,
ReturnValue_t initialize() override; ReturnValue_t initialize() override;
private: private:
//! [EXPORT] : [SKIP]
static constexpr ReturnValue_t NO_REPLY_AVAILABLE = returnvalue::makeCode(2, 0); static constexpr ReturnValue_t NO_REPLY_AVAILABLE = returnvalue::makeCode(2, 0);
enum class InternalState { IDLE, IS_BUSY } state = InternalState::IDLE; enum class InternalState { IDLE, IS_BUSY } state = InternalState::IDLE;

View File

@ -37,7 +37,7 @@ void I2cTestClass::battInit() {
if (ioctl(bpxInfo.fd, I2C_SLAVE, bpxInfo.addr) < 0) { if (ioctl(bpxInfo.fd, I2C_SLAVE, bpxInfo.addr) < 0) {
sif::error << "Failed to acquire bus access and/or talk to slave" << std::endl; sif::error << "Failed to acquire bus access and/or talk to slave" << std::endl;
} }
cmdBuf[0] = BpxBattery::PORT_PING; cmdBuf[0] = bpxBat::PORT_PING;
cmdBuf[1] = 0x42; cmdBuf[1] = 0x42;
sendLen = 2; sendLen = 2;
ReturnValue_t result = i2cWrite(bpxInfo.fd, cmdBuf.data(), sendLen); ReturnValue_t result = i2cWrite(bpxInfo.fd, cmdBuf.data(), sendLen);
@ -66,7 +66,7 @@ void I2cTestClass::battPeriodic() {
if (ioctl(bpxInfo.fd, I2C_SLAVE, bpxInfo.addr) < 0) { if (ioctl(bpxInfo.fd, I2C_SLAVE, bpxInfo.addr) < 0) {
sif::error << "Failed to acquire bus access and/or talk to slave" << std::endl; sif::error << "Failed to acquire bus access and/or talk to slave" << std::endl;
} }
cmdBuf[0] = BpxBattery::PORT_GET_HK; cmdBuf[0] = bpxBat::PORT_GET_HK;
sendLen = 1; sendLen = 1;
ReturnValue_t result = i2cWrite(bpxInfo.fd, cmdBuf.data(), sendLen); ReturnValue_t result = i2cWrite(bpxInfo.fd, cmdBuf.data(), sendLen);
if (result != returnvalue::OK) { if (result != returnvalue::OK) {

View File

@ -20,6 +20,7 @@ class SyrlinksComHandler : public DeviceCommunicationIF,
//! [EXPORT] : [SKIP] //! [EXPORT] : [SKIP]
static constexpr ReturnValue_t NO_SERIAL_DATA_READ = returnvalue::makeCode(2, 0); static constexpr ReturnValue_t NO_SERIAL_DATA_READ = returnvalue::makeCode(2, 0);
//! [EXPORT] : [SKIP]
static constexpr ReturnValue_t NO_PACKET_FOUND = returnvalue::makeCode(2, 1); static constexpr ReturnValue_t NO_PACKET_FOUND = returnvalue::makeCode(2, 1);
enum class State { SLEEPING, ACTIVE } state = State::SLEEPING; enum class State { SLEEPING, ACTIVE } state = State::SLEEPING;

View File

@ -1,7 +1,7 @@
/** /**
* @brief Auto-generated event translation file. Contains 284 translations. * @brief Auto-generated event translation file. Contains 285 translations.
* @details * @details
* Generated on: 2023-04-04 13:59:07 * Generated on: 2023-04-07 11:06:14
*/ */
#include "translateEvents.h" #include "translateEvents.h"
@ -266,7 +266,8 @@ const char *VERSION_INFO_STRING = "VERSION_INFO";
const char *CURRENT_IMAGE_INFO_STRING = "CURRENT_IMAGE_INFO"; const char *CURRENT_IMAGE_INFO_STRING = "CURRENT_IMAGE_INFO";
const char *REBOOT_COUNTER_STRING = "REBOOT_COUNTER"; const char *REBOOT_COUNTER_STRING = "REBOOT_COUNTER";
const char *INDIVIDUAL_BOOT_COUNTS_STRING = "INDIVIDUAL_BOOT_COUNTS"; const char *INDIVIDUAL_BOOT_COUNTS_STRING = "INDIVIDUAL_BOOT_COUNTS";
const char *I2C_UNAVAILABLE_REBOOT_STRING = "I2C_UNAVAILABLE_REBOOT"; const char *TRYING_I2C_RECOVERY_STRING = "TRYING_I2C_RECOVERY";
const char *I2C_REBOOT_STRING = "I2C_REBOOT";
const char *NO_VALID_SENSOR_TEMPERATURE_STRING = "NO_VALID_SENSOR_TEMPERATURE"; const char *NO_VALID_SENSOR_TEMPERATURE_STRING = "NO_VALID_SENSOR_TEMPERATURE";
const char *NO_HEALTHY_HEATER_AVAILABLE_STRING = "NO_HEALTHY_HEATER_AVAILABLE"; const char *NO_HEALTHY_HEATER_AVAILABLE_STRING = "NO_HEALTHY_HEATER_AVAILABLE";
const char *SYRLINKS_OVERHEATING_STRING = "SYRLINKS_OVERHEATING"; const char *SYRLINKS_OVERHEATING_STRING = "SYRLINKS_OVERHEATING";
@ -815,7 +816,9 @@ const char *translateEvents(Event event) {
case (14008): case (14008):
return INDIVIDUAL_BOOT_COUNTS_STRING; return INDIVIDUAL_BOOT_COUNTS_STRING;
case (14010): case (14010):
return I2C_UNAVAILABLE_REBOOT_STRING; return TRYING_I2C_RECOVERY_STRING;
case (14011):
return I2C_REBOOT_STRING;
case (14100): case (14100):
return NO_VALID_SENSOR_TEMPERATURE_STRING; return NO_VALID_SENSOR_TEMPERATURE_STRING;
case (14101): case (14101):

View File

@ -2,7 +2,7 @@
* @brief Auto-generated object translation file. * @brief Auto-generated object translation file.
* @details * @details
* Contains 175 translations. * Contains 175 translations.
* Generated on: 2023-04-04 13:59:07 * Generated on: 2023-04-07 11:06:14
*/ */
#include "translateObjects.h" #include "translateObjects.h"

View File

@ -10,6 +10,7 @@
class ScexHelper : public SerializeIF { class ScexHelper : public SerializeIF {
public: public:
//! [EXPORT] : [SKIP]
static const ReturnValue_t INVALID_CRC = returnvalue::makeCode(0, 2); static const ReturnValue_t INVALID_CRC = returnvalue::makeCode(0, 2);
ScexHelper(); ScexHelper();

View File

@ -182,14 +182,10 @@ class ThermalController : public ExtendedControllerBase {
susMax1227::SusDataset susSet11; susMax1227::SusDataset susSet11;
lp_var_t<float> tempQ7s = lp_var_t<float>(objects::CORE_CONTROLLER, core::PoolIds::TEMPERATURE); lp_var_t<float> tempQ7s = lp_var_t<float>(objects::CORE_CONTROLLER, core::PoolIds::TEMPERATURE);
lp_var_t<int16_t> battTemp1 = lp_var_t<int16_t> battTemp1 = lp_var_t<int16_t>(objects::BPX_BATT_HANDLER, bpxBat::BATT_TEMP_1);
lp_var_t<int16_t>(objects::BPX_BATT_HANDLER, BpxBattery::BATT_TEMP_1); lp_var_t<int16_t> battTemp2 = lp_var_t<int16_t>(objects::BPX_BATT_HANDLER, bpxBat::BATT_TEMP_2);
lp_var_t<int16_t> battTemp2 = lp_var_t<int16_t> battTemp3 = lp_var_t<int16_t>(objects::BPX_BATT_HANDLER, bpxBat::BATT_TEMP_3);
lp_var_t<int16_t>(objects::BPX_BATT_HANDLER, BpxBattery::BATT_TEMP_2); lp_var_t<int16_t> battTemp4 = lp_var_t<int16_t>(objects::BPX_BATT_HANDLER, bpxBat::BATT_TEMP_4);
lp_var_t<int16_t> battTemp3 =
lp_var_t<int16_t>(objects::BPX_BATT_HANDLER, BpxBattery::BATT_TEMP_3);
lp_var_t<int16_t> battTemp4 =
lp_var_t<int16_t>(objects::BPX_BATT_HANDLER, BpxBattery::BATT_TEMP_4);
lp_var_t<int32_t> tempRw1 = lp_var_t<int32_t>(objects::RW1, rws::TEMPERATURE_C); lp_var_t<int32_t> tempRw1 = lp_var_t<int32_t>(objects::RW1, rws::TEMPERATURE_C);
lp_var_t<int32_t> tempRw2 = lp_var_t<int32_t>(objects::RW2, rws::TEMPERATURE_C); lp_var_t<int32_t> tempRw2 = lp_var_t<int32_t>(objects::RW2, rws::TEMPERATURE_C);
lp_var_t<int32_t> tempRw3 = lp_var_t<int32_t>(objects::RW3, rws::TEMPERATURE_C); lp_var_t<int32_t> tempRw3 = lp_var_t<int32_t>(objects::RW3, rws::TEMPERATURE_C);

View File

@ -27,54 +27,56 @@ void BpxBatteryHandler::doStartUp() {
void BpxBatteryHandler::doShutDown() { void BpxBatteryHandler::doShutDown() {
// Perform a COM check on reboot // Perform a COM check on reboot
state = States::CHECK_COM; state = States::CHECK_COM;
setMode(MODE_OFF);
} }
ReturnValue_t BpxBatteryHandler::buildNormalDeviceCommand(DeviceCommandId_t* id) { ReturnValue_t BpxBatteryHandler::buildNormalDeviceCommand(DeviceCommandId_t* id) {
*id = BpxBattery::GET_HK; *id = bpxBat::GET_HK;
return buildCommandFromCommand(*id, nullptr, 0); return buildCommandFromCommand(*id, nullptr, 0);
} }
ReturnValue_t BpxBatteryHandler::buildTransitionDeviceCommand(DeviceCommandId_t* id) { ReturnValue_t BpxBatteryHandler::buildTransitionDeviceCommand(DeviceCommandId_t* id) {
if (state == States::CHECK_COM) { if (state == States::CHECK_COM) {
*id = BpxBattery::PING; *id = bpxBat::PING;
return buildCommandFromCommand(*id, nullptr, 0); return buildCommandFromCommand(*id, nullptr, 0);
} }
return returnvalue::OK; return returnvalue::OK;
} }
void BpxBatteryHandler::fillCommandAndReplyMap() { void BpxBatteryHandler::fillCommandAndReplyMap() {
using namespace BpxBattery; using namespace bpxBat;
insertInCommandAndReplyMap(GET_HK, 1, &hkSet, GET_HK_REPLY_LEN); insertInCommandAndReplyMap(GET_HK, 1, &hkSet, GET_HK_REPLY_LEN);
insertInCommandAndReplyMap(BpxBattery::PING, 1, nullptr, PING_REPLY_LEN); insertInCommandAndReplyMap(bpxBat::PING, 1, nullptr, PING_REPLY_LEN);
insertInCommandAndReplyMap(BpxBattery::REBOOT, 1, nullptr, 0); insertInCommandAndReplyMap(bpxBat::REBOOT, 1, nullptr, 0);
insertInCommandAndReplyMap(BpxBattery::RESET_COUNTERS, 1, nullptr, EMPTY_REPLY_LEN); insertInCommandAndReplyMap(bpxBat::RESET_COUNTERS, 1, nullptr, EMPTY_REPLY_LEN);
insertInCommandAndReplyMap(BpxBattery::CONFIG_CMD, 1, nullptr, EMPTY_REPLY_LEN); insertInCommandAndReplyMap(bpxBat::CONFIG_CMD, 1, nullptr, EMPTY_REPLY_LEN);
insertInCommandAndReplyMap(BpxBattery::CONFIG_GET, 1, &cfgSet, CONFIG_GET_REPLY_LEN); insertInCommandAndReplyMap(bpxBat::CONFIG_GET, 1, &cfgSet, CONFIG_GET_REPLY_LEN);
} }
ReturnValue_t BpxBatteryHandler::buildCommandFromCommand(DeviceCommandId_t deviceCommand, ReturnValue_t BpxBatteryHandler::buildCommandFromCommand(DeviceCommandId_t deviceCommand,
const uint8_t* commandData, const uint8_t* commandData,
size_t commandDataLen) { size_t commandDataLen) {
switch (deviceCommand) { switch (deviceCommand) {
case (BpxBattery::GET_HK): { case (bpxBat::GET_HK): {
cmdBuf[0] = BpxBattery::PORT_GET_HK; cmdBuf[0] = bpxBat::PORT_GET_HK;
this->rawPacketLen = 1; this->rawPacketLen = 1;
break; break;
} }
case (BpxBattery::PING): { case (bpxBat::PING): {
if (commandDataLen == 1 and commandData != nullptr) { if (commandDataLen == 1 and commandData != nullptr) {
sentPingByte = commandData[0]; sentPingByte = commandData[0];
} else { } else {
sentPingByte = BpxBattery::DEFAULT_PING_SENT_BYTE; sentPingByte = bpxBat::DEFAULT_PING_SENT_BYTE;
} }
cmdBuf[0] = BpxBattery::PORT_PING; cmdBuf[0] = bpxBat::PORT_PING;
cmdBuf[1] = sentPingByte; cmdBuf[1] = sentPingByte;
this->rawPacketLen = 2; this->rawPacketLen = 2;
break; break;
} }
case (BpxBattery::REBOOT): { case (bpxBat::REBOOT): {
cmdBuf[0] = BpxBattery::PORT_REBOOT; sif::info << "BPX BATT: Executing reboot command" << std::endl;
cmdBuf[0] = bpxBat::PORT_REBOOT;
cmdBuf[1] = 0x80; cmdBuf[1] = 0x80;
cmdBuf[2] = 0x07; cmdBuf[2] = 0x07;
cmdBuf[3] = 0x80; cmdBuf[3] = 0x80;
@ -85,26 +87,26 @@ ReturnValue_t BpxBatteryHandler::buildCommandFromCommand(DeviceCommandId_t devic
triggerEvent(DeviceHandlerIF::DEVICE_WANTS_HARD_REBOOT); triggerEvent(DeviceHandlerIF::DEVICE_WANTS_HARD_REBOOT);
break; break;
} }
case (BpxBattery::RESET_COUNTERS): { case (bpxBat::RESET_COUNTERS): {
cmdBuf[0] = BpxBattery::PORT_RESET_COUNTERS; cmdBuf[0] = bpxBat::PORT_RESET_COUNTERS;
cmdBuf[1] = BpxBattery::RESET_COUNTERS_MAGIC_VALUE; cmdBuf[1] = bpxBat::RESET_COUNTERS_MAGIC_VALUE;
this->rawPacketLen = 2; this->rawPacketLen = 2;
break; break;
} }
case (BpxBattery::CONFIG_CMD): { case (bpxBat::CONFIG_CMD): {
cmdBuf[0] = BpxBattery::PORT_CONFIG_CMD; cmdBuf[0] = bpxBat::PORT_CONFIG_CMD;
// Needs to be set to 0x01 according to datasheet // Needs to be set to 0x01 according to datasheet
cmdBuf[1] = 0x01; cmdBuf[1] = 0x01;
this->rawPacketLen = 2; this->rawPacketLen = 2;
break; break;
} }
case (BpxBattery::CONFIG_GET): { case (bpxBat::CONFIG_GET): {
cmdBuf[0] = BpxBattery::PORT_CONFIG_GET; cmdBuf[0] = bpxBat::PORT_CONFIG_GET;
this->rawPacketLen = 1; this->rawPacketLen = 1;
break; break;
} }
case (BpxBattery::CONFIG_SET): { case (bpxBat::CONFIG_SET): {
cmdBuf[0] = BpxBattery::PORT_CONFIG_SET; cmdBuf[0] = bpxBat::PORT_CONFIG_SET;
if (commandDataLen != 3) { if (commandDataLen != 3) {
return DeviceHandlerIF::INVALID_NUMBER_OR_LENGTH_OF_PARAMETERS; return DeviceHandlerIF::INVALID_NUMBER_OR_LENGTH_OF_PARAMETERS;
} }
@ -114,8 +116,8 @@ ReturnValue_t BpxBatteryHandler::buildCommandFromCommand(DeviceCommandId_t devic
this->rawPacketLen = 4; this->rawPacketLen = 4;
break; break;
} }
case (BpxBattery::MAN_HEAT_ON): { case (bpxBat::MAN_HEAT_ON): {
cmdBuf[0] = BpxBattery::PORT_MAN_HEAT_ON; cmdBuf[0] = bpxBat::PORT_MAN_HEAT_ON;
if (commandDataLen != 2) { if (commandDataLen != 2) {
return DeviceHandlerIF::INVALID_NUMBER_OR_LENGTH_OF_PARAMETERS; return DeviceHandlerIF::INVALID_NUMBER_OR_LENGTH_OF_PARAMETERS;
} }
@ -125,8 +127,8 @@ ReturnValue_t BpxBatteryHandler::buildCommandFromCommand(DeviceCommandId_t devic
this->rawPacketLen = 3; this->rawPacketLen = 3;
break; break;
} }
case (BpxBattery::MAN_HEAT_OFF): { case (bpxBat::MAN_HEAT_OFF): {
cmdBuf[0] = BpxBattery::PORT_MAN_HEAT_OFF; cmdBuf[0] = bpxBat::PORT_MAN_HEAT_OFF;
this->rawPacketLen = 1; this->rawPacketLen = 1;
break; break;
} }
@ -142,35 +144,35 @@ ReturnValue_t BpxBatteryHandler::buildCommandFromCommand(DeviceCommandId_t devic
ReturnValue_t BpxBatteryHandler::scanForReply(const uint8_t* start, size_t remainingSize, ReturnValue_t BpxBatteryHandler::scanForReply(const uint8_t* start, size_t remainingSize,
DeviceCommandId_t* foundId, size_t* foundLen) { DeviceCommandId_t* foundId, size_t* foundLen) {
using namespace BpxBattery; using namespace bpxBat;
switch (lastCmd) { switch (lastCmd) {
case (BpxBattery::GET_HK): { case (bpxBat::GET_HK): {
if (remainingSize != GET_HK_REPLY_LEN) { if (remainingSize != GET_HK_REPLY_LEN) {
return DeviceHandlerIF::LENGTH_MISSMATCH; return DeviceHandlerIF::LENGTH_MISSMATCH;
} }
break; break;
} }
case (BpxBattery::PING): case (bpxBat::PING):
case (BpxBattery::MAN_HEAT_ON): case (bpxBat::MAN_HEAT_ON):
case (BpxBattery::MAN_HEAT_OFF): { case (bpxBat::MAN_HEAT_OFF): {
if (remainingSize != PING_REPLY_LEN) { if (remainingSize != PING_REPLY_LEN) {
return DeviceHandlerIF::LENGTH_MISSMATCH; return DeviceHandlerIF::LENGTH_MISSMATCH;
} }
break; break;
} }
case (BpxBattery::REBOOT): { case (bpxBat::REBOOT): {
// Ignore // Ignore
break; break;
} }
case (BpxBattery::RESET_COUNTERS): case (bpxBat::RESET_COUNTERS):
case (BpxBattery::CONFIG_CMD): case (bpxBat::CONFIG_CMD):
case (BpxBattery::CONFIG_SET): { case (bpxBat::CONFIG_SET): {
if (remainingSize != EMPTY_REPLY_LEN) { if (remainingSize != EMPTY_REPLY_LEN) {
return DeviceHandlerIF::LENGTH_MISSMATCH; return DeviceHandlerIF::LENGTH_MISSMATCH;
} }
break; break;
} }
case (BpxBattery::CONFIG_GET): { case (bpxBat::CONFIG_GET): {
if (remainingSize != CONFIG_GET_REPLY_LEN) { if (remainingSize != CONFIG_GET_REPLY_LEN) {
return DeviceHandlerIF::LENGTH_MISSMATCH; return DeviceHandlerIF::LENGTH_MISSMATCH;
} }
@ -187,11 +189,11 @@ ReturnValue_t BpxBatteryHandler::scanForReply(const uint8_t* start, size_t remai
} }
ReturnValue_t BpxBatteryHandler::interpretDeviceReply(DeviceCommandId_t id, const uint8_t* packet) { ReturnValue_t BpxBatteryHandler::interpretDeviceReply(DeviceCommandId_t id, const uint8_t* packet) {
if (id != BpxBattery::REBOOT and packet[1] != 0) { if (id != bpxBat::REBOOT and packet[1] != 0) {
return DeviceHandlerIF::DEVICE_REPORTED_ERROR; return DeviceHandlerIF::DEVICE_REPORTED_ERROR;
} }
switch (id) { switch (id) {
case (BpxBattery::GET_HK): { case (bpxBat::GET_HK): {
PoolReadGuard rg(&hkSet); PoolReadGuard rg(&hkSet);
ReturnValue_t result = hkSet.parseRawHk(packet + 2, 21); ReturnValue_t result = hkSet.parseRawHk(packet + 2, 21);
hkSet.setValidity(true, true); hkSet.setValidity(true, true);
@ -213,7 +215,7 @@ ReturnValue_t BpxBatteryHandler::interpretDeviceReply(DeviceCommandId_t id, cons
} }
break; break;
} }
case (BpxBattery::PING): { case (bpxBat::PING): {
if (packet[2] != sentPingByte) { if (packet[2] != sentPingByte) {
return DeviceHandlerIF::INVALID_DATA; return DeviceHandlerIF::INVALID_DATA;
} }
@ -222,19 +224,19 @@ ReturnValue_t BpxBatteryHandler::interpretDeviceReply(DeviceCommandId_t id, cons
} }
break; break;
} }
case (BpxBattery::RESET_COUNTERS): case (bpxBat::RESET_COUNTERS):
case (BpxBattery::CONFIG_CMD): case (bpxBat::CONFIG_CMD):
case (BpxBattery::CONFIG_SET): { case (bpxBat::CONFIG_SET): {
break; break;
} }
case (BpxBattery::MAN_HEAT_ON): case (bpxBat::MAN_HEAT_ON):
case (BpxBattery::MAN_HEAT_OFF): { case (bpxBat::MAN_HEAT_OFF): {
if (packet[2] != 0x01) { if (packet[2] != 0x01) {
return DeviceHandlerIF::DEVICE_DID_NOT_EXECUTE; return DeviceHandlerIF::DEVICE_DID_NOT_EXECUTE;
} }
break; break;
} }
case (BpxBattery::CONFIG_GET): { case (bpxBat::CONFIG_GET): {
PoolReadGuard rg(&cfgSet); PoolReadGuard rg(&cfgSet);
ReturnValue_t result = cfgSet.parseRawHk(packet + 2, 3); ReturnValue_t result = cfgSet.parseRawHk(packet + 2, 3);
if (result != returnvalue::OK) { if (result != returnvalue::OK) {
@ -243,7 +245,7 @@ ReturnValue_t BpxBatteryHandler::interpretDeviceReply(DeviceCommandId_t id, cons
cfgSet.setValidity(true, true); cfgSet.setValidity(true, true);
break; break;
} }
case (BpxBattery::REBOOT): { case (bpxBat::REBOOT): {
break; break;
} }
default: { default: {
@ -257,20 +259,20 @@ uint32_t BpxBatteryHandler::getTransitionDelayMs(Mode_t modeFrom, Mode_t modeTo)
ReturnValue_t BpxBatteryHandler::initializeLocalDataPool(localpool::DataPool& localDataPoolMap, ReturnValue_t BpxBatteryHandler::initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
LocalDataPoolManager& poolManager) { LocalDataPoolManager& poolManager) {
localDataPoolMap.emplace(BpxBattery::BATT_TEMP_1, &battTemp1); localDataPoolMap.emplace(bpxBat::BATT_TEMP_1, &battTemp1);
localDataPoolMap.emplace(BpxBattery::BATT_TEMP_2, &battTemp2); localDataPoolMap.emplace(bpxBat::BATT_TEMP_2, &battTemp2);
localDataPoolMap.emplace(BpxBattery::BATT_TEMP_3, &battTemp3); localDataPoolMap.emplace(bpxBat::BATT_TEMP_3, &battTemp3);
localDataPoolMap.emplace(BpxBattery::BATT_TEMP_4, &battTemp4); localDataPoolMap.emplace(bpxBat::BATT_TEMP_4, &battTemp4);
localDataPoolMap.emplace(BpxBattery::CHARGE_CURRENT, &chargeCurrent); localDataPoolMap.emplace(bpxBat::CHARGE_CURRENT, &chargeCurrent);
localDataPoolMap.emplace(BpxBattery::DISCHARGE_CURRENT, &dischargeCurrent); localDataPoolMap.emplace(bpxBat::DISCHARGE_CURRENT, &dischargeCurrent);
localDataPoolMap.emplace(BpxBattery::HEATER_CURRENT, &heaterCurrent); localDataPoolMap.emplace(bpxBat::HEATER_CURRENT, &heaterCurrent);
localDataPoolMap.emplace(BpxBattery::BATT_VOLTAGE, &battVolt); localDataPoolMap.emplace(bpxBat::BATT_VOLTAGE, &battVolt);
localDataPoolMap.emplace(BpxBattery::REBOOT_COUNTER, &rebootCounter); localDataPoolMap.emplace(bpxBat::REBOOT_COUNTER, &rebootCounter);
localDataPoolMap.emplace(BpxBattery::BOOTCAUSE, &bootCause); localDataPoolMap.emplace(bpxBat::BOOTCAUSE, &bootCause);
localDataPoolMap.emplace(BpxBattery::BATTERY_HEATER_MODE, &battheatMode); localDataPoolMap.emplace(bpxBat::BATTERY_HEATER_MODE, &battheatMode);
localDataPoolMap.emplace(BpxBattery::BATTHEAT_LOW_LIMIT, &battheatLow); localDataPoolMap.emplace(bpxBat::BATTHEAT_LOW_LIMIT, &battheatLow);
localDataPoolMap.emplace(BpxBattery::BATTHEAT_HIGH_LIMIT, &battheatHigh); localDataPoolMap.emplace(bpxBat::BATTHEAT_HIGH_LIMIT, &battheatHigh);
poolManager.subscribeForRegularPeriodicPacket( poolManager.subscribeForRegularPeriodicPacket(
subdp::RegularHkPeriodicParams(hkSet.getSid(), enableHkSets, 20.0)); subdp::RegularHkPeriodicParams(hkSet.getSid(), enableHkSets, 20.0));

View File

@ -25,7 +25,7 @@ class BpxBatteryHandler : public DeviceHandlerBase {
bool commandExecuted = false; bool commandExecuted = false;
bool debugMode = false; bool debugMode = false;
bool goToNormalModeImmediately = false; bool goToNormalModeImmediately = false;
uint8_t sentPingByte = BpxBattery::DEFAULT_PING_SENT_BYTE; uint8_t sentPingByte = bpxBat::DEFAULT_PING_SENT_BYTE;
#if OBSW_THREAD_TRACING == 1 #if OBSW_THREAD_TRACING == 1
uint32_t opCounter = 0; uint32_t opCounter = 0;
#endif #endif

View File

@ -8,7 +8,7 @@
#include "fsfw/devicehandlers/DeviceHandlerIF.h" #include "fsfw/devicehandlers/DeviceHandlerIF.h"
namespace BpxBattery { namespace bpxBat {
enum LocalPoolIds { enum LocalPoolIds {
CHARGE_CURRENT = 0, CHARGE_CURRENT = 0,
@ -114,18 +114,18 @@ class BpxHkDeserializer : public SerialLinkedListAdapter<SerializeIF> {
} }
}; };
}; // namespace BpxBattery }; // namespace bpxBat
/** /**
* @brief BPX HK data holder * @brief BPX HK data holder
*/ */
class BpxBatteryHk : public StaticLocalDataSet<BpxBattery::HK_ENTRIES> { class BpxBatteryHk : public StaticLocalDataSet<bpxBat::HK_ENTRIES> {
public: public:
/** /**
* Constructor for data users * Constructor for data users
* @param gyroId * @param gyroId
*/ */
BpxBatteryHk(object_id_t bpxId) : StaticLocalDataSet(sid_t(bpxId, BpxBattery::HK_SET_ID)) { BpxBatteryHk(object_id_t bpxId) : StaticLocalDataSet(sid_t(bpxId, bpxBat::HK_SET_ID)) {
setAllVariablesReadOnly(); setAllVariablesReadOnly();
} }
@ -176,28 +176,25 @@ class BpxBatteryHk : public StaticLocalDataSet<BpxBattery::HK_ENTRIES> {
} }
//! Charge current in mA //! Charge current in mA
lp_var_t<uint16_t> chargeCurrent = lp_var_t<uint16_t> chargeCurrent = lp_var_t<uint16_t>(sid.objectId, bpxBat::CHARGE_CURRENT, this);
lp_var_t<uint16_t>(sid.objectId, BpxBattery::CHARGE_CURRENT, this);
//! Discharge current in mA //! Discharge current in mA
lp_var_t<uint16_t> dischargeCurrent = lp_var_t<uint16_t> dischargeCurrent =
lp_var_t<uint16_t>(sid.objectId, BpxBattery::DISCHARGE_CURRENT, this); lp_var_t<uint16_t>(sid.objectId, bpxBat::DISCHARGE_CURRENT, this);
//! Heater current in mA //! Heater current in mA
lp_var_t<uint16_t> heaterCurrent = lp_var_t<uint16_t> heaterCurrent = lp_var_t<uint16_t>(sid.objectId, bpxBat::HEATER_CURRENT, this);
lp_var_t<uint16_t>(sid.objectId, BpxBattery::HEATER_CURRENT, this);
//! Battery voltage in mV //! Battery voltage in mV
lp_var_t<uint16_t> battVoltage = lp_var_t<uint16_t>(sid.objectId, BpxBattery::BATT_VOLTAGE, this); lp_var_t<uint16_t> battVoltage = lp_var_t<uint16_t>(sid.objectId, bpxBat::BATT_VOLTAGE, this);
//! Battery temperature 1 in degC //! Battery temperature 1 in degC
lp_var_t<int16_t> battTemp1 = lp_var_t<int16_t>(sid.objectId, BpxBattery::BATT_TEMP_1, this); lp_var_t<int16_t> battTemp1 = lp_var_t<int16_t>(sid.objectId, bpxBat::BATT_TEMP_1, this);
//! Battery temperature 2 in degC //! Battery temperature 2 in degC
lp_var_t<int16_t> battTemp2 = lp_var_t<int16_t>(sid.objectId, BpxBattery::BATT_TEMP_2, this); lp_var_t<int16_t> battTemp2 = lp_var_t<int16_t>(sid.objectId, bpxBat::BATT_TEMP_2, this);
//! Battery temperature 3 in degC //! Battery temperature 3 in degC
lp_var_t<int16_t> battTemp3 = lp_var_t<int16_t>(sid.objectId, BpxBattery::BATT_TEMP_3, this); lp_var_t<int16_t> battTemp3 = lp_var_t<int16_t>(sid.objectId, bpxBat::BATT_TEMP_3, this);
//! Battery temperature 4 in degC //! Battery temperature 4 in degC
lp_var_t<int16_t> battTemp4 = lp_var_t<int16_t>(sid.objectId, BpxBattery::BATT_TEMP_4, this); lp_var_t<int16_t> battTemp4 = lp_var_t<int16_t>(sid.objectId, bpxBat::BATT_TEMP_4, this);
lp_var_t<uint32_t> rebootCounter = lp_var_t<uint32_t> rebootCounter = lp_var_t<uint32_t>(sid.objectId, bpxBat::REBOOT_COUNTER, this);
lp_var_t<uint32_t>(sid.objectId, BpxBattery::REBOOT_COUNTER, this); lp_var_t<uint8_t> bootcause = lp_var_t<uint8_t>(sid.objectId, bpxBat::BOOTCAUSE, this);
lp_var_t<uint8_t> bootcause = lp_var_t<uint8_t>(sid.objectId, BpxBattery::BOOTCAUSE, this);
private: private:
friend class BpxBatteryHandler; friend class BpxBatteryHandler;
@ -205,16 +202,16 @@ class BpxBatteryHk : public StaticLocalDataSet<BpxBattery::HK_ENTRIES> {
* Constructor for data creator * Constructor for data creator
* @param hkOwner * @param hkOwner
*/ */
BpxBatteryHk(HasLocalDataPoolIF* hkOwner) : StaticLocalDataSet(hkOwner, BpxBattery::HK_SET_ID) {} BpxBatteryHk(HasLocalDataPoolIF* hkOwner) : StaticLocalDataSet(hkOwner, bpxBat::HK_SET_ID) {}
}; };
class BpxBatteryCfg : public StaticLocalDataSet<BpxBattery::CFG_ENTRIES> { class BpxBatteryCfg : public StaticLocalDataSet<bpxBat::CFG_ENTRIES> {
public: public:
/** /**
* Constructor for data users * Constructor for data users
* @param gyroId * @param gyroId
*/ */
BpxBatteryCfg(object_id_t bpxId) : StaticLocalDataSet(sid_t(bpxId, BpxBattery::CFG_SET_ID)) { BpxBatteryCfg(object_id_t bpxId) : StaticLocalDataSet(sid_t(bpxId, bpxBat::CFG_SET_ID)) {
setAllVariablesReadOnly(); setAllVariablesReadOnly();
} }
@ -230,13 +227,12 @@ class BpxBatteryCfg : public StaticLocalDataSet<BpxBattery::CFG_ENTRIES> {
//! Mode for battheater [0=OFF,1=Auto] //! Mode for battheater [0=OFF,1=Auto]
lp_var_t<uint8_t> battheatermode = lp_var_t<uint8_t> battheatermode =
lp_var_t<uint8_t>(sid.objectId, BpxBattery::BATTERY_HEATER_MODE, this); lp_var_t<uint8_t>(sid.objectId, bpxBat::BATTERY_HEATER_MODE, this);
//! Turn heater on at [degC] //! Turn heater on at [degC]
lp_var_t<int8_t> battheaterLow = lp_var_t<int8_t> battheaterLow = lp_var_t<int8_t>(sid.objectId, bpxBat::BATTHEAT_LOW_LIMIT, this);
lp_var_t<int8_t>(sid.objectId, BpxBattery::BATTHEAT_LOW_LIMIT, this);
//! Turn heater off at [degC] //! Turn heater off at [degC]
lp_var_t<int8_t> battheaterHigh = lp_var_t<int8_t> battheaterHigh =
lp_var_t<int8_t>(sid.objectId, BpxBattery::BATTHEAT_HIGH_LIMIT, this); lp_var_t<int8_t>(sid.objectId, bpxBat::BATTHEAT_HIGH_LIMIT, this);
private: private:
friend class BpxBatteryHandler; friend class BpxBatteryHandler;
@ -244,8 +240,7 @@ class BpxBatteryCfg : public StaticLocalDataSet<BpxBattery::CFG_ENTRIES> {
* Constructor for data creator * Constructor for data creator
* @param hkOwner * @param hkOwner
*/ */
BpxBatteryCfg(HasLocalDataPoolIF* hkOwner) BpxBatteryCfg(HasLocalDataPoolIF* hkOwner) : StaticLocalDataSet(hkOwner, bpxBat::CFG_SET_ID) {}
: StaticLocalDataSet(hkOwner, BpxBattery::CFG_SET_ID) {}
}; };
#endif /* MISSION_POWER_BPXBATTDEFS_H_ */ #endif /* MISSION_POWER_BPXBATTDEFS_H_ */

View File

@ -1,12 +1,79 @@
#ifndef MISSION_SYSDEFS_H_ #ifndef MISSION_SYSDEFS_H_
#define MISSION_SYSDEFS_H_ #define MISSION_SYSDEFS_H_
#include <atomic>
#include "acs/defs.h" #include "acs/defs.h"
extern std::atomic_uint16_t I2C_FATAL_ERRORS;
namespace satsystem { namespace satsystem {
enum Mode : Mode_t { BOOT = 5, SAFE = acs::AcsMode::SAFE, PTG_IDLE = acs::AcsMode::PTG_IDLE }; enum Mode : Mode_t { BOOT = 5, SAFE = acs::AcsMode::SAFE, PTG_IDLE = acs::AcsMode::PTG_IDLE };
} }
namespace core {
static constexpr ActionId_t LIST_DIRECTORY_INTO_FILE = 0;
static constexpr ActionId_t ANNOUNCE_VERSION = 1;
static constexpr ActionId_t ANNOUNCE_CURRENT_IMAGE = 2;
static constexpr ActionId_t ANNOUNCE_BOOT_COUNTS = 3;
static constexpr ActionId_t SWITCH_REBOOT_FILE_HANDLING = 5;
static constexpr ActionId_t RESET_REBOOT_COUNTERS = 6;
static constexpr ActionId_t SWITCH_IMG_LOCK = 7;
static constexpr ActionId_t SET_MAX_REBOOT_CNT = 8;
static constexpr ActionId_t OBSW_UPDATE_FROM_SD_0 = 10;
static constexpr ActionId_t OBSW_UPDATE_FROM_SD_1 = 11;
static constexpr ActionId_t OBSW_UPDATE_FROM_TMP = 12;
static constexpr ActionId_t SWITCH_TO_SD_0 = 16;
static constexpr ActionId_t SWITCH_TO_SD_1 = 17;
static constexpr ActionId_t SWITCH_TO_BOTH_SD_CARDS = 18;
//! Reboot using the xsc_boot_copy command
static constexpr ActionId_t XSC_REBOOT_OBC = 32;
static constexpr ActionId_t MOUNT_OTHER_COPY = 33;
//! Reboot using the reboot command
static constexpr ActionId_t REBOOT_OBC = 34;
static constexpr ActionId_t EXECUTE_SHELL_CMD = 40;
static constexpr uint8_t SUBSYSTEM_ID = SUBSYSTEM_ID::CORE;
static constexpr Event ALLOC_FAILURE = event::makeEvent(SUBSYSTEM_ID, 0, severity::MEDIUM);
//! [EXPORT] : [COMMENT] Software reboot occurred. Can also be a systemd reboot.
//! P1: Current Chip, P2: Current Copy
static constexpr Event REBOOT_SW = event::makeEvent(SUBSYSTEM_ID, 1, severity::LOW);
//! [EXPORT] : [COMMENT] The reboot mechanism was triggered.
//! P1: First 16 bits: Last Chip, Last 16 bits: Last Copy,
//! P2: Each byte is the respective reboot count for the slots
static constexpr Event REBOOT_MECHANISM_TRIGGERED =
event::makeEvent(SUBSYSTEM_ID, 2, severity::MEDIUM);
//! Trying to find a way how to determine that the reboot came from ProASIC3 or PCDU..
static constexpr Event REBOOT_HW = event::makeEvent(SUBSYSTEM_ID, 3, severity::MEDIUM);
//! [EXPORT] : [COMMENT] No SD card was active. Core controller will attempt to re-initialize
//! a SD card.
static constexpr Event NO_SD_CARD_ACTIVE = event::makeEvent(SUBSYSTEM_ID, 4, severity::HIGH);
//! [EXPORT] : [COMMENT]
//! P1: Byte 0: Major, Byte 1: Minor, Byte 2: Patch, Byte 3: Has Git Hash
//! P2: First four letters of Git SHA is the last byte of P1 is set.
static constexpr Event VERSION_INFO = event::makeEvent(SUBSYSTEM_ID, 5, severity::INFO);
//! [EXPORT] : [COMMENT] P1: Current Chip, P2: Current Copy
static constexpr Event CURRENT_IMAGE_INFO = event::makeEvent(SUBSYSTEM_ID, 6, severity::INFO);
//! [EXPORT] : [COMMENT] Total reboot counter, which is the sum of the boot count of all
//! individual images.
static constexpr Event REBOOT_COUNTER = event::makeEvent(SUBSYSTEM_ID, 7, severity::INFO);
//! [EXPORT] : [COMMENT] Get the boot count of the individual images.
//! P1: First 16 bits boot count of image 0 0, last 16 bits boot count of image 0 1.
//! P2: First 16 bits boot count of image 1 0, last 16 bits boot count of image 1 1.
static constexpr Event INDIVIDUAL_BOOT_COUNTS = event::makeEvent(SUBSYSTEM_ID, 8, severity::INFO);
//! [EXPORT] : [COMMENT] I2C is unavailable. Trying recovery of I2C bus by power cycling all I2C
//! devices.
static constexpr Event TRYING_I2C_RECOVERY = event::makeEvent(SUBSYSTEM_ID, 10, severity::MEDIUM);
//! [EXPORT] : [COMMENT] I2C is unavailable. Recovery did not work, performing full reboot.
static constexpr Event I2C_REBOOT = event::makeEvent(SUBSYSTEM_ID, 11, severity::MEDIUM);
} // namespace core
#endif /* MISSION_SYSDEFS_H_ */ #endif /* MISSION_SYSDEFS_H_ */

View File

@ -5,4 +5,6 @@ add_subdirectory(com)
add_subdirectory(fdir) add_subdirectory(fdir)
add_subdirectory(power) add_subdirectory(power)
target_sources(${LIB_EIVE_MISSION} PRIVATE DualLanePowerStateMachine.cpp) target_sources(
${LIB_EIVE_MISSION} PRIVATE systemTree.cpp DualLanePowerStateMachine.cpp
EiveSystem.cpp treeUtil.cpp)

View File

@ -0,0 +1,281 @@
#include "EiveSystem.h"
#include <eive/objects.h>
#include <fsfw/events/EventManager.h>
#include <fsfw/ipc/QueueFactory.h>
#include <fsfw/power/PowerSwitchIF.h>
#include <mission/acs/defs.h>
#include <mission/com/defs.h>
#include <mission/controller/tcsDefs.h>
#include "mission/power/bpxBattDefs.h"
#include "mission/power/defs.h"
#include "mission/sysDefs.h"
EiveSystem::EiveSystem(object_id_t setObjectId, uint32_t maxNumberOfSequences,
uint32_t maxNumberOfTables, std::atomic_uint16_t& i2cErrors)
: Subsystem(setObjectId, maxNumberOfSequences, maxNumberOfTables),
actionHelper(this, commandQueue),
i2cErrors(i2cErrors) {
auto mqArgs = MqArgs(SubsystemBase::getObjectId(), static_cast<void*>(this));
eventQueue =
QueueFactory::instance()->createMessageQueue(10, EventMessage::EVENT_MESSAGE_SIZE, &mqArgs);
}
void EiveSystem::announceMode(bool recursive) {
const char* modeStr = "UNKNOWN";
switch (mode) {
case (satsystem::Mode::BOOT): {
modeStr = "OFF/BOOT";
break;
}
case (satsystem::Mode::SAFE): {
modeStr = "SAFE";
break;
}
case (satsystem::Mode::PTG_IDLE): {
modeStr = "POINTING IDLE";
break;
}
case (acs::AcsMode::PTG_INERTIAL): {
modeStr = "POINTING INERTIAL";
break;
}
case (acs::AcsMode::PTG_TARGET): {
modeStr = "POINTING TARGET";
break;
}
case (acs::AcsMode::PTG_TARGET_GS): {
modeStr = "POINTING TARGET GS";
break;
}
}
sif::info << "EIVE system is now in " << modeStr << " mode" << std::endl;
return Subsystem::announceMode(recursive);
}
void EiveSystem::performChildOperation() {
Subsystem::performChildOperation();
handleEventMessages();
if (not isInTransition and performSafeRecovery) {
commandSelfToSafe();
performSafeRecovery = false;
return;
}
i2cRecoveryLogic();
}
ReturnValue_t EiveSystem::initialize() {
if (powerSwitcher == nullptr) {
return ObjectManager::CHILD_INIT_FAILED;
}
ReturnValue_t result = actionHelper.initialize();
if (result != returnvalue::OK) {
return result;
}
auto* bpxDest = ObjectManager::instance()->get<HasActionsIF>(objects::BPX_BATT_HANDLER);
if (bpxDest == nullptr) {
return ObjectManager::CHILD_INIT_FAILED;
}
bpxBattQueueId = bpxDest->getCommandQueue();
auto* coreCtrl = ObjectManager::instance()->get<HasActionsIF>(objects::CORE_CONTROLLER);
if (coreCtrl == nullptr) {
return ObjectManager::CHILD_INIT_FAILED;
}
coreCtrlQueueId = coreCtrl->getCommandQueue();
auto* manager = ObjectManager::instance()->get<EventManagerIF>(objects::EVENT_MANAGER);
if (manager == nullptr) {
#if FSFW_CPP_OSTREAM_ENABLED == 1
sif::error << "AcsSubsystem::initialize: Invalid event manager" << std::endl;
#endif
return ObjectManagerIF::CHILD_INIT_FAILED;
}
result = manager->registerListener(eventQueue->getId());
if (result != returnvalue::OK) {
#if FSFW_CPP_OSTREAM_ENABLED == 1
sif::warning << "AcsSubsystem::registerListener: Failed to register as "
"listener"
<< std::endl;
#endif
return ObjectManagerIF::CHILD_INIT_FAILED;
}
manager->subscribeToEvent(eventQueue->getId(),
event::getEventId(tcsCtrl::PCDU_SYSTEM_OVERHEATING));
manager->subscribeToEvent(eventQueue->getId(), event::getEventId(tcsCtrl::OBC_OVERHEATING));
// manager->subscribeToEvent(eventQueue->getId(), event::getEventId(CoreController::))
return Subsystem::initialize();
}
void EiveSystem::handleEventMessages() {
EventMessage event;
for (ReturnValue_t status = eventQueue->receiveMessage(&event); status == returnvalue::OK;
status = eventQueue->receiveMessage(&event)) {
switch (event.getMessageId()) {
case EventMessage::EVENT_MESSAGE:
switch (event.getEvent()) {
case tcsCtrl::OBC_OVERHEATING:
case tcsCtrl::PCDU_SYSTEM_OVERHEATING: {
if (isInTransition) {
performSafeRecovery = true;
return;
}
commandSelfToSafe();
break;
}
}
break;
default:
sif::debug << "EiveSystem: Did not subscribe to event " << event.getEvent() << std::endl;
break;
}
}
}
MessageQueueId_t EiveSystem::getCommandQueue() const { return Subsystem::getCommandQueue(); }
ReturnValue_t EiveSystem::executeAction(ActionId_t actionId, MessageQueueId_t commandedBy,
const uint8_t* data, size_t size) {
switch (actionId) {
case (EXECUTE_I2C_REBOOT): {
triggerEvent(core::TRYING_I2C_RECOVERY);
performI2cReboot = true;
// This flag is more related to autonomous recovery handling, so we reset it here if this
// reboot sequence is commanded manually.
alreadyTriedI2cRecovery = false;
i2cRebootState = I2cRebootState::SYSTEM_MODE_BOOT;
this->actionCommandedBy = commandedBy;
return returnvalue::OK;
}
default: {
return HasActionsIF::INVALID_ACTION_ID;
}
}
return returnvalue::OK;
}
void EiveSystem::setI2cRecoveryParams(PowerSwitchIF* pwrSwitcher) {
this->powerSwitcher = pwrSwitcher;
}
void EiveSystem::i2cRecoveryLogic() {
ReturnValue_t result;
if (not performI2cReboot) {
// If a recovery worked, need to reset these flags and the error count after some time.
if (i2cRecoveryClearCountdown.hasTimedOut()) {
i2cErrors = 0;
alreadyTriedI2cRecovery = false;
i2cRebootHandlingCountdown.resetTimer();
}
// If an I2C recovery is not ongoing and the I2C error counter is above a threshold, try
// recovery or reboot if recovery was already attempted.
if (i2cErrors >= 5) {
if (not alreadyTriedI2cRecovery) {
// Try recovery.
executeAction(EXECUTE_I2C_REBOOT, MessageQueueIF::NO_QUEUE, nullptr, 0);
} else {
// We already tried an I2C recovery but the bus is still broken.
// Send full reboot request to core controller.
CommandMessage msg;
ActionMessage::setCommand(&msg, core::REBOOT_OBC, store_address_t());
result = commandQueue->sendMessage(coreCtrlQueueId, &msg);
}
}
}
if (not isInTransition and performI2cReboot) {
switch (i2cRebootState) {
case (I2cRebootState::NONE): {
break;
}
case (I2cRebootState::SYSTEM_MODE_BOOT): {
startTransition(satsystem::Mode::BOOT, 0);
i2cRebootState = I2cRebootState::SWITCH_3V3_STACK_OFF_AND_BATT_REBOOT;
i2cRebootHandlingCountdown.resetTimer();
break;
}
case (I2cRebootState::SWITCH_3V3_STACK_OFF_AND_BATT_REBOOT): {
if (mode == satsystem::Mode::BOOT) {
result = powerSwitcher->sendSwitchCommand(power::Switches::P60_DOCK_3V3_STACK,
PowerSwitchIF::SWITCH_OFF);
if (result != returnvalue::OK) {
actionHelper.finish(false, actionCommandedBy, EXECUTE_I2C_REBOOT, result);
commonI2cRecoverySequenceFinish();
return;
}
CommandMessage msg;
store_address_t dummy{};
ActionMessage::setCommand(&msg, bpxBat::REBOOT, dummy);
result = commandQueue->sendMessage(bpxBattQueueId, &msg);
if (result != returnvalue::OK) {
actionHelper.finish(false, actionCommandedBy, EXECUTE_I2C_REBOOT, result);
commonI2cRecoverySequenceFinish();
return;
}
i2cRebootState = I2cRebootState::WAIT_CYCLE;
}
break;
}
case (I2cRebootState::WAIT_CYCLE): {
i2cRebootState = I2cRebootState::SWITCH_3V3_STACK_ON;
break;
}
case (I2cRebootState::SWITCH_3V3_STACK_ON): {
result = powerSwitcher->sendSwitchCommand(power::Switches::P60_DOCK_3V3_STACK,
PowerSwitchIF::SWITCH_ON);
if (result != returnvalue::OK) {
actionHelper.finish(false, actionCommandedBy, EXECUTE_I2C_REBOOT, result);
commonI2cRecoverySequenceFinish();
return;
}
i2cRebootState = I2cRebootState::SYSTEM_MODE_SAFE;
break;
}
case (I2cRebootState::SYSTEM_MODE_SAFE): {
if (powerSwitcher->getSwitchState(power::Switches::P60_DOCK_3V3_STACK) ==
PowerSwitchIF::SWITCH_ON) {
// This should always be accepted
commonI2cRecoverySequenceFinish();
actionHelper.finish(true, actionCommandedBy, EXECUTE_I2C_REBOOT);
}
break;
}
default: {
sif::error << "EiveSystem: Unexpected I2C reboot state" << std::endl;
break;
}
}
// Timeout handling for the internal procedure.
if (i2cRebootState != I2cRebootState::NONE and i2cRebootHandlingCountdown.hasTimedOut()) {
actionHelper.finish(false, actionCommandedBy, EXECUTE_I2C_REBOOT, returnvalue::FAILED);
// Command stack back on in any case.
powerSwitcher->sendSwitchCommand(power::Switches::P60_DOCK_3V3_STACK,
PowerSwitchIF::SWITCH_ON);
commonI2cRecoverySequenceFinish();
}
}
}
void EiveSystem::commandSelfToSafe() { startTransition(satsystem::Mode::SAFE, 0); }
void EiveSystem::commonI2cRecoverySequenceFinish() {
alreadyTriedI2cRecovery = true;
performI2cReboot = false;
i2cRecoveryClearCountdown.resetTimer();
i2cRebootState = I2cRebootState::NONE;
// Reset this counter. If I2C devices are still problematic, we will get a full reboot
// next time this count goes above 5.
i2cErrors = 0;
// This should always be accepted
commandSelfToSafe();
}
ReturnValue_t EiveSystem::handleCommandMessage(CommandMessage* message) {
if (message->getMessageType() == messagetypes::ACTION) {
return actionHelper.handleActionMessage(message);
}
return Subsystem::handleCommandMessage(message);
}

View File

@ -0,0 +1,61 @@
#ifndef MISSION_SYSTEM_EIVESYSTEM_H_
#define MISSION_SYSTEM_EIVESYSTEM_H_
#include <fsfw/action/HasActionsIF.h>
#include <fsfw/power/PowerSwitchIF.h>
#include <fsfw/subsystem/Subsystem.h>
#include <atomic>
class EiveSystem : public Subsystem, public HasActionsIF {
public:
static constexpr ActionId_t EXECUTE_I2C_REBOOT = 10;
EiveSystem(object_id_t setObjectId, uint32_t maxNumberOfSequences, uint32_t maxNumberOfTables,
std::atomic_uint16_t& i2cErrors);
void setI2cRecoveryParams(PowerSwitchIF* pwrSwitcher);
[[nodiscard]] MessageQueueId_t getCommandQueue() const override;
private:
enum class I2cRebootState {
NONE,
SYSTEM_MODE_BOOT,
SWITCH_3V3_STACK_OFF_AND_BATT_REBOOT,
WAIT_CYCLE,
SWITCH_3V3_STACK_ON,
SYSTEM_MODE_SAFE
} i2cRebootState = I2cRebootState::NONE;
MessageQueueIF* eventQueue = nullptr;
bool performSafeRecovery = false;
bool performI2cReboot = false;
bool alreadyTriedI2cRecovery = false;
ActionHelper actionHelper;
PowerSwitchIF* powerSwitcher = nullptr;
std::atomic_uint16_t& i2cErrors;
MessageQueueId_t bpxBattQueueId = MessageQueueIF::NO_QUEUE;
MessageQueueId_t coreCtrlQueueId = MessageQueueIF::NO_QUEUE;
MessageQueueId_t actionCommandedBy = MessageQueueIF::NO_QUEUE;
Countdown i2cRebootHandlingCountdown = Countdown(10000);
// Countdown i2cUnavailableCountdown = Countdown(30000);
// After 1 minute, clear the flag to avoid full reboots on I2C issues.
Countdown i2cRecoveryClearCountdown = Countdown(60000);
ReturnValue_t initialize() override;
void performChildOperation() override;
void announceMode(bool recursive) override;
ReturnValue_t executeAction(ActionId_t actionId, MessageQueueId_t commandedBy,
const uint8_t* data, size_t size) override;
ReturnValue_t handleCommandMessage(CommandMessage* message) override;
void i2cRecoveryLogic();
void handleEventMessages();
void commandSelfToSafe();
void commonI2cRecoverySequenceFinish();
};
#endif /* MISSION_SYSTEM_EIVESYSTEM_H_ */

View File

@ -11,7 +11,7 @@
#include "eive/objects.h" #include "eive/objects.h"
#include "mission/acs/defs.h" #include "mission/acs/defs.h"
#include "mission/power/defs.h" #include "mission/power/defs.h"
#include "mission/system/tree/util.h" #include "mission/system/treeUtil.h"
AcsSubsystem satsystem::acs::ACS_SUBSYSTEM(objects::ACS_SUBSYSTEM, 12, 24); AcsSubsystem satsystem::acs::ACS_SUBSYSTEM(objects::ACS_SUBSYSTEM, 12, 24);

View File

@ -6,7 +6,7 @@
#include "eive/objects.h" #include "eive/objects.h"
#include "mission/com/defs.h" #include "mission/com/defs.h"
#include "mission/system/tree/util.h" #include "mission/system/treeUtil.h"
const auto check = subsystem::checkInsert; const auto check = subsystem::checkInsert;

View File

@ -1,9 +1,4 @@
target_sources( target_sources(
${LIB_EIVE_MISSION} ${LIB_EIVE_MISSION}
PRIVATE EiveSystem.cpp PRIVATE CamSwitcher.cpp TcsSubsystem.cpp PayloadSubsystem.cpp
CamSwitcher.cpp Stack5VHandler.cpp PowerStateMachineBase.cpp TcsBoardAssembly.cpp)
TcsSubsystem.cpp
PayloadSubsystem.cpp
Stack5VHandler.cpp
PowerStateMachineBase.cpp
TcsBoardAssembly.cpp)

View File

@ -1,111 +0,0 @@
#include "EiveSystem.h"
#include <eive/objects.h>
#include <fsfw/events/EventManager.h>
#include <fsfw/ipc/QueueFactory.h>
#include <mission/acs/defs.h>
#include <mission/com/defs.h>
#include <mission/controller/tcsDefs.h>
#include "mission/sysDefs.h"
EiveSystem::EiveSystem(object_id_t setObjectId, uint32_t maxNumberOfSequences,
uint32_t maxNumberOfTables)
: Subsystem(setObjectId, maxNumberOfSequences, maxNumberOfTables) {
auto mqArgs = MqArgs(SubsystemBase::getObjectId(), static_cast<void*>(this));
eventQueue =
QueueFactory::instance()->createMessageQueue(10, EventMessage::EVENT_MESSAGE_SIZE, &mqArgs);
}
void EiveSystem::announceMode(bool recursive) {
const char* modeStr = "UNKNOWN";
switch (mode) {
case (satsystem::Mode::BOOT): {
modeStr = "OFF/BOOT";
break;
}
case (satsystem::Mode::SAFE): {
modeStr = "SAFE";
break;
}
case (satsystem::Mode::PTG_IDLE): {
modeStr = "POINTING IDLE";
break;
}
case (acs::AcsMode::PTG_INERTIAL): {
modeStr = "POINTING INERTIAL";
break;
}
case (acs::AcsMode::PTG_TARGET): {
modeStr = "POINTING TARGET";
break;
}
case (acs::AcsMode::PTG_TARGET_GS): {
modeStr = "POINTING TARGET GS";
break;
}
}
sif::info << "EIVE system is now in " << modeStr << " mode" << std::endl;
return Subsystem::announceMode(recursive);
}
void EiveSystem::performChildOperation() {
Subsystem::performChildOperation();
handleEventMessages();
if (not isInTransition and performSafeRecovery) {
commandSelfToSafe();
performSafeRecovery = false;
}
}
ReturnValue_t EiveSystem::initialize() {
auto* manager = ObjectManager::instance()->get<EventManagerIF>(objects::EVENT_MANAGER);
if (manager == nullptr) {
#if FSFW_CPP_OSTREAM_ENABLED == 1
sif::error << "AcsSubsystem::initialize: Invalid event manager" << std::endl;
#endif
return ObjectManagerIF::CHILD_INIT_FAILED;
}
ReturnValue_t result = manager->registerListener(eventQueue->getId());
if (result != returnvalue::OK) {
#if FSFW_CPP_OSTREAM_ENABLED == 1
sif::warning << "AcsSubsystem::registerListener: Failed to register as "
"listener"
<< std::endl;
#endif
return ObjectManagerIF::CHILD_INIT_FAILED;
}
manager->subscribeToEvent(eventQueue->getId(),
event::getEventId(tcsCtrl::PCDU_SYSTEM_OVERHEATING));
manager->subscribeToEvent(eventQueue->getId(), event::getEventId(tcsCtrl::OBC_OVERHEATING));
return Subsystem::initialize();
}
void EiveSystem::handleEventMessages() {
EventMessage event;
for (ReturnValue_t status = eventQueue->receiveMessage(&event); status == returnvalue::OK;
status = eventQueue->receiveMessage(&event)) {
switch (event.getMessageId()) {
case EventMessage::EVENT_MESSAGE:
switch (event.getEvent()) {
case tcsCtrl::OBC_OVERHEATING:
case tcsCtrl::PCDU_SYSTEM_OVERHEATING: {
if (isInTransition) {
performSafeRecovery = true;
return;
}
commandSelfToSafe();
break;
}
}
break;
default:
sif::debug << "EiveSystem: Did not subscribe to event " << event.getEvent() << std::endl;
break;
}
}
}
void EiveSystem::commandSelfToSafe() { startTransition(satsystem::Mode::SAFE, 0); }

View File

@ -1,21 +0,0 @@
#ifndef MISSION_SYSTEM_EIVESYSTEM_H_
#define MISSION_SYSTEM_EIVESYSTEM_H_
#include <fsfw/subsystem/Subsystem.h>
class EiveSystem : public Subsystem {
public:
EiveSystem(object_id_t setObjectId, uint32_t maxNumberOfSequences, uint32_t maxNumberOfTables);
private:
MessageQueueIF* eventQueue = nullptr;
bool performSafeRecovery = false;
ReturnValue_t initialize() override;
void performChildOperation() override;
void announceMode(bool recursive) override;
void handleEventMessages();
void commandSelfToSafe();
};
#endif /* MISSION_SYSTEM_EIVESYSTEM_H_ */

View File

@ -1,4 +1,4 @@
#include "system.h" #include "systemTree.h"
#include <fsfw/devicehandlers/DeviceHandlerIF.h> #include <fsfw/devicehandlers/DeviceHandlerIF.h>
#include <fsfw/subsystem/Subsystem.h> #include <fsfw/subsystem/Subsystem.h>
@ -6,12 +6,14 @@
#include <mission/sysDefs.h> #include <mission/sysDefs.h>
#include <mission/system/com/comModeTree.h> #include <mission/system/com/comModeTree.h>
#include <atomic>
#include "eive/objects.h" #include "eive/objects.h"
#include "mission/com/defs.h" #include "mission/com/defs.h"
#include "mission/system/acs/acsModeTree.h" #include "mission/system/acs/acsModeTree.h"
#include "payloadModeTree.h" #include "mission/system/tree/payloadModeTree.h"
#include "tcsModeTree.h" #include "mission/system/tree/tcsModeTree.h"
#include "util.h" #include "treeUtil.h"
namespace { namespace {
// Alias for checker function // Alias for checker function
@ -41,7 +43,7 @@ void satsystem::init() {
EIVE_SYSTEM.setInitialMode(satsystem::Mode::BOOT, 0); EIVE_SYSTEM.setInitialMode(satsystem::Mode::BOOT, 0);
} }
EiveSystem satsystem::EIVE_SYSTEM = EiveSystem(objects::EIVE_SYSTEM, 12, 24); EiveSystem satsystem::EIVE_SYSTEM = EiveSystem(objects::EIVE_SYSTEM, 12, 24, I2C_FATAL_ERRORS);
auto EIVE_SEQUENCE_BOOT = std::make_pair(satsystem::Mode::BOOT, FixedArrayList<ModeListEntry, 5>()); auto EIVE_SEQUENCE_BOOT = std::make_pair(satsystem::Mode::BOOT, FixedArrayList<ModeListEntry, 5>());
auto EIVE_TABLE_BOOT_TGT = auto EIVE_TABLE_BOOT_TGT =

View File

@ -1,7 +1,7 @@
#ifndef MISSION_SYSTEM_TREE_SYSTEM_H_ #ifndef MISSION_SYSTEM_TREE_SYSTEM_H_
#define MISSION_SYSTEM_TREE_SYSTEM_H_ #define MISSION_SYSTEM_TREE_SYSTEM_H_
#include <mission/system/objects/EiveSystem.h> #include <mission/system/EiveSystem.h>
namespace satsystem { namespace satsystem {

View File

@ -1,2 +1 @@
target_sources(${LIB_EIVE_MISSION} PRIVATE payloadModeTree.cpp tcsModeTree.cpp target_sources(${LIB_EIVE_MISSION} PRIVATE payloadModeTree.cpp tcsModeTree.cpp)
system.cpp util.cpp)

View File

@ -10,7 +10,7 @@
#include "eive/objects.h" #include "eive/objects.h"
#include "mission/power/defs.h" #include "mission/power/defs.h"
#include "mission/system/objects/PayloadSubsystem.h" #include "mission/system/objects/PayloadSubsystem.h"
#include "util.h" #include "mission/system/treeUtil.h"
namespace { namespace {
void initOffSequence(Subsystem& ss, ModeListEntry& eh); void initOffSequence(Subsystem& ss, ModeListEntry& eh);

View File

@ -3,7 +3,7 @@
#include "eive/objects.h" #include "eive/objects.h"
#include "fsfw/devicehandlers/DeviceHandlerIF.h" #include "fsfw/devicehandlers/DeviceHandlerIF.h"
#include "fsfw/subsystem/Subsystem.h" #include "fsfw/subsystem/Subsystem.h"
#include "mission/system/tree/util.h" #include "mission/system/treeUtil.h"
TcsSubsystem satsystem::tcs::SUBSYSTEM(objects::TCS_SUBSYSTEM, 12, 24); TcsSubsystem satsystem::tcs::SUBSYSTEM(objects::TCS_SUBSYSTEM, 12, 24);

View File

@ -1,4 +1,4 @@
#include "util.h" #include "treeUtil.h"
#include "fsfw/container/FixedMap.h" #include "fsfw/container/FixedMap.h"
#include "fsfw/serviceinterface.h" #include "fsfw/serviceinterface.h"

View File

@ -331,7 +331,6 @@ void HeaterHandler::handleSwitchOffCommand(heater::Switchers heaterIdx) {
} }
} }
} else { } else {
sif::info << "HeaterHandler::handleSwitchOffCommand: Switch already off" << std::endl;
triggerEvent(SWITCH_ALREADY_OFF, heaterIdx); triggerEvent(SWITCH_ALREADY_OFF, heaterIdx);
} }
if (heater.replyQueue != NO_COMMANDER) { if (heater.replyQueue != NO_COMMANDER) {

View File

@ -101,8 +101,8 @@ class HeaterHandler : public ExecutableObjectIF,
static constexpr Event GPIO_PULL_LOW_FAILED = MAKE_EVENT(1, severity::LOW); static constexpr Event GPIO_PULL_LOW_FAILED = MAKE_EVENT(1, severity::LOW);
static constexpr Event HEATER_WENT_ON = event::makeEvent(SUBSYSTEM_ID, 2, severity::INFO); static constexpr Event HEATER_WENT_ON = event::makeEvent(SUBSYSTEM_ID, 2, severity::INFO);
static constexpr Event HEATER_WENT_OFF = event::makeEvent(SUBSYSTEM_ID, 3, severity::INFO); static constexpr Event HEATER_WENT_OFF = event::makeEvent(SUBSYSTEM_ID, 3, severity::INFO);
static constexpr Event SWITCH_ALREADY_ON = MAKE_EVENT(4, severity::LOW); static constexpr Event SWITCH_ALREADY_ON = MAKE_EVENT(4, severity::INFO);
static constexpr Event SWITCH_ALREADY_OFF = MAKE_EVENT(5, severity::LOW); static constexpr Event SWITCH_ALREADY_OFF = MAKE_EVENT(5, severity::INFO);
static constexpr Event MAIN_SWITCH_TIMEOUT = MAKE_EVENT(6, severity::MEDIUM); static constexpr Event MAIN_SWITCH_TIMEOUT = MAKE_EVENT(6, severity::MEDIUM);
//! A faulty heater was one. The SW will autonomously attempt to shut it down. P1: Heater Index //! A faulty heater was one. The SW will autonomously attempt to shut it down. P1: Heater Index
static constexpr Event FAULTY_HEATER_WAS_ON = event::makeEvent(SUBSYSTEM_ID, 7, severity::LOW); static constexpr Event FAULTY_HEATER_WAS_ON = event::makeEvent(SUBSYSTEM_ID, 7, severity::LOW);

2
tmtc

@ -1 +1 @@
Subproject commit 7e5fa2e61a3f2b50860fe2e3427f31f7ebaf854f Subproject commit 91a8a2e89519ac20d9ddabec2d8eaeb7707718d5