Blame view

app/gui/oven_control/ovenstatics.h 1.12 KB
652e9cd54   고영탁   Merge
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
  #ifndef OVENSTATICS_H
  #define OVENSTATICS_H
  
  #include <QObject>
  #include <time.h>
  #include "all_share.h"
  #include "udphandler.h"
  #include "oven.h"
  #include "servicedatas.h"
  
  
  #define SYS_ERR_FIRE_TRIGGER1               0x0001
  #define SYS_ERR_FIRE_TRIGGER2               0x0002
  #define SYS_ERR_FIRE_TRIGGER3               0x0004
  #define SYS_ERR_OVNE_TEMP_ALARM     0x0008
  #define SYS_ERR_QUN_TEMP_ALARM       0x0010
  #define SYS_ERR_CENTER_TEMP_ALARM  0x0020
  #define SYS_ERR_WALL_TEMP_ALARM      0x0040
  #define SYS_ERR_WATER_SPLY_FAIL           0x0080
  
  
  
  class OvenStatics : public QObject
  {
      Q_OBJECT
  public:
      static OvenStatics* getInstance(QObject* parent = 0,UdpHandler * udp=0, Oven* oven=0);
      static void destroy();
  
  
  private:
      static OvenStatics* p_singtonInstance;
      UdpHandler *udp;
      Oven* oven;
      oven_control_t control;
      oven_state_t state;
      servicedatas* srvdatas;
  
  
      bool curdoorstate;
      uint16_t curSysErrorState;
      explicit OvenStatics(QObject* parent);
      ~OvenStatics();
      void processSystemError(uint16_t errflag,time_t ltime);
  public slots:
      void onDataChanged();
  };
  
  #endif // OVENSTATICS_H