Rev 750 | Details | Compare with Previous | Last modification | View Log | RSS feed
Rev | Author | Line No. | Line |
---|---|---|---|
674 | KeyOz | 1 | /*************************************************************************** |
2 | * Copyright (C) 2009 by Manuel Schrape * |
||
3 | * manuel.schrape@gmx.de * |
||
4 | * * |
||
5 | * This program is free software; you can redistribute it and/or modify * |
||
6 | * it under the terms of the GNU General Public License as published by * |
||
7 | * the Free Software Foundation; either version 2 of the License. * |
||
8 | * * |
||
9 | * This program is distributed in the hope that it will be useful, * |
||
10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of * |
||
11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * |
||
12 | * GNU General Public License for more details. * |
||
13 | * * |
||
14 | * You should have received a copy of the GNU General Public License * |
||
15 | * along with this program; if not, write to the * |
||
16 | * Free Software Foundation, Inc., * |
||
17 | * 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * |
||
18 | ***************************************************************************/ |
||
19 | #ifndef DLG_MAIN_H |
||
20 | #define DLG_MAIN_H |
||
21 | |||
22 | #include <QtGui/QMainWindow> |
||
23 | #include <QtGui/QLineEdit> |
||
24 | #include <QtGui/QCheckBox> |
||
25 | #include <QtGui/QLabel> |
||
26 | #include <QtGui/QFont> |
||
27 | |||
28 | #include <QTcpServer> |
||
29 | #include <QTcpSocket> |
||
30 | |||
31 | #include <qwt_plot_curve.h> |
||
32 | #include <qwt_plot_grid.h> |
||
33 | #include <qwt_legend.h> |
||
34 | #include <qwt_plot.h> |
||
35 | |||
36 | #include "ui_dlg_Main.h" |
||
37 | |||
801 | - | 38 | #include "wgt_Index.h" |
39 | |||
674 | KeyOz | 40 | #include "../Defines.h" |
41 | #include "../TypeDefs.h" |
||
42 | |||
43 | #include "../Classes/cSettings.h" |
||
44 | |||
801 | - | 45 | |
674 | KeyOz | 46 | class dlg_Main : public QMainWindow, public Ui::dlg_Main_UI |
47 | { |
||
48 | Q_OBJECT |
||
49 | |||
50 | public: |
||
51 | dlg_Main(); |
||
52 | ~dlg_Main(); |
||
53 | |||
54 | private: |
||
55 | // Settings-Object |
||
56 | cSettings *o_Settings; |
||
57 | |||
801 | - | 58 | wgt_Index *wg_Index[MAX_DebugData]; |
674 | KeyOz | 59 | |
60 | // Info über die Hardware |
||
750 | KeyOz | 61 | s_Hardware gs_Version; |
674 | KeyOz | 62 | |
63 | // Datenspeicher zum Senden. |
||
64 | char c_Data[150]; |
||
65 | |||
750 | KeyOz | 66 | s_MK_Debug gs_Debug; |
674 | KeyOz | 67 | |
68 | int Debug_Data[MAX_DebugData]; |
||
69 | |||
70 | // Plots für die Analogwerte |
||
71 | QwtPlotCurve *Plot[MAX_DebugData]; |
||
72 | |||
73 | // Datenspeicher für die Plots |
||
74 | double pl_Data[MAX_DebugData][50000]; |
||
75 | double pl_ID[50000]; |
||
76 | int NextPlot; |
||
77 | |||
78 | // Programm-Initialisirungen |
||
79 | void init_GUI(); |
||
80 | void init_Connections(); |
||
81 | void init_Plotter(); |
||
82 | |||
83 | void update_Plotter(); |
||
84 | void config_Plotter(); |
||
85 | |||
86 | private slots: |
||
87 | void slot_ac_About(); |
||
88 | |||
750 | KeyOz | 89 | void slot_ConnectionStatus(int li_Status); |
90 | void slot_MK_Version(s_Hardware ls_Version); |
||
91 | void slot_MK_Debug(s_MK_Debug ls_Debug); |
||
92 | void slot_MK_DebugLabels(s_MK_DebugLabels MK_DebugLabels); |
||
674 | KeyOz | 93 | |
801 | - | 94 | // void slot_ac_Plotter(); |
95 | // void slot_ac_Debug(); |
||
96 | // void slot_ac_Chose(); |
||
674 | KeyOz | 97 | |
98 | void slot_ac_ReadLabels(); |
||
99 | |||
100 | void slot_btn_ChoseOK(); |
||
101 | |||
102 | void slot_Plotter_Start(); |
||
103 | void slot_Plotter_Scroll(int Position); |
||
104 | }; |
||
105 | |||
106 | #endif // DLG_MAIN_H |