added health getter function
All checks were successful
EIVE/eive-obsw/pipeline/pr-develop This commit looks good
All checks were successful
EIVE/eive-obsw/pipeline/pr-develop This commit looks good
This commit is contained in:
parent
7ea2fd67c7
commit
b89e440fc4
@ -186,7 +186,7 @@ void scheduling::initTasks() {
|
|||||||
#endif /* OBSW_ADD_TEST_CODE == 1 */
|
#endif /* OBSW_ADD_TEST_CODE == 1 */
|
||||||
|
|
||||||
PeriodicTaskIF* dummyTask = factory->createPeriodicTask(
|
PeriodicTaskIF* dummyTask = factory->createPeriodicTask(
|
||||||
"DUMMY_TASK", 30, PeriodicTaskIF::MINIMUM_STACK_SIZE, 1.0, missedDeadlineFunc);
|
"DUMMY_TASK", 30, PeriodicTaskIF::MINIMUM_STACK_SIZE, 1.0, missedDeadlineFunc);
|
||||||
scheduling::scheduleTmpTempSensors(dummyTask);
|
scheduling::scheduleTmpTempSensors(dummyTask);
|
||||||
scheduling::scheduleRtdSensors(dummyTask);
|
scheduling::scheduleRtdSensors(dummyTask);
|
||||||
dummyTask->addComponent(objects::SUS_0_N_LOC_XFYFZM_PT_XF);
|
dummyTask->addComponent(objects::SUS_0_N_LOC_XFYFZM_PT_XF);
|
||||||
|
@ -106,7 +106,6 @@ void ThermalController::performControlOperation() {
|
|||||||
|
|
||||||
// TODO: Heater control
|
// TODO: Heater control
|
||||||
ctrl4KCamera();
|
ctrl4KCamera();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ReturnValue_t ThermalController::initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
|
ReturnValue_t ThermalController::initializeLocalDataPool(localpool::DataPool& localDataPoolMap,
|
||||||
|
@ -19,7 +19,8 @@
|
|||||||
* limit is exceeded to avoid reaching NOP limit
|
* limit is exceeded to avoid reaching NOP limit
|
||||||
*/
|
*/
|
||||||
struct TempLimits {
|
struct TempLimits {
|
||||||
TempLimits(float nopLowerLimit, float opLowerLimit, float cutOffLimit, float opUpperLimit, float nopUpperLimit)
|
TempLimits(float nopLowerLimit, float opLowerLimit, float cutOffLimit, float opUpperLimit,
|
||||||
|
float nopUpperLimit)
|
||||||
: opLowerLimit(opLowerLimit),
|
: opLowerLimit(opLowerLimit),
|
||||||
opUpperLimit(opUpperLimit),
|
opUpperLimit(opUpperLimit),
|
||||||
cutOffLimit(cutOffLimit),
|
cutOffLimit(cutOffLimit),
|
||||||
|
@ -361,3 +361,12 @@ ReturnValue_t HeaterHandler::getSwitchState(uint8_t switchNr) const {
|
|||||||
ReturnValue_t HeaterHandler::getFuseState(uint8_t fuseNr) const { return 0; }
|
ReturnValue_t HeaterHandler::getFuseState(uint8_t fuseNr) const { return 0; }
|
||||||
|
|
||||||
uint32_t HeaterHandler::getSwitchDelayMs(void) const { return 2000; }
|
uint32_t HeaterHandler::getSwitchDelayMs(void) const { return 2000; }
|
||||||
|
|
||||||
|
HasHealthIF::HealthState HeaterHandler::getHealth(heater::Switchers heater) {
|
||||||
|
auto* healthDev = heaterVec.at(heater).healthDevice;
|
||||||
|
if (healthDev != nullptr) {
|
||||||
|
MutexGuard mg(heaterMutex);
|
||||||
|
return healthDev->getHealth();
|
||||||
|
}
|
||||||
|
return HasHealthIF::HealthState::FAULTY;
|
||||||
|
}
|
||||||
|
@ -68,6 +68,8 @@ class HeaterHandler : public ExecutableObjectIF,
|
|||||||
enum SwitchAction : uint8_t { SET_SWITCH_OFF, SET_SWITCH_ON, NONE };
|
enum SwitchAction : uint8_t { SET_SWITCH_OFF, SET_SWITCH_ON, NONE };
|
||||||
|
|
||||||
ReturnValue_t switchHeater(heater::Switchers heater, SwitchState switchState);
|
ReturnValue_t switchHeater(heater::Switchers heater, SwitchState switchState);
|
||||||
|
HasHealthIF::HealthState getHealth(heater::Switchers heater);
|
||||||
|
|
||||||
ReturnValue_t performOperation(uint8_t operationCode = 0) override;
|
ReturnValue_t performOperation(uint8_t operationCode = 0) override;
|
||||||
|
|
||||||
ReturnValue_t sendSwitchCommand(uint8_t switchNr, ReturnValue_t onOff) override;
|
ReturnValue_t sendSwitchCommand(uint8_t switchNr, ReturnValue_t onOff) override;
|
||||||
|
Loading…
Reference in New Issue
Block a user