|
|
|
@ -8,19 +8,19 @@
|
|
|
|
|
#include <QtCore\qprocess.h>
|
|
|
|
|
#include "exportData.h"
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
int g_op_time; //OP权限时长(默认300秒)
|
|
|
|
|
|
|
|
|
|
int g_admin_time; //ADMINOP权限时长(默认300秒)
|
|
|
|
|
int g_op_time; //操作员权限时长(默认300秒)
|
|
|
|
|
int g_admin_time; //管理员操作权限时长(默认300秒)
|
|
|
|
|
|
|
|
|
|
int rotationAngle[NumberOfSupportedCameras]; //图片旋转角度
|
|
|
|
|
bool isNeddRotate[NumberOfSupportedCameras];
|
|
|
|
|
bool isNeedRotate[NumberOfSupportedCameras];
|
|
|
|
|
|
|
|
|
|
SysConf g_sys_conf; //系统配置参数
|
|
|
|
|
ModbusConf g_modbus_conf; //modbus地址
|
|
|
|
|
DisplayLabelConf g_display_label_conf[NumberOfSupportedCameras];
|
|
|
|
|
|
|
|
|
|
SysConf g_sys_conf; //系统配置参数
|
|
|
|
|
ModbusConf g_modbus_conf; //modbus地址参数
|
|
|
|
|
PLCDevice * m_PLCDevice;
|
|
|
|
|
bool g_plc_dialog_open; //是否打开plc配置对话框
|
|
|
|
|
|
|
|
|
|
QDateTime g_ts_start;
|
|
|
|
|
|
|
|
|
|
extern SingleCamInfoStruct SingleCamInfo[NumberOfSupportedCameras];
|
|
|
|
@ -50,8 +50,9 @@ ASyncQueue<bool> *g_shooted_queue[NumberOfSupportedCameras]; //
|
|
|
|
|
ASyncQueue<bool> *g_result_wait_queue[NumberOfSupportedCameras]; //
|
|
|
|
|
ASyncQueue<bool> *g_double_queue[NumberOfSupportedCameras]; //
|
|
|
|
|
ASyncQueue<bool> *g_result_queue[NumberOfSupportedCameras]; //
|
|
|
|
|
bool g_debug_mode; //相机调试模式,调试模式必须暂停状态才能打开
|
|
|
|
|
bool g_debug_mode; //相机调试模式,工作模式必须暂停状态才能打开
|
|
|
|
|
SyncQueue<cv::Mat> *g_debug_queue[NumberOfSupportedCameras]; //相机调试模式图像队列
|
|
|
|
|
|
|
|
|
|
SyncQueue<_UDPSendInfo> *UDP_Info_queue;
|
|
|
|
|
SyncQueue<_ExportDataInfo> *export_Data_Info_queue;
|
|
|
|
|
ExportDataThread exportDataThread;
|
|
|
|
@ -64,16 +65,12 @@ bool g_op_mode; //
|
|
|
|
|
|
|
|
|
|
QString g_op_pswd; //操作员密码
|
|
|
|
|
|
|
|
|
|
bool g_plc_dialog_open; //是否打开plc配置对话框
|
|
|
|
|
|
|
|
|
|
bool g_working; //true 开始工作状态; false 暂停工作状态
|
|
|
|
|
bool g_working; //true 开始工作状态; false 停止工作状态
|
|
|
|
|
|
|
|
|
|
int last_shift; //记录上一次班
|
|
|
|
|
|
|
|
|
|
QStringList g_alarm_msg;
|
|
|
|
|
|
|
|
|
|
std::vector<AlarmInfo> g_vec_alarm;
|
|
|
|
|
|
|
|
|
|
int g_last_alarm_code;
|
|
|
|
|
|
|
|
|
|
int g_lst_quantiy; //上一秒的产量
|
|
|
|
@ -141,7 +138,7 @@ Cigarette::Cigarette(QWidget *parent)
|
|
|
|
|
g_debug_queue[i]->name = format("debug_%d", i);
|
|
|
|
|
if (update_rotate) {
|
|
|
|
|
rotationAngle[i] = cv::ROTATE_90_COUNTERCLOCKWISE + 1;
|
|
|
|
|
isNeddRotate[i] = false;
|
|
|
|
|
isNeedRotate[i] = false;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
if (update_rotate) {
|
|
|
|
@ -151,7 +148,7 @@ Cigarette::Cigarette(QWidget *parent)
|
|
|
|
|
}
|
|
|
|
|
g_debug_mode = false;
|
|
|
|
|
|
|
|
|
|
g_admin_mode = true;
|
|
|
|
|
g_admin_mode = false;
|
|
|
|
|
g_admin_time = ADMIN_TIME;
|
|
|
|
|
|
|
|
|
|
g_admin_pswd = read_pswd();
|
|
|
|
@ -178,7 +175,6 @@ Cigarette::Cigarette(QWidget *parent)
|
|
|
|
|
|
|
|
|
|
g_last_alarm_code = 0;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
g_ts_start = QDateTime::currentDateTime();
|
|
|
|
|
|
|
|
|
|
for(int i=0;i<NumberOfSupportedCameras;i++)
|
|
|
|
@ -192,7 +188,9 @@ Cigarette::Cigarette(QWidget *parent)
|
|
|
|
|
ng[i] = 0;
|
|
|
|
|
g_display_label_conf[i].g_last_mat[0] = cv::Mat::zeros(20, 20, CV_8UC3);
|
|
|
|
|
g_display_label_conf[i].g_last_mat[1] = cv::Mat::zeros(20, 20, CV_8UC3);
|
|
|
|
|
#ifdef DRAW_RECT
|
|
|
|
|
DrawRect_init(i);
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
ui.lcdNumber_total_no->display(0);
|
|
|
|
|
ui.lcdNumber_total_no_last->display(0);
|
|
|
|
@ -205,14 +203,6 @@ Cigarette::Cigarette(QWidget *parent)
|
|
|
|
|
|
|
|
|
|
read_sys_config(g_sys_conf); //初始化系统配置
|
|
|
|
|
|
|
|
|
|
//g_modbus_conf.kick1 = 0;
|
|
|
|
|
//g_modbus_conf.kick2 = 0;
|
|
|
|
|
//g_modbus_conf.kick3 = 0;
|
|
|
|
|
//g_modbus_conf.kick4 = 0;
|
|
|
|
|
//g_modbus_conf.kick5 = 0;
|
|
|
|
|
//g_modbus_conf.kick6 = 0;
|
|
|
|
|
//g_modbus_conf.kick7 = 0;
|
|
|
|
|
//g_modbus_conf.kick8 = 0;
|
|
|
|
|
#if defined(NumberOfSupportedCameras) && (NumberOfSupportedCameras>0)
|
|
|
|
|
g_modbus_conf.kick1 = 0; //1#通道剔除个数地址
|
|
|
|
|
#endif
|
|
|
|
@ -226,16 +216,16 @@ Cigarette::Cigarette(QWidget *parent)
|
|
|
|
|
g_modbus_conf.kick4 = 0; //4#通道剔除个数地址
|
|
|
|
|
#endif
|
|
|
|
|
#if defined(NumberOfSupportedCameras) && (NumberOfSupportedCameras>4)
|
|
|
|
|
g_modbus_conf.kick5 = 0; //1#通道剔除个数地址
|
|
|
|
|
g_modbus_conf.kick5 = 0; //5#通道剔除个数地址
|
|
|
|
|
#endif
|
|
|
|
|
#if defined(NumberOfSupportedCameras) && (NumberOfSupportedCameras>5)
|
|
|
|
|
g_modbus_conf.kick6 = 0; //2#通道剔除个数地址
|
|
|
|
|
g_modbus_conf.kick6 = 0; //6#通道剔除个数地址
|
|
|
|
|
#endif
|
|
|
|
|
#if defined(NumberOfSupportedCameras) && (NumberOfSupportedCameras>6)
|
|
|
|
|
g_modbus_conf.kick7 = 0; //3#通道剔除个数地址
|
|
|
|
|
g_modbus_conf.kick7 = 0; //7#通道剔除个数地址
|
|
|
|
|
#endif
|
|
|
|
|
#if defined(NumberOfSupportedCameras) && (NumberOfSupportedCameras>7)
|
|
|
|
|
g_modbus_conf.kick8 = 0; //4#通道剔除个数地址
|
|
|
|
|
g_modbus_conf.kick8 = 0; //8#通道剔除个数地址
|
|
|
|
|
#endif
|
|
|
|
|
g_modbus_conf.quantity = 0;
|
|
|
|
|
g_modbus_conf.shift = 0;
|
|
|
|
@ -314,17 +304,71 @@ Cigarette::Cigarette(QWidget *parent)
|
|
|
|
|
{
|
|
|
|
|
if(SingleCamInfo[i].Detect){
|
|
|
|
|
cam_status_mat[i]->setStyleSheet(tr("background-color: rgb(0, 170, 0);"));
|
|
|
|
|
if (!alg_jd[i].init(g_sys_conf.path_model,g_sys_conf.model_name))
|
|
|
|
|
QString model_path, model_name;
|
|
|
|
|
if (g_sys_conf.model_path.isEmpty()) {
|
|
|
|
|
model_path = "D:/model";
|
|
|
|
|
g_sys_conf.model_path = "D:/model";
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
model_path = g_sys_conf.model_path;
|
|
|
|
|
|
|
|
|
|
if (g_sys_conf.model_name.isEmpty()) {
|
|
|
|
|
model_name = "jd.weights";
|
|
|
|
|
g_sys_conf.model_name = "jd.weights";
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
model_name = g_sys_conf.model_name;
|
|
|
|
|
|
|
|
|
|
if (!alg_jd[i].init(model_path, model_name))
|
|
|
|
|
{
|
|
|
|
|
QMessageBox::information(NULL, QStringLiteral("系统自检失败"), QStringLiteral("AI模型1初始化失败,请检查程序完整性"), QMessageBox::Ok);
|
|
|
|
|
exit(-1);
|
|
|
|
|
}
|
|
|
|
|
CreatWorkThread(SingleCamInfo[i].CamClass, i, this);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
#ifdef __DEBUG
|
|
|
|
|
alg_test.init(g_sys_conf.path_model,g_sys_conf.path_jpg);
|
|
|
|
|
else {
|
|
|
|
|
QDateTime ts_start = QDateTime::currentDateTime();
|
|
|
|
|
QTime time = QTime::currentTime();
|
|
|
|
|
QDateTime local(ts_start);
|
|
|
|
|
QString localTime = local.toString("yyyy-MM-dd hh:mm:ss");
|
|
|
|
|
|
|
|
|
|
if (g_modbus_conf.alarm > 0)
|
|
|
|
|
{
|
|
|
|
|
uint16_t dest16[2] = { 5+i,0 };
|
|
|
|
|
int ret = m_PLCDevice->write_short_2_plc(g_modbus_conf.alarm, 2, dest16);
|
|
|
|
|
//if (ret > 0) SingleCamInfo[0].OffLine = false;
|
|
|
|
|
|
|
|
|
|
if (ret > 0)
|
|
|
|
|
{
|
|
|
|
|
AlarmInfo alarm_info;
|
|
|
|
|
alarm_info.alarm_code = dest16[0];
|
|
|
|
|
if ((alarm_info.alarm_code > 0) && (alarm_info.alarm_code <= 12))
|
|
|
|
|
{
|
|
|
|
|
alarm_info.alarm_msg = (g_alarm_msg[alarm_info.alarm_code]).toStdString();
|
|
|
|
|
alarm_info.alarm_start = localTime.toStdString();
|
|
|
|
|
ui.label_alarm->setText(g_alarm_msg[alarm_info.alarm_code]);
|
|
|
|
|
ui.label_alarm->setStyleSheet(tr("background-color: rgb(255, 0, 0);"));
|
|
|
|
|
if (g_last_alarm_code != alarm_info.alarm_code)
|
|
|
|
|
{
|
|
|
|
|
g_vec_alarm.push_back(alarm_info);
|
|
|
|
|
g_last_alarm_code = alarm_info.alarm_code;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
else if (alarm_info.alarm_code == 0) {
|
|
|
|
|
ui.label_alarm->setStyleSheet(tr("background-color: rgb(0, 170, 0);"));
|
|
|
|
|
ui.label_alarm->setText(QStringLiteral("无报警"));
|
|
|
|
|
}
|
|
|
|
|
#ifdef __UDPSend
|
|
|
|
|
QString str;
|
|
|
|
|
str = QString("alarm") + '_' + QString::number(alarm_info.alarm_code);
|
|
|
|
|
sThread.sendData(str, g_sys_conf.FeedbackPort);
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//自动打开所有相机
|
|
|
|
|
if (g_sys_conf.auto_open == 1)
|
|
|
|
|
{
|
|
|
|
@ -403,8 +447,10 @@ Cigarette::Cigarette(QWidget *parent)
|
|
|
|
|
connect(pTimer_Cam_signalMapper, SIGNAL(mapped(int)), this, SLOT(OpenCamTimeoutHub(int)));
|
|
|
|
|
connect(image_lable_DBsignalMapper0, SIGNAL(mapped(int)), this, SLOT(OnDBClickHub(int)));
|
|
|
|
|
connect(image_lable_DBsignalMapper1, SIGNAL(mapped(int)), this, SLOT(OnDBClickHub(int)));
|
|
|
|
|
#ifdef DRAW_RECT
|
|
|
|
|
connect(image_lable_TPsignalMapper0, SIGNAL(mapped(int)), this, SLOT(OnTPClickHub(int)));
|
|
|
|
|
connect(image_lable_TPsignalMapper1, SIGNAL(mapped(int)), this, SLOT(OnTPClickHub(int)));
|
|
|
|
|
#endif
|
|
|
|
|
connect(label_ng_signalMapper, SIGNAL(mapped(int)), this, SLOT(OnDBClickNGHub(int)));
|
|
|
|
|
connect(RotateReleased_signalMapper, SIGNAL(mapped(int)), this, SLOT(OnRotateReleasedHub(int)));
|
|
|
|
|
|
|
|
|
@ -805,7 +851,7 @@ void Cigarette::OnRotateReleasedHub(int Num)//
|
|
|
|
|
{
|
|
|
|
|
QString str = "Start to rotate picture " + QString::number(90 * ((rotationAngle[Num] + 1) % 4)) + " degrees of camera " + QString::number(Num) + ".";
|
|
|
|
|
emit sengMsgToClog(str);
|
|
|
|
|
if(isNeddRotate[Num] == true)
|
|
|
|
|
if(isNeedRotate[Num] == true)
|
|
|
|
|
{
|
|
|
|
|
rotationAngle[Num] = (rotationAngle[Num] + 1) % 4;
|
|
|
|
|
save_rotate_message();
|
|
|
|
@ -1048,7 +1094,7 @@ void Cigarette::DrawRect_init(int Num_Cnt) {
|
|
|
|
|
cfg_file.open(buf);
|
|
|
|
|
if (!cfg_file.is_open())
|
|
|
|
|
{
|
|
|
|
|
std::cout << "Error: Open config file SelectRects.txt" << std::endl;
|
|
|
|
|
std::cout << "Error: Open config file SelectRects"<<Num<<Cnt<<".txt" << std::endl;
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
while (!cfg_file.eof())
|
|
|
|
@ -1299,6 +1345,7 @@ void Cigarette::on_checkBox_debug_clicked(bool checked)
|
|
|
|
|
#endif
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
//打开PLC配置对话框
|
|
|
|
|
void Cigarette::on_toolButton_plc_released()
|
|
|
|
|
{
|
|
|
|
@ -1322,9 +1369,6 @@ void Cigarette::on_toolButton_plc_released()
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
//操作员权限剩余时间
|
|
|
|
|
void Cigarette::op_timeout()
|
|
|
|
|
{
|
|
|
|
@ -2145,7 +2189,7 @@ bool Cigarette::read_sys_config(SysConf &conf)
|
|
|
|
|
}
|
|
|
|
|
else if (tmp_key == "MODELPATH")
|
|
|
|
|
{
|
|
|
|
|
conf.path_model = line.substr(pos + 1).c_str();
|
|
|
|
|
conf.model_path = line.substr(pos + 1).c_str();
|
|
|
|
|
}
|
|
|
|
|
else if (tmp_key == "MODELNAME")
|
|
|
|
|
{
|
|
|
|
@ -2153,7 +2197,7 @@ bool Cigarette::read_sys_config(SysConf &conf)
|
|
|
|
|
}
|
|
|
|
|
else if (tmp_key == "JPGPATH")
|
|
|
|
|
{
|
|
|
|
|
conf.path_jpg = line.substr(pos + 1).c_str();
|
|
|
|
|
conf.jpg_path = line.substr(pos + 1).c_str();
|
|
|
|
|
}
|
|
|
|
|
#if defined(NumberOfSupportedCameras) && (NumberOfSupportedCameras>0)
|
|
|
|
|
else if (tmp_key == "EXPO1")
|
|
|
|
@ -2560,7 +2604,7 @@ bool Cigarette::read_rotate_message()
|
|
|
|
|
if (rotate_message.length() > NumberOfSupportedCameras*2)
|
|
|
|
|
{
|
|
|
|
|
for (int i = 0; i < NumberOfSupportedCameras; i++) {
|
|
|
|
|
isNeddRotate[i] = rotate_message[i * 2].toInt();
|
|
|
|
|
isNeedRotate[i] = rotate_message[i * 2].toInt();
|
|
|
|
|
rotationAngle[i] = rotate_message[i * 2 + 1].toInt();
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -2590,7 +2634,7 @@ bool Cigarette::save_rotate_message()
|
|
|
|
|
for (int i = 0; i < NumberOfSupportedCameras; i++) {
|
|
|
|
|
char tmp[8];
|
|
|
|
|
memset(tmp, 0, 8);
|
|
|
|
|
itoa(isNeddRotate[i], tmp, 10);
|
|
|
|
|
itoa(isNeedRotate[i], tmp, 10);
|
|
|
|
|
cfg_file.write(tmp, 1);
|
|
|
|
|
cfg_file.write(",", 1);
|
|
|
|
|
memset(tmp, 0, 8);
|
|
|
|
@ -2860,7 +2904,6 @@ bool Cigarette::ControlCamOpenOrClose(int Num,bool OpenOrClose)
|
|
|
|
|
pCaptureThread[Num]->p_result_wait_queue = g_result_wait_queue[Num];
|
|
|
|
|
pCaptureThread[Num]->p_double_queue = g_double_queue[Num];
|
|
|
|
|
pCaptureThread[Num]->p_shooted_queue = g_shooted_queue[Num];
|
|
|
|
|
|
|
|
|
|
pCaptureThread[Num]->p_debug_queue = g_debug_queue[Num];
|
|
|
|
|
|
|
|
|
|
pThread[Num] = new QThread;
|
|
|
|
@ -2871,7 +2914,8 @@ bool Cigarette::ControlCamOpenOrClose(int Num,bool OpenOrClose)
|
|
|
|
|
//connect(pCaptureThread[Num], SIGNAL(error(QString)), this, SLOT(errorString(QString)));
|
|
|
|
|
connect(pCaptureThread[Num], SIGNAL(finished()), pThread[Num], SLOT(quit()));
|
|
|
|
|
connect(pCaptureThread[Num], SIGNAL(finished()), pCaptureThread[Num], SLOT(deleteLater()));
|
|
|
|
|
connect(pCaptureThread[Num], SIGNAL(updateStatistics(const QString&,int)), this, SLOT(updateStatisticsHub(const QString&,int)));
|
|
|
|
|
if(!g_debug_mode)
|
|
|
|
|
connect(pCaptureThread[Num], SIGNAL(updateStatistics(const QString&,int)), this, SLOT(updateStatisticsHub(const QString&,int)));
|
|
|
|
|
|
|
|
|
|
pThread[Num]->start();
|
|
|
|
|
if (pThread[Num]->isRunning())
|
|
|
|
@ -2987,7 +3031,8 @@ bool Cigarette::ControlCamOpenOrClose(int Num,bool OpenOrClose)
|
|
|
|
|
//connect(pBaslerCaptureThread[Num], SIGNAL(error(QString)), this, SLOT(errorString(QString)));
|
|
|
|
|
connect(pBaslerCaptureThread[Num], SIGNAL(finished()), pThread[Num], SLOT(quit()));
|
|
|
|
|
connect(pBaslerCaptureThread[Num], SIGNAL(finished()), pBaslerCaptureThread[Num], SLOT(deleteLater()));
|
|
|
|
|
connect(pBaslerCaptureThread[Num], SIGNAL(updateStatistics(const QString&, int)), this, SLOT(updateStatisticsHub(const QString&, int)));
|
|
|
|
|
if(!g_debug_mode)
|
|
|
|
|
connect(pBaslerCaptureThread[Num], SIGNAL(updateStatistics(const QString&, int)), this, SLOT(updateStatisticsHub(const QString&, int)));
|
|
|
|
|
|
|
|
|
|
pThread[Num]->start();
|
|
|
|
|
if (pThread[Num]->isRunning())
|
|
|
|
@ -3110,7 +3155,8 @@ bool Cigarette::ControlCamOpenOrClose(int Num,bool OpenOrClose)
|
|
|
|
|
//connect(pHIKCaptureThread[Num], SIGNAL(error(QString)), this, SLOT(errorString(QString)));
|
|
|
|
|
connect(pHIKCaptureThread[Num], SIGNAL(finished()), pThread[Num], SLOT(quit()));
|
|
|
|
|
connect(pHIKCaptureThread[Num], SIGNAL(finished()), pHIKCaptureThread[Num], SLOT(deleteLater()));
|
|
|
|
|
connect(pHIKCaptureThread[Num], SIGNAL(updateStatistics(const QString&,int)), this, SLOT(updateStatisticsHub(const QString&,int)));
|
|
|
|
|
if (!g_debug_mode)
|
|
|
|
|
connect(pHIKCaptureThread[Num], SIGNAL(updateStatistics(const QString&,int)), this, SLOT(updateStatisticsHub(const QString&,int)));
|
|
|
|
|
pThread[Num]->start();
|
|
|
|
|
if (pThread[Num]->isRunning())
|
|
|
|
|
{
|
|
|
|
@ -3222,6 +3268,7 @@ void Cigarette::EnumerateCameras(SingleCamInfoStruct *TempSingleCamInfoStruct,bo
|
|
|
|
|
filtered = BaslerCamera::Enumerate();
|
|
|
|
|
Pylon::CInstantCameraArray cameras(filtered);
|
|
|
|
|
Pylon::CTlFactory& tlFactory = Pylon::CTlFactory::GetInstance();
|
|
|
|
|
|
|
|
|
|
for (int i = 0; i < min(filtered, NumberOfSupportedCameras); i++)
|
|
|
|
|
{
|
|
|
|
|
SingleCamInfoStruct CamInfo;
|
|
|
|
@ -3386,7 +3433,6 @@ void Cigarette::EnableDebugMode()
|
|
|
|
|
else if(SingleCamInfo[i].CamClass == HIKClassID)
|
|
|
|
|
{
|
|
|
|
|
int nRet = MV_OK;
|
|
|
|
|
|
|
|
|
|
MV_CC_SetFrameRate(HIKCamHandle[i], 10.0);
|
|
|
|
|
nRet = MV_CC_SetBoolValue(HIKCamHandle[i], "AcquisitionFrameRateEnable",true);
|
|
|
|
|
if (nRet) { std::cout << "can not set Hik's AcquisitionFrameRateEnable" << std::endl;}
|
|
|
|
@ -3417,6 +3463,7 @@ void Cigarette::EnableDebugMode()
|
|
|
|
|
}
|
|
|
|
|
g_debug_mode = true;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void Cigarette::DisableDebugMode()
|
|
|
|
|
{
|
|
|
|
|
for(int i=0;i<NumberOfSupportedCameras;i++)
|
|
|
|
@ -3467,7 +3514,6 @@ void Cigarette::DisableDebugMode()
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
g_debug_mode = false;
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void Cigarette::CleanThreadStart()
|
|
|
|
@ -3896,7 +3942,7 @@ void Cigarette::recMsgFromUdp(QString data)
|
|
|
|
|
qDebug() << "g_admin_pswd md5:" << g_admin_pswd;
|
|
|
|
|
if (md5Str.compare(g_admin_pswd, Qt::CaseInsensitive) == 0)///
|
|
|
|
|
{
|
|
|
|
|
g_admin_mode = false;
|
|
|
|
|
g_admin_mode = true;
|
|
|
|
|
OnAdmin();
|
|
|
|
|
sThread.sendData("LoginIn", g_sys_conf.FeedbackPort);
|
|
|
|
|
}
|
|
|
|
|