summaryrefslogtreecommitdiffstats
path: root/src/knutconst.h
blob: 866fe5d60d496d2e36bf5fcc801712519404ca20 (plain)
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
50
51
52
53
54
55
56
57
58
/***************************************************************************
                          knutconst.h  -  description
                             -------------------
    begin                : Tue Sep 24 2001
    copyright            : (C) 2003 by Daniel Prynych
    email                : [email protected]
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This program is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU General Public License as published by  *
 *   the Free Software Foundation; either version 2 of the License, or     *
 *   (at your option) any later version.                                   *
 *                                                                         *
 ***************************************************************************/

#ifndef KNUTCONST_H
#define KNUTCONST_H


namespace knc {

  const int StartPort =1024;
  const int StopPort= 65535;
  const int MinDelay = 2000;

  const int MinCols = 1;
  const int MaxCols = 5;

  const int DefaultCountCols = 3; // prednastaveny pocet sloupcu analogovych meraku
  const int DefaultPort = 3493;  // default ports - prednastaveny port

  const int DefaultDelay = 2000; //2000 msec

  const int DefaultInputVoltage = 230;
  const int DefaultInputFrequency = 50;

  const int NumberOfTypes = 14; // count types of variables //  pocet typu promenych (none,utility ....)
  const int NumberOfVars = NumberOfTypes -1; // how many variables we can measure //  kolik promenych muzeme merit 

  enum {VarNone,VarUtility,VarBattPct,VarUpsTemp,VarAcfreq,VarLoadPct,VarAmbTemp,VarAmbHumid,VarBattVolt,VarOutVolt,VarCurrent,VarOutFreq,VarBattTemp,VarBattCurrent};

  const unsigned int maxCountKNutEvent = 100;

  const int numberVarError = -1000;

  enum upsDriverConnection {  // state of connection to usbd, this isn't state of knutnet 
    connecting,
    connected,
    stale,
    notConnected,
    error
    };
  }


#endif