Compare commits
23 Commits
24ef96d1b8
...
707a43aba9
Author | SHA1 | Date | |
---|---|---|---|
707a43aba9 | |||
9f6504ab64 | |||
c7b1f305a1 | |||
d2f740bd9c | |||
e4f1f0cbe2 | |||
f1af20a749 | |||
cbd02e7261 | |||
92334add3f | |||
2da0c2aab8 | |||
ece84a0e74 | |||
26d9e359df | |||
3546160cd1 | |||
fe2e395491 | |||
ce8459546e | |||
cec12c0073 | |||
96babff67e | |||
cd3153b464 | |||
28166ee19e | |||
cde987dd35 | |||
0bc050b80a | |||
4e242aa954 | |||
bdddee4f81 | |||
ff5153d011 |
@@ -375,7 +375,7 @@ float MgmLIS3MDLHandler::getSensitivityFactor(MGMLIS3MDL::Sensitivies sens) {
|
||||
|
||||
ReturnValue_t MgmLIS3MDLHandler::enableTemperatureSensor(const uint8_t *commandData,
|
||||
size_t commandDataLen) {
|
||||
if(commandData == nullptr) {
|
||||
if (commandData == nullptr) {
|
||||
return INVALID_COMMAND_PARAMETER;
|
||||
}
|
||||
triggerEvent(CHANGE_OF_SETUP_PARAMETER);
|
||||
|
@@ -620,7 +620,7 @@ class DeviceHandlerBase : public DeviceHandlerIF,
|
||||
* @param[out] numberOfSwitches length of returned array
|
||||
* @return
|
||||
* - @c RETURN_OK if the parameters were set
|
||||
* - @c RETURN_FAILED if no switches exist
|
||||
* - @c RETURN_FAILED or DeviceHandlerBase::NO_SWITCH if no switches exist
|
||||
*/
|
||||
virtual ReturnValue_t getSwitches(const uint8_t **switches, uint8_t *numberOfSwitches);
|
||||
|
||||
|
@@ -18,7 +18,8 @@ class PowerSwitcher : public HasReturnvaluesIF {
|
||||
static const uint8_t INTERFACE_ID = CLASS_ID::POWER_SWITCHER;
|
||||
static const ReturnValue_t IN_POWER_TRANSITION = MAKE_RETURN_CODE(1);
|
||||
static const ReturnValue_t SWITCH_STATE_MISMATCH = MAKE_RETURN_CODE(2);
|
||||
PowerSwitcher(PowerSwitchIF* switcher, uint8_t setSwitch1, uint8_t setSwitch2 = power::NO_SWITCH,
|
||||
PowerSwitcher(PowerSwitchIF* switcher, power::Switch_t setSwitch1,
|
||||
power::Switch_t setSwitch2 = power::NO_SWITCH,
|
||||
State_t setStartState = SWITCH_IS_OFF);
|
||||
void turnOn(bool checkCurrentState = true);
|
||||
void turnOff(bool checkCurrentState = true);
|
||||
|
@@ -138,23 +138,23 @@ ReturnValue_t FixedSlotSequence::checkSequence() const {
|
||||
}
|
||||
|
||||
ReturnValue_t FixedSlotSequence::intializeSequenceAfterTaskCreation() const {
|
||||
std::set<ExecutableObjectIF*> uniqueObjects;
|
||||
uint32_t count = 0;
|
||||
std::set<ExecutableObjectIF*> uniqueObjects = {};
|
||||
uint32_t failedCount = 0;
|
||||
for (const auto& slot : slotList) {
|
||||
// Ensure that each unique object is initialized once.
|
||||
if (uniqueObjects.find(slot.executableObject) == uniqueObjects.end()) {
|
||||
ReturnValue_t result = slot.executableObject->initializeAfterTaskCreation();
|
||||
if (result != HasReturnvaluesIF::RETURN_OK) {
|
||||
count++;
|
||||
failedCount++;
|
||||
}
|
||||
uniqueObjects.emplace(slot.executableObject);
|
||||
}
|
||||
}
|
||||
if (count > 0) {
|
||||
if (failedCount > 0) {
|
||||
#if FSFW_CPP_OSTREAM_ENABLED == 1
|
||||
sif::error << "FixedSlotSequence::intializeSequenceAfterTaskCreation:"
|
||||
"Counted "
|
||||
<< count << " failed initializations!" << std::endl;
|
||||
<< failedCount << " failed initializations" << std::endl;
|
||||
#endif
|
||||
return HasReturnvaluesIF::RETURN_FAILED;
|
||||
}
|
||||
|
Reference in New Issue
Block a user