1
0
forked from fsfw/fsfw

DataSetBase not bound to max size anymore

This commit is contained in:
2020-07-02 16:54:53 +02:00
parent 3e069c34aa
commit 099e6281ec
8 changed files with 58 additions and 15 deletions

View File

@ -2,7 +2,9 @@
#include <framework/datapoolglob/GlobalDataSet.h>
#include <framework/serviceinterface/ServiceInterfaceStream.h>
GlobDataSet::GlobDataSet(): DataSetBase() {}
GlobDataSet::GlobDataSet(): DataSetBase(
reinterpret_cast<PoolVariableIF**>(&registeredVariables),
DATA_SET_MAX_SIZE) {}
// Don't do anything with your variables, they are dead already!
// (Destructor is already called)

View File

@ -61,6 +61,10 @@ public:
*/
void setEntriesValid(bool valid);
//!< This definition sets the maximum number of variables to
//! register in one DataSet.
static const uint8_t DATA_SET_MAX_SIZE = 63;
private:
/**
* If the valid state of a dataset is always relevant to the whole
@ -85,6 +89,8 @@ private:
void handleAlreadyReadDatasetCommit();
ReturnValue_t handleUnreadDatasetCommit();
PoolVariableIF* registeredVariables[DATA_SET_MAX_SIZE];
};
#endif /* DATASET_H_ */