Add mapping logic, refactor stuff

This commit is contained in:
2022-09-19 20:02:18 +02:00
parent dccd6f2773
commit f507912623
19 changed files with 275 additions and 187 deletions

23
app/include/Mapping.h Normal file
View File

@@ -0,0 +1,23 @@
#ifndef MAPPING_H_
#define MAPPING_H_
#include <memory>
#include <vector>
#include <fan/Fan.h>
#include <fan/PwmControl.h>
#include <sensor/Sensor.h>
class Mapping {
public:
std::vector<std::shared_ptr<Fan>>
createMapping(std::vector<std::shared_ptr<Sensor>> rpmSensors,
std::vector<std::shared_ptr<PwmControl>> pwmControls);
private:
template <class Printable>
void print(std::string listLabel,
std::vector<std::shared_ptr<Printable>> list);
};
#endif // MAPPING_H_