bugfix in setNormalDataPoolEntriesInvalid
Do not forget to call read and write to actually update the validity state
This commit is contained in:
parent
3250bbf269
commit
e11eabdbcf
@ -1,5 +1,7 @@
|
|||||||
#include "DeviceHandlerBase.h"
|
#include "DeviceHandlerBase.h"
|
||||||
|
|
||||||
|
#include <fsfw/datapool/PoolReadGuard.h>
|
||||||
|
|
||||||
#include "fsfw/datapoollocal/LocalPoolVariable.h"
|
#include "fsfw/datapoollocal/LocalPoolVariable.h"
|
||||||
#include "fsfw/devicehandlers/AcceptsDeviceResponsesIF.h"
|
#include "fsfw/devicehandlers/AcceptsDeviceResponsesIF.h"
|
||||||
#include "fsfw/devicehandlers/DeviceTmReportingWrapper.h"
|
#include "fsfw/devicehandlers/DeviceTmReportingWrapper.h"
|
||||||
@ -1524,9 +1526,12 @@ DeviceCommandId_t DeviceHandlerBase::getPendingCommand() const {
|
|||||||
void DeviceHandlerBase::setNormalDatapoolEntriesInvalid() {
|
void DeviceHandlerBase::setNormalDatapoolEntriesInvalid() {
|
||||||
for (const auto& reply : deviceReplyMap) {
|
for (const auto& reply : deviceReplyMap) {
|
||||||
if (reply.second.dataSet != nullptr) {
|
if (reply.second.dataSet != nullptr) {
|
||||||
|
PoolReadGuard pg(reply.second.dataSet);
|
||||||
|
if (pg.getReadResult() == returnvalue::OK) {
|
||||||
reply.second.dataSet->setValidity(false, true);
|
reply.second.dataSet->setValidity(false, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void DeviceHandlerBase::printWarningOrError(sif::OutputTypes errorType, const char* functionName,
|
void DeviceHandlerBase::printWarningOrError(sif::OutputTypes errorType, const char* functionName,
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
|
|
||||||
namespace addresses {
|
namespace addresses {
|
||||||
/* Logical addresses have uint32_t datatype */
|
/* Logical addresses have uint32_t datatype */
|
||||||
enum logicalAddresses : address_t {};
|
enum LogicAddress : address_t {};
|
||||||
} // namespace addresses
|
} // namespace addresses
|
||||||
|
|
||||||
#endif /* CONFIG_DEVICES_LOGICALADDRESSES_H_ */
|
#endif /* CONFIG_DEVICES_LOGICALADDRESSES_H_ */
|
||||||
|
Loading…
Reference in New Issue
Block a user