diff --git a/app/gui/oven_control/engineermenuwindow.cpp b/app/gui/oven_control/engineermenuwindow.cpp index b883649..845e9cc 100644 --- a/app/gui/oven_control/engineermenuwindow.cpp +++ b/app/gui/oven_control/engineermenuwindow.cpp @@ -6,9 +6,9 @@ #include "functiontestwindow.h" #include "ovenstatics.h" -engineermenuwindow::engineermenuwindow(QWidget *parent) : +EngineerMenuWindow::EngineerMenuWindow(QWidget *parent) : QMainWindow(parent), - ui(new Ui::engineermenuwindow) + ui(new Ui::EngineerMenuWindow) { ui->setupUi(this); @@ -19,33 +19,33 @@ engineermenuwindow::engineermenuwindow(QWidget *parent) : } -engineermenuwindow::~engineermenuwindow() +EngineerMenuWindow::~EngineerMenuWindow() { delete ui; } -void engineermenuwindow::on_servicehistorybutton_clicked() +void EngineerMenuWindow::on_serviceHistoryButton_clicked() { - serviceHistoryMain *w = new serviceHistoryMain(this); + ServiceHistoryMain *w = new ServiceHistoryMain(this); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); } -void engineermenuwindow::on_operationtimebutton_clicked() +void EngineerMenuWindow::on_operationTimeButton_clicked() { - operationTimeMain *w = new operationTimeMain(this); + OperationTimeMain *w = new OperationTimeMain(this); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); } -void engineermenuwindow::on_realdatabutton_clicked() +void EngineerMenuWindow::on_realDataButton_clicked() { - realtimeMain* w = new realtimeMain(this); + RealtimeMain* w = new RealtimeMain(this); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); } -void engineermenuwindow::on_functiontestbutton_clicked() +void EngineerMenuWindow::on_functionTestButton_clicked() { FunctionTestWindow *w = new FunctionTestWindow(this); w->setWindowModality(Qt::WindowModal); diff --git a/app/gui/oven_control/engineermenuwindow.h b/app/gui/oven_control/engineermenuwindow.h index be7a2ec..1f208bb 100644 --- a/app/gui/oven_control/engineermenuwindow.h +++ b/app/gui/oven_control/engineermenuwindow.h @@ -4,28 +4,28 @@ #include namespace Ui { -class engineermenuwindow; +class EngineerMenuWindow; } -class engineermenuwindow : public QMainWindow +class EngineerMenuWindow : public QMainWindow { Q_OBJECT public: - explicit engineermenuwindow(QWidget *parent = 0); - ~engineermenuwindow(); + explicit EngineerMenuWindow(QWidget *parent = 0); + ~EngineerMenuWindow(); private slots: - void on_servicehistorybutton_clicked(); + void on_serviceHistoryButton_clicked(); - void on_operationtimebutton_clicked(); + void on_operationTimeButton_clicked(); - void on_realdatabutton_clicked(); + void on_realDataButton_clicked(); - void on_functiontestbutton_clicked(); + void on_functionTestButton_clicked(); private: - Ui::engineermenuwindow *ui; + Ui::EngineerMenuWindow *ui; }; #endif // ENGINEERMENUWINDOW_H diff --git a/app/gui/oven_control/engineermenuwindow.ui b/app/gui/oven_control/engineermenuwindow.ui index 287973c..b35cf21 100644 --- a/app/gui/oven_control/engineermenuwindow.ui +++ b/app/gui/oven_control/engineermenuwindow.ui @@ -1,7 +1,7 @@ - engineermenuwindow - + EngineerMenuWindow + 0 @@ -116,7 +116,7 @@ QPushButton:pressed { border-image: url(:/images/bottom_bar/back_ov.png); }0 - + 0 @@ -186,7 +186,7 @@ QPushButton { text-align: left;} 0 - + 0 @@ -255,7 +255,7 @@ QPushButton { text-align: left;} 0 - + 0 @@ -324,7 +324,7 @@ QPushButton { color: rgb(255, 255, 255);text-align: left;} 0 - + 0 @@ -393,7 +393,7 @@ QPushButton {color: rgb(255, 255, 255); text-align: left;} 0 - + 0 @@ -461,7 +461,7 @@ QPushButton:pressed { border-image: url(:/images/config/pannel_ov.png); }QPushBu 0 - + 0 @@ -529,7 +529,7 @@ QPushButton:pressed { border-image: url(:/images/config/pannel_ov.png); }QPushBu 0 - + 0 diff --git a/app/gui/oven_control/errorpopupdlg.cpp b/app/gui/oven_control/errorpopupdlg.cpp index be00abc..9c1be5c 100644 --- a/app/gui/oven_control/errorpopupdlg.cpp +++ b/app/gui/oven_control/errorpopupdlg.cpp @@ -1,9 +1,9 @@ #include "errorpopupdlg.h" #include "ui_errorpopupdlg.h" -errorPopupDlg::errorPopupDlg(QWidget *parent, const QString &MsgDesc, const QString &MsgTitle) : +ErrorPopupDlg::ErrorPopupDlg(QWidget *parent, const QString &MsgDesc, const QString &MsgTitle) : QDialog(parent), - ui(new Ui::errorPopupDlg) + ui(new Ui::ErrorPopupDlg) { ui->setupUi(this); this->setAttribute( Qt::WA_TranslucentBackground); @@ -15,12 +15,12 @@ errorPopupDlg::errorPopupDlg(QWidget *parent, const QString &MsgDesc, const QStr ui->ctrlWarnTitle->setText(MsgTitle); } -errorPopupDlg::~errorPopupDlg() +ErrorPopupDlg::~ErrorPopupDlg() { delete ui; } -void errorPopupDlg::on_ctrlOkBtn_clicked() +void ErrorPopupDlg::on_ctrlOkBtn_clicked() { close(); } diff --git a/app/gui/oven_control/errorpopupdlg.h b/app/gui/oven_control/errorpopupdlg.h index 1dc8b16..7152f36 100644 --- a/app/gui/oven_control/errorpopupdlg.h +++ b/app/gui/oven_control/errorpopupdlg.h @@ -4,22 +4,22 @@ #include namespace Ui { -class errorPopupDlg; +class ErrorPopupDlg; } -class errorPopupDlg : public QDialog +class ErrorPopupDlg : public QDialog { Q_OBJECT public: - explicit errorPopupDlg(QWidget *parent = 0, const QString &MsgDesc=0, const QString &MsgTitle=0); - ~errorPopupDlg(); + explicit ErrorPopupDlg(QWidget *parent = 0, const QString &MsgDesc=0, const QString &MsgTitle=0); + ~ErrorPopupDlg(); private slots: void on_ctrlOkBtn_clicked(); private: - Ui::errorPopupDlg *ui; + Ui::ErrorPopupDlg *ui; }; #endif // ERRORPOPUPDLG_H diff --git a/app/gui/oven_control/errorpopupdlg.ui b/app/gui/oven_control/errorpopupdlg.ui index 986a9e8..d544361 100644 --- a/app/gui/oven_control/errorpopupdlg.ui +++ b/app/gui/oven_control/errorpopupdlg.ui @@ -1,7 +1,7 @@ - errorPopupDlg - + ErrorPopupDlg + 0 diff --git a/app/gui/oven_control/historylistwindow.cpp b/app/gui/oven_control/historylistwindow.cpp index 5af755c..b0661a6 100644 --- a/app/gui/oven_control/historylistwindow.cpp +++ b/app/gui/oven_control/historylistwindow.cpp @@ -8,9 +8,9 @@ -historyListWindow::historyListWindow(QWidget *parent) : +HistoryListWindow::HistoryListWindow(QWidget *parent) : QMainWindow(parent), - ui(new Ui::historyListWindow) + ui(new Ui::HistoryListWindow) { ui->setupUi(this); @@ -64,17 +64,17 @@ historyListWindow::historyListWindow(QWidget *parent) : m_nWindowType = ERROR_HISTORY_UPPERBUNNER; } -historyListWindow::~historyListWindow() +HistoryListWindow::~HistoryListWindow() { delete ui; } -void historyListWindow::on_ctrlBtnBack_clicked() +void HistoryListWindow::on_ctrlBtnBack_clicked() { deleteLater(); } -void historyListWindow::reloadDataset(void){ +void HistoryListWindow::reloadDataset(void){ int i = 0; QString strPrefix = tr("에러"); QString strTemp = ""; @@ -115,7 +115,7 @@ void historyListWindow::reloadDataset(void){ } } -void historyListWindow::setUpperBunnerDataSet(void){ +void HistoryListWindow::setUpperBunnerDataSet(void){ OvenStatistics *ovenst = OvenStatistics::getInstance(); m_nCurDpStartPos = 0; m_nCurSelPos = 0; @@ -125,13 +125,13 @@ void historyListWindow::setUpperBunnerDataSet(void){ strName.append(tr(m_strWindowName[ERROR_HISTORY_UPPERBUNNER ])); m_ctrlErrorNameLabel->setText(strName); for(i=0;isrvdatas->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_UPPERBUNNER][i]]); + err_items[i] = &(ovenst->srvdata->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_UPPERBUNNER][i]]); } reloadDataset(); } } -void historyListWindow::setSteamBunnerDataSet(void){ +void HistoryListWindow::setSteamBunnerDataSet(void){ OvenStatistics *ovenst = OvenStatistics::getInstance(); m_nCurDpStartPos = 0; m_nCurSelPos = 0; @@ -141,13 +141,13 @@ void historyListWindow::setSteamBunnerDataSet(void){ strName.append(tr(m_strWindowName[ERROR_HISTORY_STEAMBUNNER ])); m_ctrlErrorNameLabel->setText(strName); for(i=0;isrvdatas->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_STEAMBUNNER][i]]); + err_items[i] = &(ovenst->srvdata->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_STEAMBUNNER][i]]); } reloadDataset(); } } -void historyListWindow::setLowerBunnerDataSet(void){ +void HistoryListWindow::setLowerBunnerDataSet(void){ OvenStatistics *ovenst = OvenStatistics::getInstance(); m_nCurDpStartPos = 0; m_nCurSelPos = 0; @@ -157,13 +157,13 @@ void historyListWindow::setLowerBunnerDataSet(void){ strName.append(tr(m_strWindowName[ERROR_HISTORY_LOWERBUNNER ])); m_ctrlErrorNameLabel->setText(strName); for(i=0;isrvdatas->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_LOWERBUNNER][i]]); + err_items[i] = &(ovenst->srvdata->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_LOWERBUNNER][i]]); } reloadDataset(); } } -void historyListWindow::setTotalServiceDataSet(void){ +void HistoryListWindow::setTotalServiceDataSet(void){ int i = 0; error_item *item; time_t firsttimebuf=0,lasttimebuf=0; @@ -174,7 +174,7 @@ void historyListWindow::setTotalServiceDataSet(void){ m_ctrlErrorNameLabel->setText(strName); //01 상부 점화 장치 데이터 초기화 for(i=0;isrvdatas->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_UPPERBUNNER][i]]); + item = &(ovenst->srvdata->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_UPPERBUNNER][i]]); if(i==0) {firsttimebuf = item->first_fired;lasttimebuf = item->last_fried;firecntbuf=item->fired_cnt;} else{ if( firsttimebuf > item->first_fired && item->first_fired != 0 ) firsttimebuf = item->first_fired; @@ -190,7 +190,7 @@ void historyListWindow::setTotalServiceDataSet(void){ //02 스팀 점화 장치 데이터 초기화 firecntbuf = 0;firsttimebuf = 0; lasttimebuf=0; for(i=0;isrvdatas->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_STEAMBUNNER][i]]); + item = &(ovenst->srvdata->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_STEAMBUNNER][i]]); if(i==0) {firsttimebuf = item->first_fired;lasttimebuf = item->last_fried;firecntbuf=item->fired_cnt;} else{ if( firsttimebuf > item->first_fired && item->first_fired != 0 ) firsttimebuf = item->first_fired; @@ -204,7 +204,7 @@ void historyListWindow::setTotalServiceDataSet(void){ //03 하부 점화 장치 데이터 초기화 firecntbuf = 0;firsttimebuf = 0; lasttimebuf=0; for(i=0;isrvdatas->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_LOWERBUNNER][i]]); + item = &(ovenst->srvdata->err_log.values[m_arrErrorIdxs[ERROR_HISTORY_LOWERBUNNER][i]]); if(i==0) {firsttimebuf = item->first_fired;lasttimebuf = item->last_fried;firecntbuf=item->fired_cnt;} else{ if( firsttimebuf > item->first_fired && item->first_fired != 0 ) firsttimebuf = item->first_fired; @@ -218,9 +218,9 @@ void historyListWindow::setTotalServiceDataSet(void){ //04 WATER firecntbuf = 0;firsttimebuf = 0; lasttimebuf=0; - item = &(ovenst->srvdatas->err_log.items.inner_temp_fail); + item = &(ovenst->srvdata->err_log.items.inner_temp_fail); firsttimebuf = item->first_fired;lasttimebuf = item->last_fried;firecntbuf=item->fired_cnt; - item = &(ovenst->srvdatas->err_log.items.qunching_temp_fail); + item = &(ovenst->srvdata->err_log.items.qunching_temp_fail); if( firsttimebuf > item->first_fired && item->first_fired != 0 ) firsttimebuf = item->first_fired; if( lasttimebuf < item->last_fried ) lasttimebuf = item->last_fried; firecntbuf += item->fired_cnt; @@ -244,7 +244,7 @@ void historyListWindow::setTotalServiceDataSet(void){ //07 B1 센서 에러 firecntbuf = 0;firsttimebuf = 0; lasttimebuf=0; - item = &(ovenst->srvdatas->err_log.items.inner_temp_high_alarm); + item = &(ovenst->srvdata->err_log.items.inner_temp_high_alarm); firsttimebuf = item->first_fired;lasttimebuf = item->last_fried;firecntbuf=item->fired_cnt; total_items[5].fired_cnt = firecntbuf; total_items[5].first_fired = firsttimebuf; @@ -252,7 +252,7 @@ void historyListWindow::setTotalServiceDataSet(void){ //08 B2 센서 에러 firecntbuf = 0;firsttimebuf = 0; lasttimebuf=0; - item = &(ovenst->srvdatas->err_log.items.qunching_temp_high_alarm); + item = &(ovenst->srvdata->err_log.items.qunching_temp_high_alarm); firsttimebuf = item->first_fired;lasttimebuf = item->last_fried;firecntbuf=item->fired_cnt; total_items[6].fired_cnt = firecntbuf; total_items[6].first_fired = firsttimebuf; @@ -260,7 +260,7 @@ void historyListWindow::setTotalServiceDataSet(void){ //09 B3 센서 에러 firecntbuf = 0;firsttimebuf = 0; lasttimebuf=0; - item = &(ovenst->srvdatas->err_log.items.meatprove_temp1_high_alarm); + item = &(ovenst->srvdata->err_log.items.meatprove_temp1_high_alarm); firsttimebuf = item->first_fired;lasttimebuf = item->last_fried;firecntbuf=item->fired_cnt; total_items[7].fired_cnt = firecntbuf; total_items[7].first_fired = firsttimebuf; @@ -268,7 +268,7 @@ void historyListWindow::setTotalServiceDataSet(void){ //10 B4 센서 에러 firecntbuf = 0;firsttimebuf = 0; lasttimebuf=0; - item = &(ovenst->srvdatas->err_log.items.wall_temp1_high_alarm); + item = &(ovenst->srvdata->err_log.items.wall_temp1_high_alarm); firsttimebuf = item->first_fired;lasttimebuf = item->last_fried;firecntbuf=item->fired_cnt; total_items[8].fired_cnt = firecntbuf; total_items[8].first_fired = firsttimebuf; @@ -276,7 +276,7 @@ void historyListWindow::setTotalServiceDataSet(void){ //11 B5 센서 에러 firecntbuf = 0;firsttimebuf = 0; lasttimebuf=0; - item = &(ovenst->srvdatas->err_log.items.steam_gen_temp_high_alram); + item = &(ovenst->srvdata->err_log.items.steam_gen_temp_high_alram); firsttimebuf = item->first_fired;lasttimebuf = item->last_fried;firecntbuf=item->fired_cnt; total_items[9].fired_cnt = firecntbuf; total_items[9].first_fired = firsttimebuf; @@ -284,7 +284,7 @@ void historyListWindow::setTotalServiceDataSet(void){ //12 수위센 firecntbuf = 0;firsttimebuf = 0; lasttimebuf=0; - item = &(ovenst->srvdatas->err_log.items.water_level_sensor_fail); + item = &(ovenst->srvdata->err_log.items.water_level_sensor_fail); firsttimebuf = item->first_fired;lasttimebuf = item->last_fried;firecntbuf=item->fired_cnt; total_items[10].fired_cnt = firecntbuf; total_items[10].first_fired = firsttimebuf; @@ -297,7 +297,7 @@ void historyListWindow::setTotalServiceDataSet(void){ reloadDataset(); } -void historyListWindow::setWindosDataSet(ERROR_HISTORY_TYPE type){ +void HistoryListWindow::setWindosDataSet(ERROR_HISTORY_TYPE type){ switch((uint16_t)type){ case ERROR_HISTORY_UPPERBUNNER: m_nWindowType = ERROR_HISTORY_UPPERBUNNER; @@ -318,12 +318,12 @@ void historyListWindow::setWindosDataSet(ERROR_HISTORY_TYPE type){ } } -void historyListWindow::on_ctrlBackBtn_clicked() +void HistoryListWindow::on_ctrlBackBtn_clicked() { deleteLater(); } -void historyListWindow::on_ctrlUpBtn_clicked() +void HistoryListWindow::on_ctrlUpBtn_clicked() { if(m_nCurDpStartPos == 8 && m_arrErrorMaxIdx[m_nWindowType] > 8 ){ m_nCurDpStartPos = 0; @@ -331,7 +331,7 @@ void historyListWindow::on_ctrlUpBtn_clicked() } } -void historyListWindow::on_ctrflDownBtn_clicked() +void HistoryListWindow::on_ctrflDownBtn_clicked() { if(m_nCurDpStartPos == 0 && m_arrErrorMaxIdx[m_nWindowType] > 8){ m_nCurDpStartPos = 8; @@ -339,16 +339,16 @@ void historyListWindow::on_ctrflDownBtn_clicked() } } -void historyListWindow::on_ctrlResetBtn_clicked() +void HistoryListWindow::on_ctrlResetBtn_clicked() { int i = 0; OvenStatistics *ovenst = OvenStatistics::getInstance(); for(i=0;isrvdatas->err_log.values[i].fired_cnt = 0; - ovenst->srvdatas->err_log.values[i].first_fired = 0; - ovenst->srvdatas->err_log.values[i].last_fried = 0; + ovenst->srvdata->err_log.values[i].fired_cnt = 0; + ovenst->srvdata->err_log.values[i].first_fired = 0; + ovenst->srvdata->err_log.values[i].last_fried = 0; } - ovenst->srvdatas->saveServiceDatas(); + ovenst->srvdata->saveServiceData(); setWindosDataSet(m_nWindowType); } diff --git a/app/gui/oven_control/historylistwindow.h b/app/gui/oven_control/historylistwindow.h index a7f5639..918df03 100644 --- a/app/gui/oven_control/historylistwindow.h +++ b/app/gui/oven_control/historylistwindow.h @@ -3,11 +3,11 @@ #include #include -#include "servicedatas.h" +#include "servicedata.h" #include namespace Ui { -class historyListWindow; +class HistoryListWindow; } #define MAX_DISP_ITEM 10 @@ -21,13 +21,13 @@ enum ERROR_HISTORY_TYPE{ -class historyListWindow : public QMainWindow +class HistoryListWindow : public QMainWindow { Q_OBJECT public: - explicit historyListWindow(QWidget *parent = 0); - ~historyListWindow(); + explicit HistoryListWindow(QWidget *parent = 0); + ~HistoryListWindow(); void setWindosDataSet(ERROR_HISTORY_TYPE type); private slots: @@ -42,7 +42,7 @@ private slots: void on_ctrlResetBtn_clicked(); private: - Ui::historyListWindow *ui; + Ui::HistoryListWindow *ui; const uint8_t m_arrErrorMaxIdx[4] = {3,4,3,11}; diff --git a/app/gui/oven_control/historylistwindow.ui b/app/gui/oven_control/historylistwindow.ui index 0f48f4a..59962d2 100644 --- a/app/gui/oven_control/historylistwindow.ui +++ b/app/gui/oven_control/historylistwindow.ui @@ -1,7 +1,7 @@ - historyListWindow - + HistoryListWindow + 0 diff --git a/app/gui/oven_control/mainwindow.cpp b/app/gui/oven_control/mainwindow.cpp index 8c99182..cabb4bf 100644 --- a/app/gui/oven_control/mainwindow.cpp +++ b/app/gui/oven_control/mainwindow.cpp @@ -101,7 +101,7 @@ void MainWindow::on_washButton_clicked() void MainWindow::on_configButton_clicked() { - engineermenuwindow *w = new engineermenuwindow(this); + EngineerMenuWindow *w = new EngineerMenuWindow(this); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); w->raise(); diff --git a/app/gui/oven_control/operationtimeheat.cpp b/app/gui/oven_control/operationtimeheat.cpp index c8e9668..f5e7a68 100644 --- a/app/gui/oven_control/operationtimeheat.cpp +++ b/app/gui/oven_control/operationtimeheat.cpp @@ -2,61 +2,61 @@ #include "ui_operationtimeheat.h" #include "ovenstatics.h" -operationTimeHeat::operationTimeHeat(QWidget *parent) : +OperationTimeHeat::OperationTimeHeat(QWidget *parent) : QMainWindow(parent), - ui(new Ui::operationTimeHeat) + ui(new Ui::OperationTimeHeat) { ui->setupUi(this); reloadUI(); } -operationTimeHeat::~operationTimeHeat() +OperationTimeHeat::~OperationTimeHeat() { delete ui; } -void operationTimeHeat::on_btnReset1_clicked() +void OperationTimeHeat::on_btnReset1_clicked() { //스팀 가열 시간 초기화 OvenStatistics* ovs = OvenStatistics::getInstance(); if(ovs!=NULL){ - ovs->srvdatas->use_log.items.steam_heat=0; - ovs->srvdatas->saveServiceDatas(); + ovs->srvdata->use_log.items.steam_heat=0; + ovs->srvdata->saveServiceData(); reloadUI(); } } -void operationTimeHeat::on_btnReset2_clicked() +void OperationTimeHeat::on_btnReset2_clicked() { //건열 가열 시간 초기화 OvenStatistics* ovs = OvenStatistics::getInstance(); if(ovs!=NULL){ - ovs->srvdatas->use_log.items.dry_heat=0; - ovs->srvdatas->use_log.items.upper_heat=0; - ovs->srvdatas->use_log.items.lower_heat=0; - ovs->srvdatas->saveServiceDatas(); + ovs->srvdata->use_log.items.dry_heat=0; + ovs->srvdata->use_log.items.upper_heat=0; + ovs->srvdata->use_log.items.lower_heat=0; + ovs->srvdata->saveServiceData(); reloadUI(); } } -void operationTimeHeat::reloadUI(void){ +void OperationTimeHeat::reloadUI(void){ uint32_t timetemp; OvenStatistics* ovs = OvenStatistics::getInstance(); QString strTemp=""; if(ovs!=NULL){ - timetemp = ovs->srvdatas->use_log.items.steam_heat; + timetemp = ovs->srvdata->use_log.items.steam_heat; strTemp.sprintf("%d h", timetemp/3600); ui->m_ctrlLbListTime1->setText(strTemp); - timetemp = ovs->srvdatas->use_log.items.dry_heat; + timetemp = ovs->srvdata->use_log.items.dry_heat; strTemp.sprintf("%d h", timetemp/3600); ui->m_ctrlLbListTime2->setText(strTemp); - qDebug() << "Steam heat time : " << ovs->srvdatas->use_log.items.steam_heat; - qDebug() << "Dry heat time : " << ovs->srvdatas->use_log.items.dry_heat; + qDebug() << "Steam heat time : " << ovs->srvdata->use_log.items.steam_heat; + qDebug() << "Dry heat time : " << ovs->srvdata->use_log.items.dry_heat; } } -void operationTimeHeat::on_backButton_clicked() +void OperationTimeHeat::on_backButton_clicked() { deleteLater(); } diff --git a/app/gui/oven_control/operationtimeheat.h b/app/gui/oven_control/operationtimeheat.h index eb3c574..76feb95 100644 --- a/app/gui/oven_control/operationtimeheat.h +++ b/app/gui/oven_control/operationtimeheat.h @@ -4,16 +4,16 @@ #include namespace Ui { -class operationTimeHeat; +class OperationTimeHeat; } -class operationTimeHeat : public QMainWindow +class OperationTimeHeat : public QMainWindow { Q_OBJECT public: - explicit operationTimeHeat(QWidget *parent = 0); - ~operationTimeHeat(); + explicit OperationTimeHeat(QWidget *parent = 0); + ~OperationTimeHeat(); private slots: void on_btnReset1_clicked(); @@ -23,7 +23,7 @@ private slots: void on_backButton_clicked(); private: - Ui::operationTimeHeat *ui; + Ui::OperationTimeHeat *ui; void reloadUI(void); }; diff --git a/app/gui/oven_control/operationtimeheat.ui b/app/gui/oven_control/operationtimeheat.ui index a210ea0..35ef441 100644 --- a/app/gui/oven_control/operationtimeheat.ui +++ b/app/gui/oven_control/operationtimeheat.ui @@ -1,7 +1,7 @@ - operationTimeHeat - + OperationTimeHeat + 0 diff --git a/app/gui/oven_control/operationtimemain.cpp b/app/gui/oven_control/operationtimemain.cpp index 2321bff..4299f6e 100644 --- a/app/gui/oven_control/operationtimemain.cpp +++ b/app/gui/oven_control/operationtimemain.cpp @@ -4,40 +4,40 @@ #include "operationtimemode.h" #include "operationtimeparts.h" -operationTimeMain::operationTimeMain(QWidget *parent) : +OperationTimeMain::OperationTimeMain(QWidget *parent) : QMainWindow(parent), - ui(new Ui::operationTimeMain) + ui(new Ui::OperationTimeMain) { ui->setupUi(this); } -operationTimeMain::~operationTimeMain() +OperationTimeMain::~OperationTimeMain() { delete ui; } -void operationTimeMain::on_btnHeatPartTime_clicked() +void OperationTimeMain::on_btnHeatPartTime_clicked() { - operationTimeHeat* w = new operationTimeHeat(); + OperationTimeHeat* w = new OperationTimeHeat(); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); } -void operationTimeMain::on_btnModeTime_clicked() +void OperationTimeMain::on_btnModeTime_clicked() { - operationTimeMode* w = new operationTimeMode(); + OperationTimeMode* w = new OperationTimeMode(); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); } -void operationTimeMain::on_btnPartsTime_clicked() +void OperationTimeMain::on_btnPartsTime_clicked() { - operationTimeParts*w = new operationTimeParts(); + OperationTimeParts*w = new OperationTimeParts(); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); } -void operationTimeMain::on_backButton_clicked() +void OperationTimeMain::on_backButton_clicked() { deleteLater(); } diff --git a/app/gui/oven_control/operationtimemain.h b/app/gui/oven_control/operationtimemain.h index 9af655b..d4341a7 100644 --- a/app/gui/oven_control/operationtimemain.h +++ b/app/gui/oven_control/operationtimemain.h @@ -4,16 +4,16 @@ #include namespace Ui { -class operationTimeMain; +class OperationTimeMain; } -class operationTimeMain : public QMainWindow +class OperationTimeMain : public QMainWindow { Q_OBJECT public: - explicit operationTimeMain(QWidget *parent = 0); - ~operationTimeMain(); + explicit OperationTimeMain(QWidget *parent = 0); + ~OperationTimeMain(); private slots: void on_btnHeatPartTime_clicked(); @@ -25,7 +25,7 @@ private slots: void on_backButton_clicked(); private: - Ui::operationTimeMain *ui; + Ui::OperationTimeMain *ui; }; #endif // OPERATIONTIMEMAIN_H diff --git a/app/gui/oven_control/operationtimemain.ui b/app/gui/oven_control/operationtimemain.ui index 6d2b810..3680a69 100644 --- a/app/gui/oven_control/operationtimemain.ui +++ b/app/gui/oven_control/operationtimemain.ui @@ -1,7 +1,7 @@ - operationTimeMain - + OperationTimeMain + 0 diff --git a/app/gui/oven_control/operationtimemode.cpp b/app/gui/oven_control/operationtimemode.cpp index d9201fd..902769b 100644 --- a/app/gui/oven_control/operationtimemode.cpp +++ b/app/gui/oven_control/operationtimemode.cpp @@ -2,81 +2,81 @@ #include "ui_operationtimemode.h" #include "ovenstatics.h" -operationTimeMode::operationTimeMode(QWidget *parent) : +OperationTimeMode::OperationTimeMode(QWidget *parent) : QMainWindow(parent), - ui(new Ui::operationTimeMode) + ui(new Ui::OperationTimeMode) { ui->setupUi(this); reloadUi(); } -operationTimeMode::~operationTimeMode() +OperationTimeMode::~OperationTimeMode() { delete ui; } -void operationTimeMode::on_backButton_clicked() +void OperationTimeMode::on_backButton_clicked() { deleteLater(); } -void operationTimeMode::reloadUi(void){ +void OperationTimeMode::reloadUi(void){ uint32_t timetemp; OvenStatistics* ovs = OvenStatistics::getInstance(); QString strTemp=""; uint32_t totaltime; if(ovs!=NULL){ //건열 조리 모드 - timetemp = ovs->srvdatas->use_log.items.cook_dry_mode; + timetemp = ovs->srvdata->use_log.items.cook_dry_mode; totaltime += timetemp; strTemp.sprintf("%d h", timetemp/3600); ui->m_ctrlLbListTime1->setText(strTemp); qDebug() << "Dry Cook Time : " <srvdatas->use_log.items.cook_steam_mode; + timetemp = ovs->srvdata->use_log.items.cook_steam_mode; totaltime += timetemp; strTemp.sprintf("%d h", timetemp/3600); ui->m_ctrlLbListTime2->setText(strTemp); qDebug() << "Steam Cook Time : " <srvdatas->use_log.items.cook_combi_mode; + timetemp = ovs->srvdata->use_log.items.cook_combi_mode; totaltime += timetemp; strTemp.sprintf("%d h", timetemp/3600); ui->m_ctrlLbListTime3->setText(strTemp); qDebug() << "Combi Cook Time : " <srvdatas->use_log.items.wash_mode_nocleanser; + timetemp = ovs->srvdata->use_log.items.wash_mode_nocleanser; totaltime += timetemp; strTemp.sprintf("%d h", timetemp/3600); ui->m_ctrlLbListTime4->setText(strTemp); qDebug() << "Wash Nocleanser Time : " <srvdatas->use_log.items.wash_mode_simple; + timetemp = ovs->srvdata->use_log.items.wash_mode_simple; totaltime += timetemp; strTemp.sprintf("%d h", timetemp/3600); ui->m_ctrlLbListTime5->setText(strTemp); qDebug() << "Wash Simple Time : " <srvdatas->use_log.items.wash_mode_standard; + timetemp = ovs->srvdata->use_log.items.wash_mode_standard; totaltime += timetemp; strTemp.sprintf("%d h", timetemp/3600); ui->m_ctrlLbListTime6->setText(strTemp); qDebug() << "Wash Standard Time : " <srvdatas->use_log.items.wash_mode_strong; + timetemp = ovs->srvdata->use_log.items.wash_mode_strong; totaltime += timetemp; strTemp.sprintf("%d h", timetemp/3600); ui->m_ctrlLbListTime7->setText(strTemp); qDebug() << "Wash Strong Time : " <srvdatas->use_log.items.wash_mode_speed; + timetemp = ovs->srvdata->use_log.items.wash_mode_speed; totaltime += timetemp; strTemp.sprintf("%d h", timetemp/3600); ui->m_ctrlLbListTime8->setText(strTemp); qDebug() << "Wash Speed Time : " <srvdatas->use_log.items.cooldown_mode; + timetemp = ovs->srvdata->use_log.items.cooldown_mode; totaltime += timetemp; strTemp.sprintf("%d h", timetemp/3600); ui->m_ctrlLbListTime9->setText(strTemp); diff --git a/app/gui/oven_control/operationtimemode.h b/app/gui/oven_control/operationtimemode.h index fbcb903..3e6ab68 100644 --- a/app/gui/oven_control/operationtimemode.h +++ b/app/gui/oven_control/operationtimemode.h @@ -4,22 +4,22 @@ #include namespace Ui { -class operationTimeMode; +class OperationTimeMode; } -class operationTimeMode : public QMainWindow +class OperationTimeMode : public QMainWindow { Q_OBJECT public: - explicit operationTimeMode(QWidget *parent = 0); - ~operationTimeMode(); + explicit OperationTimeMode(QWidget *parent = 0); + ~OperationTimeMode(); private slots: void on_backButton_clicked(); private: - Ui::operationTimeMode *ui; + Ui::OperationTimeMode *ui; void reloadUi(void); }; diff --git a/app/gui/oven_control/operationtimemode.ui b/app/gui/oven_control/operationtimemode.ui index bf514cb..facb15f 100644 --- a/app/gui/oven_control/operationtimemode.ui +++ b/app/gui/oven_control/operationtimemode.ui @@ -1,7 +1,7 @@ - operationTimeMode - + OperationTimeMode + 0 diff --git a/app/gui/oven_control/operationtimeparts.cpp b/app/gui/oven_control/operationtimeparts.cpp index fe894d6..90d7c23 100644 --- a/app/gui/oven_control/operationtimeparts.cpp +++ b/app/gui/oven_control/operationtimeparts.cpp @@ -3,9 +3,9 @@ #include "ui_operationtimeparts.h" #include "ovenstatics.h" -operationTimeParts::operationTimeParts(QWidget *parent) : +OperationTimeParts::OperationTimeParts(QWidget *parent) : QMainWindow(parent), - ui(new Ui::operationTimeParts) + ui(new Ui::OperationTimeParts) { int i=0; OvenStatistics* ovs = OvenStatistics::getInstance(); @@ -47,7 +47,7 @@ operationTimeParts::operationTimeParts(QWidget *parent) : if(ovs != NULL){ for( i =0;isrvdatas->use_log.values[m_arrPartItemIdxs[i]]); + m_arrUseItems[i] = &(ovs->srvdata->use_log.values[m_arrPartItemIdxs[i]]); } else m_arrUseItems[i] = NULL; } @@ -55,17 +55,17 @@ operationTimeParts::operationTimeParts(QWidget *parent) : reloadUi(); } -operationTimeParts::~operationTimeParts() +OperationTimeParts::~OperationTimeParts() { delete ui; } -void operationTimeParts::on_backButton_clicked() +void OperationTimeParts::on_backButton_clicked() { deleteLater(); } -void operationTimeParts::reloadUi(void){ +void OperationTimeParts::reloadUi(void){ uint32_t timetemp; OvenStatistics* ovs = OvenStatistics::getInstance(); QString strTemp=""; @@ -90,12 +90,12 @@ void operationTimeParts::reloadUi(void){ } } -void operationTimeParts::on_btnReset_2_clicked() +void OperationTimeParts::on_btnReset_2_clicked() { } -void operationTimeParts::on_btnResets_clicked(int idx){ +void OperationTimeParts::on_btnResets_clicked(int idx){ qDebug() << "PUSH BUTTON " << idx; if(idx < OPERATION_TIME_CONTROL_MAX){ if(m_arrUseItems[idx] !=NULL){ diff --git a/app/gui/oven_control/operationtimeparts.h b/app/gui/oven_control/operationtimeparts.h index 5b943e6..69d7991 100644 --- a/app/gui/oven_control/operationtimeparts.h +++ b/app/gui/oven_control/operationtimeparts.h @@ -5,22 +5,22 @@ #include #include #include -#include "servicedatas.h" +#include "servicedata.h" #define OPERATION_TIME_CONTROL_MAX 11 #define OPERATION_TIME_PARTS_MAX_ITEM 10 namespace Ui { -class operationTimeParts; +class OperationTimeParts; } -class operationTimeParts : public QMainWindow +class OperationTimeParts : public QMainWindow { Q_OBJECT public: - explicit operationTimeParts(QWidget *parent = 0); - ~operationTimeParts(); + explicit OperationTimeParts(QWidget *parent = 0); + ~OperationTimeParts(); private slots: void on_backButton_clicked(); @@ -40,7 +40,7 @@ private: QPushButton* m_arrResetBtn[OPERATION_TIME_CONTROL_MAX]; QButtonGroup* m_btnGrops; - Ui::operationTimeParts *ui; + Ui::OperationTimeParts *ui; void reloadUi(void); }; diff --git a/app/gui/oven_control/operationtimeparts.ui b/app/gui/oven_control/operationtimeparts.ui index 091d2cd..b5d2b1a 100644 --- a/app/gui/oven_control/operationtimeparts.ui +++ b/app/gui/oven_control/operationtimeparts.ui @@ -1,7 +1,7 @@ - operationTimeParts - + OperationTimeParts + 0 diff --git a/app/gui/oven_control/oven_control.pro b/app/gui/oven_control/oven_control.pro index 3fb5ab5..cbfbc61 100644 --- a/app/gui/oven_control/oven_control.pro +++ b/app/gui/oven_control/oven_control.pro @@ -44,7 +44,6 @@ SOURCES += main.cpp\ cooldownpopup.cpp \ engineermenuwindow.cpp \ ovenstatics.cpp \ - servicedatas.cpp \ popupwindow.cpp \ cookbook.cpp \ define.cpp \ @@ -61,7 +60,8 @@ SOURCES += main.cpp\ realtimepartswindow.cpp \ realtimesensorwindow.cpp \ bulletindicator.cpp \ - soundplayer.cpp + soundplayer.cpp \ + servicedata.cpp HEADERS += mainwindow.h \ cook.h \ @@ -95,7 +95,6 @@ HEADERS += mainwindow.h \ cooldownpopup.h \ engineermenuwindow.h \ ovenstatics.h \ - servicedatas.h \ popupwindow.h \ cookbook.h \ define.h \ @@ -112,7 +111,8 @@ HEADERS += mainwindow.h \ realtimepartswindow.h \ realtimesensorwindow.h \ bulletindicator.h \ - soundplayer.h + soundplayer.h \ + servicedata.h FORMS += mainwindow.ui \ manualcookwindow.ui \ diff --git a/app/gui/oven_control/ovenstatics.cpp b/app/gui/oven_control/ovenstatics.cpp index d17d2b7..341de97 100644 --- a/app/gui/oven_control/ovenstatics.cpp +++ b/app/gui/oven_control/ovenstatics.cpp @@ -49,12 +49,12 @@ OvenStatistics::OvenStatistics(QObject* parent) :QObject(parent) curSensorValue[12].itemp = 100; - srvdatas = new servicedatas(); - srvdatas->loadServiceDatas(); + srvdata = new ServiceData(); + srvdata->loadServiceData(); } OvenStatistics::~OvenStatistics(){ - delete srvdatas; + delete srvdata; } @@ -73,7 +73,7 @@ void OvenStatistics::onDataChanged() if(oven->cooking() && control.system){ if(state.door_state ==1 && curdoorstate==0){ //door error - item = &(srvdatas->err_log.items.door); + item = &(srvdata->err_log.items.door); item->fired_cnt+=1; if(item->first_fired==0)item->first_fired = ltime; item->last_fried = ltime; @@ -111,65 +111,65 @@ void OvenStatistics::processSensorError(uint16_t errflag, time_t ltime){ else state = SYS_ON_COOK_OFF; if(errflag & MAKE_MASK(SENSOR_ERR_SENSOR_1)){ - item = &(srvdatas->err_log.items.inner_temp_fail); + item = &(srvdata->err_log.items.inner_temp_fail); strTitle = tr("내부 온도 이상 발생"); strMsg = tr("내부 온도 센서에 이상이 발생하였습니다."); processErrorItems(item,sensor_err_type_def[state][SENSOR_ERR_SENSOR_1],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(SENSOR_ERR_SENSOR_2)){ - item = &(srvdatas->err_log.items.qunching_temp_fail); + item = &(srvdata->err_log.items.qunching_temp_fail); strTitle = tr("퀀칭 온도 이상 발생"); strMsg = tr("퀀칭 온도에 이상이 발생하였습니다."); processErrorItems(item,sensor_err_type_def[state][SENSOR_ERR_SENSOR_2],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(SENSOR_ERR_SENSOR_3)){ //Reserved allerrornoe 설정 - item = &(srvdatas->err_log.items.qunching_temp_fail); + item = &(srvdata->err_log.items.qunching_temp_fail); strTitle = tr("퀀칭 온도 이상 발생"); strMsg = tr("퀀칭 온도 센서에 이상이 발생하였습니다."); processErrorItems(item,sensor_err_type_def[state][SENSOR_ERR_SENSOR_3],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(SENSOR_ERR_SENSOR_4)){ - item = &(srvdatas->err_log.items.wall_temp1_fail); + item = &(srvdata->err_log.items.wall_temp1_fail); strTitle = tr("벽면 온도 이상 발생"); strMsg = tr("벽면 온도 센서에 이상이 발생하였습니다."); processErrorItems(item,sensor_err_type_def[state][SENSOR_ERR_SENSOR_4],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(SENSOR_ERR_SENSOR_5)){ - item = &(srvdatas->err_log.items.steam_gen_temp_fail); + item = &(srvdata->err_log.items.steam_gen_temp_fail); strTitle = tr("스팀제네레이터 온도 이상 발생"); strMsg = tr("스팀제네레이터 온도 센서에 이상이 발생하였습니다."); processErrorItems(item,sensor_err_type_def[state][SENSOR_ERR_SENSOR_5],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(SENSOR_ERR_SENSOR_6)){ - item = &(srvdatas->err_log.items.meatprove_temp1_fail); + item = &(srvdata->err_log.items.meatprove_temp1_fail); strTitle = tr("미트프로브 온도 이상 발생"); strMsg = tr("미트프로브 온도 센서에 이상이 발생하였습니다."); processErrorItems(item,sensor_err_type_def[state][SENSOR_ERR_SENSOR_6],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(SENSOR_ERR_SENSOR_7)){ //Reseved - item = &(srvdatas->err_log.items.meatprove_temp2_fail); + item = &(srvdata->err_log.items.meatprove_temp2_fail); strTitle = tr("미트프로브2 온도 이상 발생"); strMsg = tr("미트프로브2 온도 센서에 이상이 발생하였습니다."); processErrorItems(item,sensor_err_type_def[state][SENSOR_ERR_SENSOR_7],strMsg , strTitle, ltime); } if(errflag & MAKE_MASK(SENSOR_ERR_SENSOR_8)){ //Reserved - item = &(srvdatas->err_log.items.meatprove_temp3_fail); + item = &(srvdata->err_log.items.meatprove_temp3_fail); strMsg = tr("미트프로브3 온도 센서에 이상이 발생하였습니다."); strTitle = tr("미트프로브3 온도 이상 발생"); processErrorItems(item,sensor_err_type_def[state][SENSOR_ERR_SENSOR_8],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(SENSOR_ERR_SENSOR_9)){ //Reserved - item = &(srvdatas->err_log.items.meatprove_temp4_fail); + item = &(srvdata->err_log.items.meatprove_temp4_fail); strMsg = tr("미트프로브4 온도 센서에 이상이 발생하였습니다."); strTitle = tr("미트프로브4 온도 이상 발생"); processErrorItems(item,sensor_err_type_def[state][SENSOR_ERR_SENSOR_9],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(SENSOR_ERR_SENSOR_10)){ - item = &(srvdatas->err_log.items.pcb_temp_fail); + item = &(srvdata->err_log.items.pcb_temp_fail); strMsg = tr("PCB 온도 센서에 이상이 발생하였습니다."); strTitle = tr("PCB 온도 이상 발생"); processErrorItems(item,sensor_err_type_def[state][SENSOR_ERR_SENSOR_10],strMsg,strTitle, ltime); @@ -186,31 +186,31 @@ void OvenStatistics::processCommError(uint16_t errflag, time_t ltime){ else state = SYS_ON_COOK_OFF; if(errflag & MAKE_MASK(COMM_ERR_BUNNER1)){ - item = &(srvdatas->err_log.items.upper_pan_fail); + item = &(srvdata->err_log.items.upper_pan_fail); strMsg = tr("상부 송풍기 이상 발생"); strTitle = tr("상부 송풍기 이상 발생"); processErrorItems(item,comm_err_type_def[state][COMM_ERR_BUNNER1],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(COMM_ERR_BUNNER2)){ - item = &(srvdatas->err_log.items.lower_pan_fail); + item = &(srvdata->err_log.items.lower_pan_fail); strMsg = tr("하부 송풍기 이상 발생"); strTitle = tr("하부 송풍기 이상 발생"); processErrorItems(item,comm_err_type_def[state][COMM_ERR_BUNNER2],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(COMM_ERR_BUNNER3)){ - item = &(srvdatas->err_log.items.steam_pan_fail); + item = &(srvdata->err_log.items.steam_pan_fail); strMsg = tr("스팀 송풍기 이상 발생"); strTitle = tr("스팀 송풍기 이상 발생"); processErrorItems(item,comm_err_type_def[state][COMM_ERR_BUNNER3],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(COMM_ERR_LOWERFAN)){ - item = &(srvdatas->err_log.items.lower_motor_fail); + item = &(srvdata->err_log.items.lower_motor_fail); strMsg = tr("하부 모터 컨트롤러 이상 발생"); strTitle = tr("하부 모터 컨트롤러 이상 발생"); processErrorItems(item,comm_err_type_def[state][COMM_ERR_BUNNER2],strMsg,strTitle, ltime); } if(errflag & MAKE_MASK(COMM_ERR_UPPERFAN)){ - item = &(srvdatas->err_log.items.upper_motor_fail); + item = &(srvdata->err_log.items.upper_motor_fail); strMsg = tr("상부 모터 컨트롤러 이상 발생"); strTitle = tr("상부 모터 컨트롤러 이상 발생"); processErrorItems(item,comm_err_type_def[state][COMM_ERR_BUNNER2],strMsg,strTitle, ltime); @@ -228,66 +228,66 @@ void OvenStatistics::processSystemError(uint16_t errflag,time_t ltime){ if( errflag & MAKE_MASK(SYS_ERR_FIRE_TRIGGER1)){ //버너 컨트롤러 1 착화 이상 - item = &(srvdatas->err_log.items.upper_fire_fail); + item = &(srvdata->err_log.items.upper_fire_fail); strMsg = tr("상부 버너 착하가 되지 않습니다."); strTitle = tr("상부 버너 착하 이상 발생"); processErrorItems(item, sys_err_type_def[state][SYS_ERR_FIRE_TRIGGER1],strMsg,strTitle,ltime); } if(errflag & MAKE_MASK(SYS_ERR_FIRE_TRIGGER2)){ //버너 컨트롤러 2 착화 이상 - item = &(srvdatas->err_log.items.lower_fire_fail); + item = &(srvdata->err_log.items.lower_fire_fail); strMsg = tr("하부 버너 착하가 되지 않습니다."); strTitle = tr("하부 버너 착하 이상 발생"); processErrorItems(item, sys_err_type_def[state][SYS_ERR_FIRE_TRIGGER2],strMsg,strTitle,ltime); } if(errflag & MAKE_MASK(SYS_ERR_FIRE_TRIGGER3)){ - item = &(srvdatas->err_log.items.steam_fire_fail); + item = &(srvdata->err_log.items.steam_fire_fail); strMsg = tr("스팀 버너 착하가 되지 않습니다."); strMsg = tr("스팀 버너 착하 이상 발생"); processErrorItems(item, sys_err_type_def[state][SYS_ERR_FIRE_TRIGGER3],strMsg,strTitle,ltime); } if(errflag & MAKE_MASK(SYS_ERR_OVNE_TEMP_ALARM)){ - item = &(srvdatas->err_log.items.inner_temp_high_alarm); + item = &(srvdata->err_log.items.inner_temp_high_alarm); strMsg = tr("내부 온도가 과열되었습니다."); strTitle = tr("내부 온도 과열 발생"); processErrorItems(item, sys_err_type_def[state][SYS_ERR_OVNE_TEMP_ALARM],strMsg,strTitle,ltime); } if(errflag & MAKE_MASK(SYS_ERR_QUN_TEMP_ALARM)){ //퀀칭 온도 센서 과열 - item = &(srvdatas->err_log.items.qunching_temp_high_alarm); + item = &(srvdata->err_log.items.qunching_temp_high_alarm); strTitle = tr("퀀칭 온도 센서 이상 발생"); strMsg = tr("퀀칭 온도 센서가 과열되었습니다"); processErrorItems(item, sys_err_type_def[state][SYS_ERR_QUN_TEMP_ALARM],strMsg,strTitle,ltime); } if(errflag & MAKE_MASK(SYS_ERR_CENTER_TEMP_ALARM)){ //중심 온도 과열 - item = &(srvdatas->err_log.items.meatprove_temp1_high_alarm); + item = &(srvdata->err_log.items.meatprove_temp1_high_alarm); strTitle = tr("미트프로브 온도 센서 이상 발생."); strMsg = tr("미트프로브 온도 센서 과열되었습니다."); processErrorItems(item, sys_err_type_def[state][SYS_ERR_CENTER_TEMP_ALARM],strMsg,strTitle,ltime); } if(errflag & MAKE_MASK(SYS_ERR_WALL_TEMP_ALARM)){ - item = &(srvdatas->err_log.items.wall_temp1_high_alarm); + item = &(srvdata->err_log.items.wall_temp1_high_alarm); strTitle = tr("벽면 온도 센서 이상 발생."); strMsg = tr("벽면 온도 센서가 과열 되었습니다."); processErrorItems(item, sys_err_type_def[state][SYS_ERR_WALL_TEMP_ALARM],strMsg,strTitle,ltime); } if(errflag & MAKE_MASK(SYS_ERR_STAM_TEMP_ALARM)){ - item = &(srvdatas->err_log.items.steam_gen_temp_high_alram); + item = &(srvdata->err_log.items.steam_gen_temp_high_alram); strTitle = tr("스팀제네레이터 온도 과열 발생."); strMsg = tr("스팀제네레이터 온도 센서 과열이 발생되었습니다."); processErrorItems(item, sys_err_type_def[state][SYS_ERR_STAM_TEMP_ALARM],strMsg,strTitle,ltime); } if(errflag & MAKE_MASK(SYS_ERR_WATER_SPLY_FAIL)){ //급수 이상 -> 유량 센서 이상 - item = &(srvdatas->err_log.items.water_level_sensor_fail); + item = &(srvdata->err_log.items.water_level_sensor_fail); strTitle = tr("급수 이상 발생"); strMsg = tr("급수가 되지 않습니다."); processErrorItems(item, sys_err_type_def[state][SYS_ERR_WATER_SPLY_FAIL],strMsg,strTitle,ltime); } if(errflag & MAKE_MASK(SYS_ERR_WATER_LEVEL_FAIL)){ //급수 이상 -> 수위 센서 이상 - item = &(srvdatas->err_log.items.water_level_sensor_fail); + item = &(srvdata->err_log.items.water_level_sensor_fail); strTitle = tr("급수 이상 발생"); strMsg = tr("급수가 되지 않습니다."); processErrorItems(item, sys_err_type_def[state][SYS_ERR_WATER_LEVEL_FAIL],strMsg,strTitle,ltime); @@ -314,7 +314,7 @@ void OvenStatistics::oneSecTimerFired(void){ nOneSecCnt++; if( (nOneSecCnt % 10) ==0 ) { - srvdatas->saveServiceDatas(); + srvdata->saveServiceData(); qDebug()<<"statics data saved"; } @@ -325,82 +325,82 @@ void OvenStatistics::oneSecTimerFired(void){ } //가열부 시간 측정 if( (state.onoff_state1 & LOAD_STATE1_STEAM_BUNNER) !=0){ - srvdatas->use_log.items.steam_heat +=1; + srvdata->use_log.items.steam_heat +=1; } if( (state.onoff_state1 & (LOAD_STATE1_UPPER_BUNNER | LOAD_STATE1_LOWER_FAN))!=0){ - srvdatas->use_log.items.dry_heat+=1; + srvdata->use_log.items.dry_heat+=1; if(state.onoff_state1 & (LOAD_STATE1_UPPER_BUNNER)){ - srvdatas->use_log.items.upper_heat +=1; + srvdata->use_log.items.upper_heat +=1; } if((state.onoff_state2 & LOAD_STATE1_LOWER_BUNNER)!=0){ - srvdatas->use_log.items.lower_heat +=1; + srvdata->use_log.items.lower_heat +=1; } } //모드 시간 계산 if(state.cooking_mode !=0){ if(state.cooking_humidity==0){ //건열 모드 - srvdatas->use_log.items.cook_dry_mode+=1; + srvdata->use_log.items.cook_dry_mode+=1; } else if(state.cooking_humidity ==100){ //스팀모드 - srvdatas->use_log.items.cook_steam_mode+=1; + srvdata->use_log.items.cook_steam_mode+=1; } - else srvdatas->use_log.items.cook_combi_mode+=1; + else srvdata->use_log.items.cook_combi_mode+=1; } if(state.cleaning_mode !=0 && state.cleaning_sate !=0){ switch (state.cleaning_mode) { case (uint16_t)wash_mode_nocleanser: - srvdatas->use_log.items.wash_mode_nocleanser+=1; + srvdata->use_log.items.wash_mode_nocleanser+=1; break; case (uint16_t)wash_mode_simple: - srvdatas->use_log.items.wash_mode_simple+=1; + srvdata->use_log.items.wash_mode_simple+=1; break; case (uint16_t)wash_mode_standard: - srvdatas->use_log.items.wash_mode_standard+=1; + srvdata->use_log.items.wash_mode_standard+=1; break; case (uint16_t)wash_mode_strong: - srvdatas->use_log.items.wash_mode_strong+=1; + srvdata->use_log.items.wash_mode_strong+=1; break; case (uint16_t)wash_mode_highspeed: - srvdatas->use_log.items.wash_mode_speed+=1; + srvdata->use_log.items.wash_mode_speed+=1; break; default: break; } } if(control.cooldown ==1){ - srvdatas->use_log.items.cooldown_mode+=1; + srvdata->use_log.items.cooldown_mode+=1; } //부품 if(state.door_state !=0){ - srvdatas->use_log.items.door_open+=1; + srvdata->use_log.items.door_open+=1; realdata.b.door_open = 1; } if(state.onoff_state2 !=0){ if( (state.onoff_state2 & LOAD_STATE2_DV)!=0){ - srvdatas->use_log.items.dv_open+=1; + srvdata->use_log.items.dv_open+=1; } if((state.onoff_state2 & LOAD_STATE2_SSV)!=0){ - srvdatas->use_log.items.ssv_open+=1; + srvdata->use_log.items.ssv_open+=1; } if((state.onoff_state2 & LOAD_STATE2_QNV)!=0){ - srvdatas->use_log.items.qnv_open+=1; + srvdata->use_log.items.qnv_open+=1; } if((state.onoff_state2 & LOAD_STATE2_SNV)!=0){ - srvdatas->use_log.items.snv_open+=1; + srvdata->use_log.items.snv_open+=1; } if((state.onoff_state2 & LOAD_STATE2_SSP)!=0){ - srvdatas->use_log.items.ssp_open+=1; + srvdata->use_log.items.ssp_open+=1; } if((state.onoff_state2 & LOAD_STATE2_HDM)!=0){ - srvdatas->use_log.items.hdm_open+=1; + srvdata->use_log.items.hdm_open+=1; } if((state.onoff_state2 & LOAD_STATE2_DP)!=0){ - srvdatas->use_log.items.dp_open+=1; + srvdata->use_log.items.dp_open+=1; } if((state.onoff_state2 & LOAD_STATE2_UNP) !=0){ - srvdatas->use_log.items.unp_open+=1; + srvdata->use_log.items.unp_open+=1; } } @@ -415,74 +415,74 @@ void OvenStatistics::oneSecTimerFired(void){ realdata.b.ssv_open = (state.onoff_state2&LOAD_STATE2_SSV)==0?0:1; realdata.b.water_level = 0; - if(srvdatas->sensor_log.items.B1.high_temp.itemp < state.sensor1 ){ - srvdatas->sensor_log.items.B1.high_temp.itemp = state.sensor1; - srvdatas->sensor_log.items.B1.last_high_time = ltime; + if(srvdata->sensor_log.items.B1.high_temp.itemp < state.sensor1 ){ + srvdata->sensor_log.items.B1.high_temp.itemp = state.sensor1; + srvdata->sensor_log.items.B1.last_high_time = ltime; } curSensorValue[0].itemp = state.sensor1; - if(srvdatas->sensor_log.items.B2.high_temp.itemp < state.sensor2 ){ - srvdatas->sensor_log.items.B2.high_temp.itemp = state.sensor2; - srvdatas->sensor_log.items.B2.last_high_time = ltime; + if(srvdata->sensor_log.items.B2.high_temp.itemp < state.sensor2 ){ + srvdata->sensor_log.items.B2.high_temp.itemp = state.sensor2; + srvdata->sensor_log.items.B2.last_high_time = ltime; } curSensorValue[1].itemp = state.sensor2; - if(srvdatas->sensor_log.items.B3_1.high_temp.itemp < state.sensor6 ){ - srvdatas->sensor_log.items.B3_1.high_temp.itemp = state.sensor6; - srvdatas->sensor_log.items.B3_1.last_high_time = ltime; + if(srvdata->sensor_log.items.B3_1.high_temp.itemp < state.sensor6 ){ + srvdata->sensor_log.items.B3_1.high_temp.itemp = state.sensor6; + srvdata->sensor_log.items.B3_1.last_high_time = ltime; } curSensorValue[5].itemp = state.sensor6; - if(srvdatas->sensor_log.items.B4.high_temp.itemp < state.sensor4 ){ - srvdatas->sensor_log.items.B4.high_temp.itemp = state.sensor4; - srvdatas->sensor_log.items.B4.last_high_time = ltime; + if(srvdata->sensor_log.items.B4.high_temp.itemp < state.sensor4 ){ + srvdata->sensor_log.items.B4.high_temp.itemp = state.sensor4; + srvdata->sensor_log.items.B4.last_high_time = ltime; } curSensorValue[3].itemp = state.sensor4; - if(srvdatas->sensor_log.items.B5.high_temp.itemp < state.sensor5 ){ - srvdatas->sensor_log.items.B5.high_temp.itemp = state.sensor5; - srvdatas->sensor_log.items.B5.last_high_time = ltime; + if(srvdata->sensor_log.items.B5.high_temp.itemp < state.sensor5 ){ + srvdata->sensor_log.items.B5.high_temp.itemp = state.sensor5; + srvdata->sensor_log.items.B5.last_high_time = ltime; } curSensorValue[4].itemp = state.sensor5; - if(srvdatas->sensor_log.items.B3_2.high_temp.itemp < state.sensor7 ){ - srvdatas->sensor_log.items.B3_2.high_temp.itemp = state.sensor7; - srvdatas->sensor_log.items.B3_2.last_high_time = ltime; + if(srvdata->sensor_log.items.B3_2.high_temp.itemp < state.sensor7 ){ + srvdata->sensor_log.items.B3_2.high_temp.itemp = state.sensor7; + srvdata->sensor_log.items.B3_2.last_high_time = ltime; } curSensorValue[6].itemp = state.sensor7; - if(srvdatas->sensor_log.items.B3_3.high_temp.itemp < state.sensor8 ){ - srvdatas->sensor_log.items.B3_3.high_temp.itemp = state.sensor8; - srvdatas->sensor_log.items.B3_3.last_high_time = ltime; + if(srvdata->sensor_log.items.B3_3.high_temp.itemp < state.sensor8 ){ + srvdata->sensor_log.items.B3_3.high_temp.itemp = state.sensor8; + srvdata->sensor_log.items.B3_3.last_high_time = ltime; } curSensorValue[7].itemp = state.sensor8; - if(srvdatas->sensor_log.items.B3_4.high_temp.itemp < state.sensor9 ){ - srvdatas->sensor_log.items.B3_4.high_temp.itemp = state.sensor9; - srvdatas->sensor_log.items.B3_4.last_high_time = ltime; + if(srvdata->sensor_log.items.B3_4.high_temp.itemp < state.sensor9 ){ + srvdata->sensor_log.items.B3_4.high_temp.itemp = state.sensor9; + srvdata->sensor_log.items.B3_4.last_high_time = ltime; } curSensorValue[8].itemp = state.sensor9; - if(srvdatas->sensor_log.items.mbar1.high_temp.utemp < state.sensor11 ){ - srvdatas->sensor_log.items.mbar1.high_temp.utemp = state.sensor11; - srvdatas->sensor_log.items.mbar1.last_high_time = ltime; + if(srvdata->sensor_log.items.mbar1.high_temp.utemp < state.sensor11 ){ + srvdata->sensor_log.items.mbar1.high_temp.utemp = state.sensor11; + srvdata->sensor_log.items.mbar1.last_high_time = ltime; } curSensorValue[10].utemp = state.sensor11; - if(srvdatas->sensor_log.items.mbar2.high_temp.utemp < state.sensor12 ){ - srvdatas->sensor_log.items.mbar2.high_temp.utemp = state.sensor12; - srvdatas->sensor_log.items.mbar2.last_high_time = ltime; + if(srvdata->sensor_log.items.mbar2.high_temp.utemp < state.sensor12 ){ + srvdata->sensor_log.items.mbar2.high_temp.utemp = state.sensor12; + srvdata->sensor_log.items.mbar2.last_high_time = ltime; } curSensorValue[11].utemp = state.sensor12; - if(srvdatas->sensor_log.items.pcb.high_temp.itemp < state.sensor13 ){ - srvdatas->sensor_log.items.pcb.high_temp.itemp = state.sensor13; - srvdatas->sensor_log.items.pcb.last_high_time = ltime; + if(srvdata->sensor_log.items.pcb.high_temp.itemp < state.sensor13 ){ + srvdata->sensor_log.items.pcb.high_temp.itemp = state.sensor13; + srvdata->sensor_log.items.pcb.last_high_time = ltime; } curSensorValue[12].itemp = state.sensor13; - if(srvdatas->sensor_log.items.adc.high_temp.itemp < state.sensor14 ){ - srvdatas->sensor_log.items.adc.high_temp.itemp = state.sensor14; - srvdatas->sensor_log.items.adc.last_high_time = ltime; + if(srvdata->sensor_log.items.adc.high_temp.itemp < state.sensor14 ){ + srvdata->sensor_log.items.adc.high_temp.itemp = state.sensor14; + srvdata->sensor_log.items.adc.last_high_time = ltime; } curSensorValue[13].itemp = state.sensor14; @@ -493,11 +493,11 @@ void OvenStatistics::oneSecTimerFired(void){ void OvenStatistics::processErrorItems(error_item *item, error_exe_type errtype, const QString &MsgDesc, const QString &MsgTitle, time_t ltime){ - qDebug() << (int) (item - &(srvdatas->err_log.values[0])) << "ERROR Fired!"; + qDebug() << (int) (item - &(srvdata->err_log.values[0])) << "ERROR Fired!"; if(m_pLastErrItem == item ){ - srvdatas->err_log.items.repeat_error.fired_cnt =item->fired_cnt; - srvdatas->err_log.items.repeat_error.first_fired = item->first_fired; - srvdatas->err_log.items.repeat_error.last_fried = item->last_fried; + srvdata->err_log.items.repeat_error.fired_cnt =item->fired_cnt; + srvdata->err_log.items.repeat_error.first_fired = item->first_fired; + srvdata->err_log.items.repeat_error.last_fried = item->last_fried; } m_pLastErrItem = item; @@ -511,7 +511,7 @@ void OvenStatistics::processErrorItems(error_item *item, error_exe_type errtype, case error_type_popclr: case error_type_popnonclr: { - errorPopupDlg *dlg = new errorPopupDlg(QApplication::activeWindow(),MsgDesc,MsgTitle); + ErrorPopupDlg *dlg = new ErrorPopupDlg(QApplication::activeWindow(),MsgDesc,MsgTitle); dlg->exec(); break; } @@ -519,7 +519,7 @@ void OvenStatistics::processErrorItems(error_item *item, error_exe_type errtype, case error_type_engnonclr: case error_type_onlyeng: { - engineermenuwindow *w = new engineermenuwindow(QApplication::activeWindow()); + EngineerMenuWindow *w = new EngineerMenuWindow(QApplication::activeWindow()); w->showFullScreen(); break; } diff --git a/app/gui/oven_control/ovenstatics.h b/app/gui/oven_control/ovenstatics.h index 9e41769..8680183 100644 --- a/app/gui/oven_control/ovenstatics.h +++ b/app/gui/oven_control/ovenstatics.h @@ -6,7 +6,7 @@ #include "../../app-prime-modbus/include/all_share.h" #include "udphandler.h" #include "oven.h" -#include "servicedatas.h" +#include "servicedata.h" #define SYS_STATE_MAX 4 @@ -164,7 +164,7 @@ class OvenStatistics : public QObject { Q_OBJECT public: - servicedatas* srvdatas; + ServiceData* srvdata; static OvenStatistics* getInstance(QObject* parent = 0); static void destroy(); diff --git a/app/gui/oven_control/realtimemain.cpp b/app/gui/oven_control/realtimemain.cpp index b42f5ea..b3e787a 100644 --- a/app/gui/oven_control/realtimemain.cpp +++ b/app/gui/oven_control/realtimemain.cpp @@ -3,33 +3,33 @@ #include "realtimepartswindow.h" #include "realtimesensorwindow.h" -realtimeMain::realtimeMain(QWidget *parent) : +RealtimeMain::RealtimeMain(QWidget *parent) : QMainWindow(parent), - ui(new Ui::realtimeMain) + ui(new Ui::RealtimeMain) { ui->setupUi(this); } -realtimeMain::~realtimeMain() +RealtimeMain::~RealtimeMain() { delete ui; } -void realtimeMain::on_btnPartsReal_clicked() +void RealtimeMain::on_btnPartsReal_clicked() { - realtimePartsWindow* w = new realtimePartsWindow(this); + RealtimePartsWindow* w = new RealtimePartsWindow(this); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); } -void realtimeMain::on_btnTemperatureReal_clicked() +void RealtimeMain::on_btnTemperatureReal_clicked() { - realtimeSensorWindow* w = new realtimeSensorWindow(this); + RealtimeSensorWindow* w = new RealtimeSensorWindow(this); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); } -void realtimeMain::on_backButton_clicked() +void RealtimeMain::on_backButton_clicked() { deleteLater(); } diff --git a/app/gui/oven_control/realtimemain.h b/app/gui/oven_control/realtimemain.h index 914e2bb..ab51cba 100644 --- a/app/gui/oven_control/realtimemain.h +++ b/app/gui/oven_control/realtimemain.h @@ -4,16 +4,16 @@ #include namespace Ui { -class realtimeMain; +class RealtimeMain; } -class realtimeMain : public QMainWindow +class RealtimeMain : public QMainWindow { Q_OBJECT public: - explicit realtimeMain(QWidget *parent = 0); - ~realtimeMain(); + explicit RealtimeMain(QWidget *parent = 0); + ~RealtimeMain(); private slots: void on_btnPartsReal_clicked(); @@ -23,7 +23,7 @@ private slots: void on_backButton_clicked(); private: - Ui::realtimeMain *ui; + Ui::RealtimeMain *ui; }; #endif // REALTIMEMAIN_H diff --git a/app/gui/oven_control/realtimemain.ui b/app/gui/oven_control/realtimemain.ui index 632e99c..8e8f1cc 100644 --- a/app/gui/oven_control/realtimemain.ui +++ b/app/gui/oven_control/realtimemain.ui @@ -1,7 +1,7 @@ - realtimeMain - + RealtimeMain + 0 diff --git a/app/gui/oven_control/realtimepartswindow.cpp b/app/gui/oven_control/realtimepartswindow.cpp index 231abf0..931180a 100644 --- a/app/gui/oven_control/realtimepartswindow.cpp +++ b/app/gui/oven_control/realtimepartswindow.cpp @@ -2,9 +2,9 @@ #include "ui_realtimepartswindow.h" #include "ovenstatics.h" -realtimePartsWindow::realtimePartsWindow(QWidget *parent) : +RealtimePartsWindow::RealtimePartsWindow(QWidget *parent) : QMainWindow(parent), - ui(new Ui::realtimePartsWindow) + ui(new Ui::RealtimePartsWindow) { ui->setupUi(this); @@ -46,17 +46,17 @@ realtimePartsWindow::realtimePartsWindow(QWidget *parent) : } -realtimePartsWindow::~realtimePartsWindow() +RealtimePartsWindow::~RealtimePartsWindow() { delete ui; } -void realtimePartsWindow::on_backButton_clicked() +void RealtimePartsWindow::on_backButton_clicked() { deleteLater(); } -void realtimePartsWindow::reloadUi(void){ +void RealtimePartsWindow::reloadUi(void){ OvenStatistics* ovs = OvenStatistics::getInstance(); QString strTemp = ""; int i = 0,j=0; diff --git a/app/gui/oven_control/realtimepartswindow.h b/app/gui/oven_control/realtimepartswindow.h index db1d7f3..a0bf686 100644 --- a/app/gui/oven_control/realtimepartswindow.h +++ b/app/gui/oven_control/realtimepartswindow.h @@ -9,22 +9,22 @@ namespace Ui { -class realtimePartsWindow; +class RealtimePartsWindow; } -class realtimePartsWindow : public QMainWindow +class RealtimePartsWindow : public QMainWindow { Q_OBJECT public: - explicit realtimePartsWindow(QWidget *parent = 0); - ~realtimePartsWindow(); + explicit RealtimePartsWindow(QWidget *parent = 0); + ~RealtimePartsWindow(); private slots: void on_backButton_clicked(); private: - Ui::realtimePartsWindow *ui; + Ui::RealtimePartsWindow *ui; QLabel *m_arrLbState[CONTROL_LIST_COL_MAX][CONTROL_LIST_ITEM_MAX]; void reloadUi(void); diff --git a/app/gui/oven_control/realtimepartswindow.ui b/app/gui/oven_control/realtimepartswindow.ui index c2dfe71..3c429c5 100644 --- a/app/gui/oven_control/realtimepartswindow.ui +++ b/app/gui/oven_control/realtimepartswindow.ui @@ -1,7 +1,7 @@ - realtimePartsWindow - + RealtimePartsWindow + 0 diff --git a/app/gui/oven_control/realtimesensorwindow.cpp b/app/gui/oven_control/realtimesensorwindow.cpp index 3ecfa70..88346e5 100644 --- a/app/gui/oven_control/realtimesensorwindow.cpp +++ b/app/gui/oven_control/realtimesensorwindow.cpp @@ -2,9 +2,9 @@ #include "ui_realtimesensorwindow.h" #include "ovenstatics.h" -realtimeSensorWindow::realtimeSensorWindow(QWidget *parent) : +RealtimeSensorWindow::RealtimeSensorWindow(QWidget *parent) : QMainWindow(parent), - ui(new Ui::realtimeSensorWindow) + ui(new Ui::RealtimeSensorWindow) { OvenStatistics* ovs = OvenStatistics::getInstance(); int i = 0; @@ -51,17 +51,17 @@ realtimeSensorWindow::realtimeSensorWindow(QWidget *parent) : m_arrLbState[3][8] = ui->m_ctrlLbListState_4_9; for(i=0;isrvdatas->sensor_log.values[m_arrSensorItemIdxs[i]]); + m_arrSensorItems[i] = &(ovs->srvdata->sensor_log.values[m_arrSensorItemIdxs[i]]); } reloadUi(); } -realtimeSensorWindow::~realtimeSensorWindow() +RealtimeSensorWindow::~RealtimeSensorWindow() { delete ui; } -void realtimeSensorWindow::on_backButton_clicked() +void RealtimeSensorWindow::on_backButton_clicked() { deleteLater(); } @@ -69,7 +69,7 @@ void realtimeSensorWindow::on_backButton_clicked() uint16_t i_temp1,i_temp2; type_temp temp_temp; -void realtimeSensorWindow::reloadUi(void){ +void RealtimeSensorWindow::reloadUi(void){ char strTime[64]; QString strTemp=""; struct tm *timeptr; diff --git a/app/gui/oven_control/realtimesensorwindow.h b/app/gui/oven_control/realtimesensorwindow.h index 89da473..58cb95c 100644 --- a/app/gui/oven_control/realtimesensorwindow.h +++ b/app/gui/oven_control/realtimesensorwindow.h @@ -3,22 +3,22 @@ #include #include -#include "servicedatas.h" +#include "servicedata.h" #define REALSENSOR_CONTROL_LIST_COL_MAX 4 #define REALSENSOR_CONTROL_LIST_ITEM_MAX 9 namespace Ui { -class realtimeSensorWindow; +class RealtimeSensorWindow; } -class realtimeSensorWindow : public QMainWindow +class RealtimeSensorWindow : public QMainWindow { Q_OBJECT public: - explicit realtimeSensorWindow(QWidget *parent = 0); - ~realtimeSensorWindow(); + explicit RealtimeSensorWindow(QWidget *parent = 0); + ~RealtimeSensorWindow(); private slots: void on_backButton_clicked(); @@ -31,7 +31,7 @@ private: 320,120,270,300,300,300,300,80,80 }; - Ui::realtimeSensorWindow *ui; + Ui::RealtimeSensorWindow *ui; QLabel *m_arrLbState[REALSENSOR_CONTROL_LIST_COL_MAX][REALSENSOR_CONTROL_LIST_ITEM_MAX]; sensor_log_item* m_arrSensorItems[REALSENSOR_CONTROL_LIST_ITEM_MAX]; diff --git a/app/gui/oven_control/realtimesensorwindow.ui b/app/gui/oven_control/realtimesensorwindow.ui index 9fa8bb2..97d2be2 100644 --- a/app/gui/oven_control/realtimesensorwindow.ui +++ b/app/gui/oven_control/realtimesensorwindow.ui @@ -1,7 +1,7 @@ - realtimeSensorWindow - + RealtimeSensorWindow + 0 diff --git a/app/gui/oven_control/servicedata.cpp b/app/gui/oven_control/servicedata.cpp new file mode 100644 index 0000000..dc8a949 --- /dev/null +++ b/app/gui/oven_control/servicedata.cpp @@ -0,0 +1,113 @@ +#include "string.h" +#include "servicedata.h" +#include +#include +#include // write(), close() + +#define FRAM_SIZE 2048 +#define FRAM_TEST_PROCESS 0 + +#define fRam_path "/sys/bus/spi/devices/spi0.0/fram" +#define INIT_FRAM 1 + + +ServiceData::ServiceData() +{ + qDebug()<< "Statics Data Size Report\r\n error_log size = " << sizeof(error_log) << " \r\nuse_static_log size = " << sizeof(use_statics_log) \ + << "\r\nsensor_statics_log size = " << sizeof(sensor_statics_log); + memset((void*)err_log.data,0x00,sizeof(error_log)); + memset((void*)use_log.data,0x00,sizeof(use_statics_log)); + memset((void*)sensor_log.data,0x00, sizeof(sensor_statics_log)); +#if INIT_FRAM == 1 + saveServiceData(); +#else + loadServiceData(); +#endif +} + + + +bool ServiceData::loadServiceData(void){ + uint8_t buffs[FRAM_SIZE]; + int fd; + +#if FRAM_TEST_PROCESS == 1 + int i; + memset(buffs,0x00,256); + for(i=0;i<256;i++){ + buffs[i] = i; + } + fd = open(fRam_path, O_RDWR); + if(fd>0){ + write(fd,buffs,256); + close(fd); + } + else{ + qDebug()<<"FRAM open fail!"; + return false; + } + i=0; + memset(buffs,0x00,256); + fd = open(fRam_path, O_RDONLY ); + if(fd>0){ + read(fd,buffs,256); + close(fd); + }else{ + qDebug()<<"FRAM open fail!"; + return false; + } + for(i=0;i<256;i++){ + if(i !=buffs[i]) { + qDebug()<<"FRAM Test Fail"; + return false; + } + } + qDebug()<<"FRAM Test Success!"; + return true; +#endif + + + + + + + fd = open(fRam_path, O_RDONLY ); + if(fd>0){ + memset(buffs,0x00,FRAM_SIZE); + read(fd,buffs,FRAM_SIZE); + if(buffs[sizeof(error_log) + sizeof(use_statics_log) + sizeof(sensor_statics_log)] != 0x9C){ + close(fd); + return saveServiceData(); + } + + qDebug() << "FRAM Read, Write Size is " << sizeof(error_log)+sizeof(use_statics_log); + memcpy((void*)err_log.data,buffs,sizeof(error_log)); + memcpy((void*)use_log.data, (void*)(&buffs[sizeof(error_log)]),sizeof(use_statics_log)); + memcpy((void*)sensor_log.data,(void*)(&buffs[sizeof(error_log) + sizeof(use_statics_log)]),sizeof(sensor_statics_log)); + close(fd); + }else{ + qDebug()<<"FRAM FILE Open fail!!"; + } + return true; +} + +bool ServiceData::saveServiceData(void){ + uint8_t buffs[FRAM_SIZE]; + int fd; + fd = open(fRam_path, O_RDWR | O_SYNC); + if(fd>0){ + memset(buffs,0x00,FRAM_SIZE); + memcpy(buffs,(void*)err_log.data,sizeof(error_log)); + memcpy((void*)(&buffs[sizeof(error_log)]),(void*)use_log.data,sizeof(use_statics_log)); + memcpy((void*)(&buffs[sizeof(error_log) + sizeof(use_statics_log)]),(void*)sensor_log.data,sizeof(sensor_statics_log)); + buffs[sizeof(error_log) + sizeof(use_statics_log) + sizeof(sensor_statics_log)] = 0x9C; + write(fd,buffs,FRAM_SIZE); + close(fd); + }else{ + qDebug()<<"FRAM FILE Open fail!!"; + return false; + } + return true; +} + + diff --git a/app/gui/oven_control/servicedata.h b/app/gui/oven_control/servicedata.h new file mode 100644 index 0000000..6e1ef0a --- /dev/null +++ b/app/gui/oven_control/servicedata.h @@ -0,0 +1,201 @@ +#ifndef SERVICEDATA_H +#define SERVICEDATA_H + +#include +#include + +#define STRUCT_PACK __attribute__ ((packed)) + +#define MAX_ERROR_TYPE_CNT 31 + +#define MAX_STATICS_CNT 23 + +#define MAX_LOG_SENSOR 16 + +typedef struct _error_item{ + uint16_t fired_cnt; + time_t first_fired; + time_t last_fried; +}STRUCT_PACK error_item; + +typedef union{ + int16_t itemp; + uint16_t utemp; +}type_temp; + +typedef struct _sensor_log_item{ + type_temp high_temp; + time_t last_high_time; +}STRUCT_PACK sensor_log_item; + + +typedef union _sensor_statics_log{ + uint8_t data[MAX_LOG_SENSOR * sizeof(sensor_log_item)]; + sensor_log_item values[MAX_LOG_SENSOR]; + struct{ + sensor_log_item B1; + sensor_log_item B2; + sensor_log_item Reserved1; + sensor_log_item B4; + sensor_log_item B5; + sensor_log_item B3_1; + sensor_log_item B3_2; + sensor_log_item B3_3; + sensor_log_item B3_4; + sensor_log_item Reserved2; //10 + sensor_log_item mbar1; + sensor_log_item mbar2; + sensor_log_item pcb; + sensor_log_item adc; + sensor_log_item convec_fan_rpm; + sensor_log_item bunner_rpm; + }items; +}STRUCT_PACK sensor_statics_log; + + + +typedef union _error_log{ + uint8_t data[MAX_ERROR_TYPE_CNT*sizeof(error_item)]; + error_item values[MAX_ERROR_TYPE_CNT]; + struct{ + error_item door; + error_item upper_fire_fail; + error_item upper_pan_fail; + error_item lower_fire_fail; + error_item lower_pan_fail; + error_item steam_fire_fail; + error_item steam_pan_fail; + error_item water_level_sensor_fail; + error_item water_flow_sensor_fail; + error_item inner_temp_high_alarm; //B1 Sensor + error_item inner_temp_fail; + error_item qunching_temp_high_alarm; //B2 Sensor + error_item qunching_temp_fail; + error_item meatprove_temp1_high_alarm; //B3 Sensor + error_item meatprove_temp1_fail; + error_item wall_temp1_high_alarm; //B4 Sensor + error_item wall_temp1_fail; + error_item steam_gen_temp_high_alram; //B5 Sensor + error_item steam_gen_temp_fail; + error_item meatprove_temp2_fail; + error_item meatprove_temp3_fail; + error_item meatprove_temp4_fail; + error_item pcb_temp_high_alarm; //PCB Temp + error_item pcb_temp_fail; + error_item upper_motor_fail; + error_item lower_motor_fail; + error_item small_motor_fail; + error_item midd_motor_fail; + error_item supply_motor_fail; // Steam Generator Tank Supply Pump + error_item humidity_tamper_fail; + error_item repeat_error; + }items; +}STRUCT_PACK error_log; + +enum ERROR_ITEM_IDX{ + ERROR_IDX_door=0, + ERROR_IDX_upper_fire_fail, + ERROR_IDX_upper_pan_fail, + ERROR_IDX_lower_fire_fail, + ERROR_IDX_lower_pan_fail, + ERROR_IDX_steam_fire_fail, + ERROR_IDX_steam_pan_fail, + ERROR_IDX_water_level_sensor_fail, + ERROR_IDX_water_flow_sensor_fail, + ERROR_IDX_inner_temp_high_alarm, //B1 Sensor + ERROR_IDX_inner_temp_fail, + ERROR_IDX_qunching_temp_high_alarm, //B2 Sensor + ERROR_IDX_qunching_temp_fail, + ERROR_IDX_meatprove_temp1_high_alarm, //B3 Sensor + ERROR_IDX_meatprove_temp1_fail, + ERROR_IDX_wall_temp1_high_alarm, //B4 Sensor + ERROR_IDX_wall_temp1_fail, + ERROR_IDX_steam_gen_temp_high_alram, //B5 Sensor + ERROR_IDX_steam_gen_temp_fail, + ERROR_IDX_meatprove_temp2_fail, + ERROR_IDX_meatprove_temp3_fail, + ERROR_IDX_meatprove_temp4_fail, + ERROR_IDX_pcb_temp_high_alarm, //PCB Temp + ERROR_IDX_pcb_temp_fail, + ERROR_IDX_upper_motor_fail, + ERROR_IDX_lower_motor_fail, + ERROR_IDX_small_motor_fail, + ERROR_IDX_midd_motor_fail, + ERROR_IDX_supply_motor_fail, // Steam Generator Tank Supply Pump + ERROR_IDX_humidity_tamper_fail +}; + +enum USE_ITEMS_IDX{ + USE_ITEM_steam_heat=0, + USE_ITEM_dry_heat, + USE_ITEM_upper_heat, + USE_ITEM_lower_heat, + USE_ITEM_cook_dry_mode, + USE_ITEM_cook_steam_mode, + USE_ITEM_cook_combi_mode, + USE_ITEM_wash_mode_nocleanser, + USE_ITEM_wash_mode_simple, + USE_ITEM_wash_mode_standard, + USE_ITEM_wash_mode_strong, + USE_ITEM_wash_mode_speed, + USE_ITEM_cooldown_mode, + USE_ITEM_door_open, + USE_ITEM_dv_open, + USE_ITEM_ssv_open, + USE_ITEM_qnv_open, + USE_ITEM_ssp_open, + USE_ITEM_snv_open, + USE_ITEM_hosereel, + USE_ITEM_hdm_open, + USE_ITEM_dp_open, + USE_ITEM_unp_open +}; + + + + +typedef union _use_statics_log{ + uint8_t data[MAX_STATICS_CNT*4]; + uint32_t values[MAX_STATICS_CNT]; + struct{ + uint32_t steam_heat; + uint32_t dry_heat; + uint32_t upper_heat; + uint32_t lower_heat; + uint32_t cook_dry_mode; + uint32_t cook_steam_mode; + uint32_t cook_combi_mode; + uint32_t wash_mode_nocleanser; + uint32_t wash_mode_simple; + uint32_t wash_mode_standard; + uint32_t wash_mode_strong; + uint32_t wash_mode_speed; + uint32_t cooldown_mode; + uint32_t door_open; + uint32_t dv_open; + uint32_t ssv_open; + uint32_t qnv_open; + uint32_t ssp_open; + uint32_t snv_open; + uint32_t hosereel; + uint32_t hdm_open; + uint32_t dp_open; + uint32_t unp_open; + }items; +}STRUCT_PACK use_statics_log; + +class ServiceData +{ +public: + ServiceData(); + + + error_log err_log; + use_statics_log use_log; + sensor_statics_log sensor_log; + uint16_t m_nRepeatErrorIdx; + bool saveServiceData(void); + bool loadServiceData(void); +}; + +#endif // SERVICEDATA_H diff --git a/app/gui/oven_control/servicedatas.cpp b/app/gui/oven_control/servicedatas.cpp deleted file mode 100644 index 62c0586..0000000 --- a/app/gui/oven_control/servicedatas.cpp +++ /dev/null @@ -1,113 +0,0 @@ -#include "string.h" -#include "servicedatas.h" -#include -#include -#include // write(), close() - -#define FRAM_SIZE 2048 -#define FRAM_TEST_PROCESS 0 - -#define fRam_path "/sys/bus/spi/devices/spi0.0/fram" -#define INIT_FRAM 1 - - -servicedatas::servicedatas() -{ - qDebug()<< "Statics Data Size Report\r\n error_log size = " << sizeof(error_log) << " \r\nuse_static_log size = " << sizeof(use_statics_log) \ - << "\r\nsensor_statics_log size = " << sizeof(sensor_statics_log); - memset((void*)err_log.datas,0x00,sizeof(error_log)); - memset((void*)use_log.datas,0x00,sizeof(use_statics_log)); - memset((void*)sensor_log.datas,0x00, sizeof(sensor_statics_log)); -#if INIT_FRAM == 1 - saveServiceDatas(); -#else - loadServiceDatas(); -#endif -} - - - -bool servicedatas::loadServiceDatas(void){ - uint8_t buffs[FRAM_SIZE]; - int fd; - -#if FRAM_TEST_PROCESS == 1 - int i; - memset(buffs,0x00,256); - for(i=0;i<256;i++){ - buffs[i] = i; - } - fd = open(fRam_path, O_RDWR); - if(fd>0){ - write(fd,buffs,256); - close(fd); - } - else{ - qDebug()<<"FRAM open fail!"; - return false; - } - i=0; - memset(buffs,0x00,256); - fd = open(fRam_path, O_RDONLY ); - if(fd>0){ - read(fd,buffs,256); - close(fd); - }else{ - qDebug()<<"FRAM open fail!"; - return false; - } - for(i=0;i<256;i++){ - if(i !=buffs[i]) { - qDebug()<<"FRAM Test Fail"; - return false; - } - } - qDebug()<<"FRAM Test Success!"; - return true; -#endif - - - - - - - fd = open(fRam_path, O_RDONLY ); - if(fd>0){ - memset(buffs,0x00,FRAM_SIZE); - read(fd,buffs,FRAM_SIZE); - if(buffs[sizeof(error_log) + sizeof(use_statics_log) + sizeof(sensor_statics_log)] != 0x9C){ - close(fd); - return saveServiceDatas(); - } - - qDebug() << "FRAM Read, Write Size is " << sizeof(error_log)+sizeof(use_statics_log); - memcpy((void*)err_log.datas,buffs,sizeof(error_log)); - memcpy((void*)use_log.datas, (void*)(&buffs[sizeof(error_log)]),sizeof(use_statics_log)); - memcpy((void*)sensor_log.datas,(void*)(&buffs[sizeof(error_log) + sizeof(use_statics_log)]),sizeof(sensor_statics_log)); - close(fd); - }else{ - qDebug()<<"FRAM FILE Open fail!!"; - } - return true; -} - -bool servicedatas::saveServiceDatas(void){ - uint8_t buffs[FRAM_SIZE]; - int fd; - fd = open(fRam_path, O_RDWR | O_SYNC); - if(fd>0){ - memset(buffs,0x00,FRAM_SIZE); - memcpy(buffs,(void*)err_log.datas,sizeof(error_log)); - memcpy((void*)(&buffs[sizeof(error_log)]),(void*)use_log.datas,sizeof(use_statics_log)); - memcpy((void*)(&buffs[sizeof(error_log) + sizeof(use_statics_log)]),(void*)sensor_log.datas,sizeof(sensor_statics_log)); - buffs[sizeof(error_log) + sizeof(use_statics_log) + sizeof(sensor_statics_log)] = 0x9C; - write(fd,buffs,FRAM_SIZE); - close(fd); - }else{ - qDebug()<<"FRAM FILE Open fail!!"; - return false; - } - return true; -} - - diff --git a/app/gui/oven_control/servicedatas.h b/app/gui/oven_control/servicedatas.h deleted file mode 100644 index bff96f6..0000000 --- a/app/gui/oven_control/servicedatas.h +++ /dev/null @@ -1,201 +0,0 @@ -#ifndef SERVICEDATAS_H -#define SERVICEDATAS_H - -#include -#include - -#define STRUCT_PACK __attribute__ ((packed)) - -#define MAX_ERROR_TYPE_CNT 31 - -#define MAX_STATICS_CNT 23 - -#define MAX_LOG_SENSOR 16 - -typedef struct _error_item{ - uint16_t fired_cnt; - time_t first_fired; - time_t last_fried; -}STRUCT_PACK error_item; - -typedef union{ - int16_t itemp; - uint16_t utemp; -}type_temp; - -typedef struct _sensor_log_item{ - type_temp high_temp; - time_t last_high_time; -}STRUCT_PACK sensor_log_item; - - -typedef union _sensor_statics_log{ - uint8_t datas[MAX_LOG_SENSOR * sizeof(sensor_log_item)]; - sensor_log_item values[MAX_LOG_SENSOR]; - struct{ - sensor_log_item B1; - sensor_log_item B2; - sensor_log_item Reserved1; - sensor_log_item B4; - sensor_log_item B5; - sensor_log_item B3_1; - sensor_log_item B3_2; - sensor_log_item B3_3; - sensor_log_item B3_4; - sensor_log_item Reserved2; //10 - sensor_log_item mbar1; - sensor_log_item mbar2; - sensor_log_item pcb; - sensor_log_item adc; - sensor_log_item convec_fan_rpm; - sensor_log_item bunner_rpm; - }items; -}STRUCT_PACK sensor_statics_log; - - - -typedef union _error_log{ - uint8_t datas[MAX_ERROR_TYPE_CNT*sizeof(error_item)]; - error_item values[MAX_ERROR_TYPE_CNT]; - struct{ - error_item door; - error_item upper_fire_fail; - error_item upper_pan_fail; - error_item lower_fire_fail; - error_item lower_pan_fail; - error_item steam_fire_fail; - error_item steam_pan_fail; - error_item water_level_sensor_fail; - error_item water_flow_sensor_fail; - error_item inner_temp_high_alarm; //B1 Sensor - error_item inner_temp_fail; - error_item qunching_temp_high_alarm; //B2 Sensor - error_item qunching_temp_fail; - error_item meatprove_temp1_high_alarm; //B3 Sensor - error_item meatprove_temp1_fail; - error_item wall_temp1_high_alarm; //B4 Sensor - error_item wall_temp1_fail; - error_item steam_gen_temp_high_alram; //B5 Sensor - error_item steam_gen_temp_fail; - error_item meatprove_temp2_fail; - error_item meatprove_temp3_fail; - error_item meatprove_temp4_fail; - error_item pcb_temp_high_alarm; //PCB Temp - error_item pcb_temp_fail; - error_item upper_motor_fail; - error_item lower_motor_fail; - error_item small_motor_fail; - error_item midd_motor_fail; - error_item supply_motor_fail; // Steam Generator Tank Supply Pump - error_item humidity_tamper_fail; - error_item repeat_error; - }items; -}STRUCT_PACK error_log; - -enum ERROR_ITEM_IDX{ - ERROR_IDX_door=0, - ERROR_IDX_upper_fire_fail, - ERROR_IDX_upper_pan_fail, - ERROR_IDX_lower_fire_fail, - ERROR_IDX_lower_pan_fail, - ERROR_IDX_steam_fire_fail, - ERROR_IDX_steam_pan_fail, - ERROR_IDX_water_level_sensor_fail, - ERROR_IDX_water_flow_sensor_fail, - ERROR_IDX_inner_temp_high_alarm, //B1 Sensor - ERROR_IDX_inner_temp_fail, - ERROR_IDX_qunching_temp_high_alarm, //B2 Sensor - ERROR_IDX_qunching_temp_fail, - ERROR_IDX_meatprove_temp1_high_alarm, //B3 Sensor - ERROR_IDX_meatprove_temp1_fail, - ERROR_IDX_wall_temp1_high_alarm, //B4 Sensor - ERROR_IDX_wall_temp1_fail, - ERROR_IDX_steam_gen_temp_high_alram, //B5 Sensor - ERROR_IDX_steam_gen_temp_fail, - ERROR_IDX_meatprove_temp2_fail, - ERROR_IDX_meatprove_temp3_fail, - ERROR_IDX_meatprove_temp4_fail, - ERROR_IDX_pcb_temp_high_alarm, //PCB Temp - ERROR_IDX_pcb_temp_fail, - ERROR_IDX_upper_motor_fail, - ERROR_IDX_lower_motor_fail, - ERROR_IDX_small_motor_fail, - ERROR_IDX_midd_motor_fail, - ERROR_IDX_supply_motor_fail, // Steam Generator Tank Supply Pump - ERROR_IDX_humidity_tamper_fail -}; - -enum USE_ITEMS_IDX{ - USE_ITEM_steam_heat=0, - USE_ITEM_dry_heat, - USE_ITEM_upper_heat, - USE_ITEM_lower_heat, - USE_ITEM_cook_dry_mode, - USE_ITEM_cook_steam_mode, - USE_ITEM_cook_combi_mode, - USE_ITEM_wash_mode_nocleanser, - USE_ITEM_wash_mode_simple, - USE_ITEM_wash_mode_standard, - USE_ITEM_wash_mode_strong, - USE_ITEM_wash_mode_speed, - USE_ITEM_cooldown_mode, - USE_ITEM_door_open, - USE_ITEM_dv_open, - USE_ITEM_ssv_open, - USE_ITEM_qnv_open, - USE_ITEM_ssp_open, - USE_ITEM_snv_open, - USE_ITEM_hosereel, - USE_ITEM_hdm_open, - USE_ITEM_dp_open, - USE_ITEM_unp_open -}; - - - - -typedef union _use_statics_log{ - uint8_t datas[MAX_STATICS_CNT*4]; - uint32_t values[MAX_STATICS_CNT]; - struct{ - uint32_t steam_heat; - uint32_t dry_heat; - uint32_t upper_heat; - uint32_t lower_heat; - uint32_t cook_dry_mode; - uint32_t cook_steam_mode; - uint32_t cook_combi_mode; - uint32_t wash_mode_nocleanser; - uint32_t wash_mode_simple; - uint32_t wash_mode_standard; - uint32_t wash_mode_strong; - uint32_t wash_mode_speed; - uint32_t cooldown_mode; - uint32_t door_open; - uint32_t dv_open; - uint32_t ssv_open; - uint32_t qnv_open; - uint32_t ssp_open; - uint32_t snv_open; - uint32_t hosereel; - uint32_t hdm_open; - uint32_t dp_open; - uint32_t unp_open; - }items; -}STRUCT_PACK use_statics_log; - -class servicedatas -{ -public: - servicedatas(); - - - error_log err_log; - use_statics_log use_log; - sensor_statics_log sensor_log; - uint16_t m_nRepeatErrorIdx; - bool saveServiceDatas(void); - bool loadServiceDatas(void); -}; - -#endif // SERVICEDATAS_H diff --git a/app/gui/oven_control/servicehistorymain.cpp b/app/gui/oven_control/servicehistorymain.cpp index 9812361..eaa9307 100644 --- a/app/gui/oven_control/servicehistorymain.cpp +++ b/app/gui/oven_control/servicehistorymain.cpp @@ -2,46 +2,46 @@ #include "ui_servicehistorymain.h" #include "historylistwindow.h" -serviceHistoryMain::serviceHistoryMain(QWidget *parent) : +ServiceHistoryMain::ServiceHistoryMain(QWidget *parent) : QMainWindow(parent), - ui(new Ui::serviceHistoryMain) + ui(new Ui::ServiceHistoryMain) { ui->setupUi(this); connect(ui->backButton, SIGNAL(released()), this, SLOT(deleteLater())); } -serviceHistoryMain::~serviceHistoryMain() +ServiceHistoryMain::~ServiceHistoryMain() { delete ui; } -void serviceHistoryMain::on_btnUpperBunner_clicked() +void ServiceHistoryMain::on_btnUpperBunner_clicked() { - historyListWindow *w = new historyListWindow(this); + HistoryListWindow *w = new HistoryListWindow(this); w->setWindosDataSet(ERROR_HISTORY_UPPERBUNNER); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); } -void serviceHistoryMain::on_btnSteamBunner_clicked() +void ServiceHistoryMain::on_btnSteamBunner_clicked() { - historyListWindow *w = new historyListWindow(this); + HistoryListWindow *w = new HistoryListWindow(this); w->setWindosDataSet(ERROR_HISTORY_STEAMBUNNER); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); } -void serviceHistoryMain::on_btnLowerBunner_clicked() +void ServiceHistoryMain::on_btnLowerBunner_clicked() { - historyListWindow *w = new historyListWindow(this); + HistoryListWindow *w = new HistoryListWindow(this); w->setWindosDataSet(ERROR_HISTORY_LOWERBUNNER); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); } -void serviceHistoryMain::on_btnErrorTotal_clicked() +void ServiceHistoryMain::on_btnErrorTotal_clicked() { - historyListWindow *w = new historyListWindow(this); + HistoryListWindow *w = new HistoryListWindow(this); w->setWindosDataSet(ERROR_HISTORY_TOTAL); w->setWindowModality(Qt::WindowModal); w->showFullScreen(); diff --git a/app/gui/oven_control/servicehistorymain.h b/app/gui/oven_control/servicehistorymain.h index 39e0a85..bc7bce7 100644 --- a/app/gui/oven_control/servicehistorymain.h +++ b/app/gui/oven_control/servicehistorymain.h @@ -4,16 +4,16 @@ #include namespace Ui { -class serviceHistoryMain; +class ServiceHistoryMain; } -class serviceHistoryMain : public QMainWindow +class ServiceHistoryMain : public QMainWindow { Q_OBJECT public: - explicit serviceHistoryMain(QWidget *parent = 0); - ~serviceHistoryMain(); + explicit ServiceHistoryMain(QWidget *parent = 0); + ~ServiceHistoryMain(); private slots: void on_btnUpperBunner_clicked(); @@ -25,7 +25,7 @@ private slots: void on_btnErrorTotal_clicked(); private: - Ui::serviceHistoryMain *ui; + Ui::ServiceHistoryMain *ui; }; #endif // SERVICEHISTORYMAIN_H diff --git a/app/gui/oven_control/servicehistorymain.ui b/app/gui/oven_control/servicehistorymain.ui index a4e2f17..e832400 100644 --- a/app/gui/oven_control/servicehistorymain.ui +++ b/app/gui/oven_control/servicehistorymain.ui @@ -1,7 +1,7 @@ - serviceHistoryMain - + ServiceHistoryMain + 0