Lightweight data components for HAPI and embedded systems.
Provides owned values, references, ranges, defaults and change tracking with zero runtime overhead.
Data<T>— owned runtime dataDataRef<T&>— reference to external variableText/TextRef— string handlingWatch<>— automatic change detectionNumRange<>/StaticNumRange<>— value limiting and steppingDefault<T>— default value injection- Full CRTP /
APIOf/Chaincompatibility
#include "oneData.h"
using namespace oneData;
int value = 42;
Text label = "Status";
auto volume = DataDef<Watch,Int&>{value};//will detect changes (watch) on external var
auto power = DataDef<Watch,Int>{60};//own data, watch for changes
if (volume.changed()) {
// ...
volume.sync();//clear changed, prepare for next change
}