32 lines
524 B
C++
32 lines
524 B
C++
#ifndef DATALOGGER_H
|
|
#define DATALOGGER_H
|
|
|
|
#include <Arduino.h>
|
|
#include <vector>
|
|
#include <map>
|
|
|
|
struct DataEntry {
|
|
std::map<String, String> values;
|
|
};
|
|
|
|
struct Config {
|
|
String parameter;
|
|
String value;
|
|
};
|
|
|
|
class Datalogger {
|
|
public:
|
|
Datalogger();
|
|
|
|
void addData(const std::map<String, String>& data);
|
|
void addConfig(String parameter, String value);
|
|
void logToSerial();
|
|
void clear();
|
|
|
|
private:
|
|
std::vector<DataEntry> dataEntries;
|
|
std::vector<Config> configs;
|
|
};
|
|
|
|
#endif // DATALOGGER_H
|