ClassFlowControll.h 2.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081
  1. #ifndef __FLOWCONTROLL__
  2. #define __FLOWCONTROLL__
  3. #include <string>
  4. #include "ClassFlow.h"
  5. #include "ClassFlowMakeImage.h"
  6. #include "ClassFlowAlignment.h"
  7. #include "ClassFlowCNNGeneral.h"
  8. #include "ClassFlowPostProcessing.h"
  9. #include "ClassFlowMQTT.h"
  10. #include "ClassFlowInfluxDB.h"
  11. #include "ClassFlowCNNGeneral.h"
  12. #include "ClassFlowWriteList.h"
  13. #define READOUT_TYPE_VALUE 0
  14. #define READOUT_TYPE_PREVALUE 1
  15. #define READOUT_TYPE_RAWVALUE 2
  16. #define READOUT_TYPE_ERROR 3
  17. class ClassFlowControll :
  18. public ClassFlow
  19. {
  20. protected:
  21. std::vector<ClassFlow*> FlowControll;
  22. ClassFlowPostProcessing* flowpostprocessing;
  23. ClassFlowAlignment* flowalignment;
  24. ClassFlowCNNGeneral* flowanalog;
  25. ClassFlowCNNGeneral* flowdigit;
  26. // ClassFlowDigit* flowdigit;
  27. ClassFlowMakeImage* flowmakeimage;
  28. ClassFlow* CreateClassFlow(std::string _type);
  29. bool AutoStart;
  30. float AutoIntervall;
  31. bool SetupModeActive;
  32. void SetInitialParameter(void);
  33. std::string aktstatus;
  34. int aktRunNr;
  35. public:
  36. void InitFlow(std::string config);
  37. bool doFlow(string time);
  38. void doFlowMakeImageOnly(string time);
  39. bool getStatusSetupModus(){return SetupModeActive;};
  40. string getReadout(bool _rawvalue, bool _noerror);
  41. string getReadoutAll(int _type);
  42. string UpdatePrevalue(std::string _newvalue, std::string _numbers, bool _extern);
  43. string GetPrevalue(std::string _number = "");
  44. bool ReadParameter(FILE* pfile, string& aktparamgraph);
  45. string getJSON(std::string _id = "", std::string _mac = "");
  46. string TranslateAktstatus(std::string _input);
  47. string GetMQTTMainTopic();
  48. esp_err_t GetJPGStream(std::string _fn, httpd_req_t *req);
  49. esp_err_t SendRawJPG(httpd_req_t *req);
  50. std::string doSingleStep(std::string _stepname, std::string _host);
  51. bool isAutoStart(long &_intervall);
  52. std::string* getActStatus();
  53. std::vector<HTMLInfo*> GetAllDigital();
  54. std::vector<HTMLInfo*> GetAllAnalog();
  55. t_CNNType GetTypeDigital();
  56. t_CNNType GetTypeAnalog();
  57. int CleanTempFolder();
  58. string name(){return "ClassFlowControll";};
  59. };
  60. #endif