去掉代码中多余的部分
This commit is contained in:
parent
176b573457
commit
4358142573
@ -382,29 +382,7 @@ void Calculation::FFTSpec(std::vector<float> & vecData, std::vector<float> & vec
|
||||
|
||||
void Calculation::envSpec(std::vector<float> & vecData, std::vector<float> & vecEnvSpecData,int StartFrequency,int EndFrequency)
|
||||
{
|
||||
/*std::vector<float> vecDropMeanData;
|
||||
drop_mean(vecDropMeanData, vecData);
|
||||
|
||||
std::vector<float> vecHilbertData;
|
||||
hilbert(vecDropMeanData, vecHilbertData, vecDropMeanData.size());
|
||||
|
||||
fftw_complex *inHilFFt, *outHilFFt;
|
||||
inHilFFt = (fftw_complex *)fftw_malloc(sizeof(fftw_complex) * vecHilbertData.size());
|
||||
outHilFFt = (fftw_complex *)fftw_malloc(sizeof(fftw_complex) * vecHilbertData.size());
|
||||
|
||||
for (int j = 0; j < vecHilbertData.size(); j++) {
|
||||
inHilFFt[j][0] = (double)vecHilbertData[j];
|
||||
inHilFFt[j][1] = 0;
|
||||
}
|
||||
|
||||
FFT(vecHilbertData.size(), inHilFFt, outHilFFt);
|
||||
fftShift(outHilFFt, vecHilbertData.size());
|
||||
|
||||
vecEnvSpecData.push_back(0);
|
||||
for (int i = vecHilbertData.size() / 2 + 1; i < vecHilbertData.size(); i++) {
|
||||
float ftemp = 2 * sqrt(outHilFFt[i][0] * outHilFFt[i][0] + outHilFFt[i][1] * outHilFFt[i][1]) / vecHilbertData.size();
|
||||
vecEnvSpecData.push_back(ftemp);
|
||||
}*/
|
||||
std::vector<float> vecFFTrealData,vecFFTimageData;
|
||||
std::vector<float> vecRealData,vecImageData;
|
||||
std::vector<float> veciFFtData;
|
||||
@ -475,72 +453,5 @@ void Calculation::Integration(std::vector<float> & vecData,std::vector<float>& r
|
||||
}
|
||||
|
||||
_iFFT(realvalue,imagevalue,retData);
|
||||
|
||||
// for (size_t i = 0; i < ifftData.size(); i++)
|
||||
// {
|
||||
// retData.push_back( ifftData[i] * 2);
|
||||
// }
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
/*void acceleration_to_velocity(int fs, int N, float *data, int min_freq, int max_freq, float *out_data) {
|
||||
fftwf_execute_dft_r2c(forward_plan[fft_plan_id(N)], data, forward_out);
|
||||
|
||||
float df = fs * 1.0f / N;
|
||||
int ni = round(min_freq / df);
|
||||
int na = round(max_freq / df);
|
||||
float dw = 2 * fcl_pi * df;
|
||||
|
||||
int double_id = get_idle_double_res();
|
||||
if (double_id < 0) {
|
||||
return;
|
||||
}
|
||||
float *w11 = get_double_res_ptr(double_id);
|
||||
|
||||
int len = 0;
|
||||
int max_f = round((0.5 * fs - df) / df);
|
||||
|
||||
for (int i = 0; i <= max_f; ++i) {
|
||||
w11[i] = i * dw;
|
||||
++len;
|
||||
}
|
||||
|
||||
for (int i = 0; i < max_f; ++i) {
|
||||
w11[len] = -2 * fcl_pi * (0.5 * fs - df) + i * dw;
|
||||
++len;
|
||||
}
|
||||
|
||||
forward_out[0][0] = forward_out[0][1] = forward_out[N - 1][0] = forward_out[N - 1][1] = 0;
|
||||
float tmp_real, tmp_imag;
|
||||
for (int i = 1; i < N - 1; ++i) {
|
||||
tmp_real = forward_out[i][1] / w11[i];
|
||||
tmp_imag = -forward_out[i][0] / w11[i];
|
||||
forward_out[i][0] = tmp_real; // real
|
||||
forward_out[i][1] = tmp_imag; // imag
|
||||
}
|
||||
|
||||
free_double_res(double_id);
|
||||
|
||||
for (int i = 0; i < N; ++i) {
|
||||
backward_in[i][0] = 0;
|
||||
backward_in[i][1] = 0;
|
||||
}
|
||||
|
||||
for (int i = ni - 1; i < na; ++i) {
|
||||
backward_in[i][0] = forward_out[i][0];
|
||||
backward_in[i][1] = forward_out[i][1];
|
||||
}
|
||||
|
||||
for (int i = N - na; i < N - ni + 1; ++i) {
|
||||
backward_in[i][0] = forward_out[i][0];
|
||||
backward_in[i][1] = forward_out[i][1];
|
||||
}
|
||||
|
||||
fftwf_execute_dft(backward_plan[fft_plan_id(N)], backward_in, backward_out);
|
||||
|
||||
for (int i = 0; i < N; ++i) {
|
||||
out_data[i] = backward_out[i][0] / N * 2 * 1000; // *1000 是单位换算, 跟python保持一致
|
||||
}
|
||||
}*/
|
||||
|
||||
@ -2330,31 +2330,6 @@ int socketHeart(const char* pSendData)
|
||||
|
||||
return 0;
|
||||
}
|
||||
//unsigned short cal_chksum(unsigned short *addr, int len)
|
||||
//{
|
||||
// int nleft=len;
|
||||
// int sum=0;
|
||||
// unsigned short *w=addr;
|
||||
// unsigned short answer=0;
|
||||
//
|
||||
// while(nleft > 1)
|
||||
// {
|
||||
// sum += *w++;
|
||||
// nleft -= 2;
|
||||
// }
|
||||
//
|
||||
// if( nleft == 1)
|
||||
// {
|
||||
// *(unsigned char *)(&answer) = *(unsigned char *)w;
|
||||
// sum += answer;
|
||||
// }
|
||||
//
|
||||
// sum = (sum >> 16) + (sum & 0xffff);
|
||||
// sum += (sum >> 16);
|
||||
// answer = ~sum;
|
||||
//
|
||||
// return answer;
|
||||
//}
|
||||
|
||||
// Ping函数,timeout为超时时间,单位是ms,10000 毫秒=10 秒
|
||||
//成功:返回0,失败:返回1或-1
|
||||
|
||||
@ -24,8 +24,8 @@ enum enumZigBeeTransmitStatus {
|
||||
//#define Q4G_MODULE
|
||||
//#define WIFI_MODULE
|
||||
//#define NR5G_MEIGE
|
||||
//#define G2UL_GATEWAY
|
||||
#define IMX6UL_GATEWAY
|
||||
#define G2UL_GATEWAY
|
||||
//#define IMX6UL_GATEWAY
|
||||
|
||||
class GlobalConfig
|
||||
{
|
||||
|
||||
@ -817,7 +817,7 @@ int SqliteDB::InsertData(const char* tablename, const char* insertValues, int re
|
||||
}
|
||||
sprintf(strSql, "%s %s%s %s %s %s", "insert into", strReplace, tablename, "values(", insertValues, ");");
|
||||
print_light_green("%s\n", strSql);
|
||||
// if (SqlSwitch()) log_system->log_write_system("[info]","%s\n", strSql);
|
||||
|
||||
iRet = sqlite3_exec(GetDbHandle(isDB2), strSql, 0, 0, &msg);
|
||||
|
||||
free(strSql);
|
||||
@ -828,7 +828,7 @@ int SqliteDB::InsertData(const char* tablename, const char* insertValues, int re
|
||||
}
|
||||
strSql = strSql + tablename + " values(" + insertValues + ");";
|
||||
print_light_green("%s\n", strSql.c_str());
|
||||
// if (SqlSwitch()) log_system->log_write_system("[info]","%s\n", strSql.c_str());
|
||||
|
||||
iRet = sqlite3_exec(GetDbHandle(isDB2), strSql.c_str(), 0, 0, &msg);
|
||||
}
|
||||
if (iRet != SQLITE_OK) {
|
||||
@ -913,7 +913,7 @@ int SqliteDB::CalculateBattery()
|
||||
vector<long> vecsendTime;
|
||||
float to_math = 0.0;
|
||||
print_info("vecResbattery = %d,temp = %s\n",vecResbattery.size(),vecResbattery[0][2].c_str());
|
||||
//LOG_INFO("vecResbattery = %d,temp = %s\n",vecResbattery.size(),vecResbattery[0][2].c_str());
|
||||
|
||||
for (size_t j = 0; j < vecResbattery.size(); j++)
|
||||
{
|
||||
float b = 2 - 25 * k;
|
||||
@ -926,7 +926,6 @@ int SqliteDB::CalculateBattery()
|
||||
}
|
||||
|
||||
print_info("自放电 = %f\n",to_math);
|
||||
//LOG_INFO("自放电 = %f\n",to_math);
|
||||
long sumworkTime = 0.0,sumsendTime = 0.0;
|
||||
for(size_t j = 0 ; j < vecworkTime.size();j++)
|
||||
{
|
||||
@ -937,11 +936,11 @@ int SqliteDB::CalculateBattery()
|
||||
sumsendTime += vecsendTime[j];
|
||||
}
|
||||
print_info("sumworkTime = %ld,sumsendTime = %ld\n",sumworkTime,sumsendTime);
|
||||
//LOG_INFO("sumworkTime = %ld,sumsendTime = %ld\n",sumworkTime,sumsendTime);
|
||||
|
||||
float usageworkTime = ((float)sumworkTime/3600000) * 4;
|
||||
float usagesendTime = ((float)sumsendTime/3600000) * 39;
|
||||
print_info("work = %f,send = %f\n",usageworkTime,usagesendTime);
|
||||
//LOG_INFO("work = %f,send = %f\n",usageworkTime,usagesendTime);
|
||||
|
||||
if(to_math < 0)
|
||||
to_math = 0;
|
||||
float usageBattery = usageworkTime + usagesendTime + to_math;
|
||||
@ -986,58 +985,7 @@ int SqliteDB::CalculateBattery()
|
||||
}
|
||||
}
|
||||
LOG_INFO("CalculateBattery end\n");
|
||||
|
||||
|
||||
|
||||
|
||||
/*float dayStaticPower = 6.5,dayWavePower = 237;//
|
||||
char whereCon[1024] = {0};
|
||||
char selectSql[1024] = { 0 };
|
||||
memset(whereCon,0x00,sizeof(whereCon));
|
||||
memset(selectSql,0x00,sizeof(selectSql));
|
||||
sprintf(selectSql," DataNodeNo,StaticTime,WaveTime,featureInterVal,waveInterVal,samplingRate ");
|
||||
array_t vecRes ;
|
||||
vecRes = GetDataMultiLine(T_SENSOR_INFO(TNAME), selectSql, NULL);
|
||||
if(vecRes.size() > 0){
|
||||
for(int i = 0; i < vecRes.size(); i++){
|
||||
if(vecRes[i][5] == "12800"){
|
||||
|
||||
}else if(vecRes[i][5] == "3200"){
|
||||
|
||||
}
|
||||
float dayStaticTime = 0.0;
|
||||
float dayWaveTime = 0.0;
|
||||
if(atoi(vecRes[i][3].c_str()) == 0){
|
||||
dayStaticTime = 0;
|
||||
}else{
|
||||
dayStaticTime = 24*60/atoi(vecRes[i][3].c_str());
|
||||
}
|
||||
if(atoi(vecRes[i][4].c_str()) == 0){
|
||||
dayWaveTime = 0;
|
||||
}else{
|
||||
dayWaveTime = 24*60/atoi(vecRes[i][4].c_str());
|
||||
}
|
||||
|
||||
float dayPower = dayStaticTime * dayStaticPower + dayWaveTime * dayWavePower + 24*3.26;//static + wave + sleep
|
||||
float usePower = atoi(vecRes[i][1].c_str()) * dayStaticPower + atoi(vecRes[i][2].c_str()) * dayWavePower;
|
||||
if(dayPower == 0)
|
||||
dayPower = 1;
|
||||
float remainDay = (19000000*0.5 - usePower)/dayPower;
|
||||
float bateryProportion = remainDay/(19000000*0.5/dayPower);
|
||||
char updateSql[1024] = { 0x00 };
|
||||
char tmpParam[1024] = {0x00};
|
||||
memset(whereCon,0x00,sizeof(whereCon));
|
||||
memset(updateSql,0x00,sizeof(updateSql));
|
||||
sprintf(whereCon,"dataNodeNo = '%s' ",vecRes[i][0].c_str());
|
||||
sprintf(updateSql,"batteryPower = '%f,%f' ",bateryProportion,remainDay);
|
||||
int iRet = UpdateTableData(T_SENSOR_INFO(TNAME), updateSql, whereCon);
|
||||
print_info("iRet = %d\n",iRet);
|
||||
string strData = sql_ctl->GetNodeConfigureInfor(whereCon);
|
||||
data_publish(strData.c_str(), GlobalConfig::Topic_G.mPubConfig.c_str());
|
||||
}
|
||||
}*/
|
||||
|
||||
print_info("CalculateBattery \n");
|
||||
return 0;
|
||||
}
|
||||
int SqliteDB::CalculateDip()
|
||||
@ -1326,7 +1274,6 @@ int SqliteDB::QueryofflineData()
|
||||
std::string strstatisticData = featureValue.write(root);
|
||||
|
||||
int iRet = data_publish(strstatisticData.c_str(), GlobalConfig::Topic_G.mPubData.c_str());
|
||||
//print_info("dataNodeNo = '%s' and TimeStamp = '%s',MQTT ret = %d\n",arrRetData[j][0].c_str(),nowTimetamp.c_str(),iRet);
|
||||
if(iRet == 0){
|
||||
char updateSql[1024] = { 0 };
|
||||
char whereCon[64] = { 0 };
|
||||
@ -1335,7 +1282,6 @@ int SqliteDB::QueryofflineData()
|
||||
memcpy(updateSql, "sendMsg='1'",sizeof(updateSql));
|
||||
sql_ctl->UpdateTableData(StaticTableName, updateSql, whereCon);
|
||||
sql_ctl->UpdateTableData(dataTableName, updateSql, whereCon);
|
||||
//LOG_INFO("resend success dataNodeNo = %s,TimeStamp = '%s'\n",arrRetData[j][0].c_str(),arrRetData[j][8].c_str());
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -1387,12 +1333,10 @@ int SqliteDB::QueryofflineData()
|
||||
sprintf(whereCon, "channelID='%s' and timeStamp = '%s' ", arrRetData[i][0].c_str(),arrRetData[i][2].c_str());
|
||||
sprintf(updateSql, "SendMsg = 1");
|
||||
sql_ctl->UpdateTableData("t_data_waveSend", updateSql, whereCon);
|
||||
//char whereCon[64]={0x00};
|
||||
//sprintf(whereCon,"waveName = '%s'",arrRetData[i][1].c_str());
|
||||
//DeleteTableData("t_data_waveSend", whereCon);
|
||||
|
||||
std::string strCmd = "rm " + arrRetData[i][1];
|
||||
system(strCmd.c_str());
|
||||
//LOG_INFO("resend success waveName = %s\n",arrRetData[i][1].c_str());
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ -58,17 +58,13 @@ void LocalServer::HandleFromServer(const char *pData_r, int pLen, const char *to
|
||||
Json::FastWriter fw;
|
||||
std::string strjson = fw.write(recvValue);
|
||||
data_publish(strjson.c_str(), GlobalConfig::Topic_G.mPubCmd.c_str());
|
||||
//system("echo 1 > /CIDW/start");
|
||||
|
||||
sleep(1);
|
||||
system("reboot");
|
||||
}
|
||||
break;
|
||||
case 12:{
|
||||
/* std::string strBody = recvValue["cmdBody"].asString();
|
||||
Json::Value jsBody;
|
||||
if (!recvReader.parse(strBody, jsBody)) {
|
||||
return;
|
||||
}*/
|
||||
|
||||
std::string timestamp = recvBody["timestamp"].asString();
|
||||
unsigned long itimestamp = atol(timestamp.c_str());
|
||||
SetTime(itimestamp);
|
||||
@ -78,14 +74,6 @@ void LocalServer::HandleFromServer(const char *pData_r, int pLen, const char *to
|
||||
std::string zoneid = recvValue["ZoneId"].asString();
|
||||
ZoneConfig(zoneid);
|
||||
}
|
||||
/* Json::Value retVal;
|
||||
retVal["dataNodeGatewayNo"] = GlobalConfig::MacAddr_G;
|
||||
retVal["cmd"] = 12;
|
||||
retVal["success"] = true;
|
||||
retVal["message"] = "校时成功";
|
||||
Json::FastWriter fw;
|
||||
std::string strjson = fw.write(retVal);
|
||||
data_publish(strjson.c_str(), GlobalConfig::Topic_G.mPubCmd.c_str());*/
|
||||
}
|
||||
break;
|
||||
case 13:{
|
||||
@ -167,7 +155,6 @@ void LocalServer::HandleFromServer(const char *pData_r, int pLen, const char *to
|
||||
JsonData jd;
|
||||
std::string data = jd.JsonCmd_25(param);
|
||||
data_publish(data.c_str(), GlobalConfig::Topic_G.mPubCmd.c_str());
|
||||
// platform->EquipIpInit();
|
||||
}
|
||||
break;
|
||||
case 26:{
|
||||
@ -182,7 +169,6 @@ void LocalServer::HandleFromServer(const char *pData_r, int pLen, const char *to
|
||||
JsonData jd;
|
||||
std::string data = jd.JsonCmd_26(param);
|
||||
data_publish(data.c_str(), GlobalConfig::Topic_G.mPubCmd.c_str());
|
||||
// platform->EquipIpInit();
|
||||
}
|
||||
break;
|
||||
case 27:{
|
||||
@ -419,7 +405,6 @@ try{
|
||||
}
|
||||
JsonData jd;
|
||||
std::string data = jd.JsonCmd_Cgi_25(param);
|
||||
//platform->EquipIpInit();
|
||||
return data;
|
||||
}
|
||||
break;
|
||||
|
||||
15
main.cpp
15
main.cpp
@ -48,8 +48,7 @@ int main(int argc, char *argv[])
|
||||
platform->PlatFormInit();
|
||||
|
||||
sql_ctl->InintGateway();
|
||||
//sql_ctl->CalculateData();
|
||||
//sql_ctl->CalculateBattery();
|
||||
|
||||
pUart->InitZigbee();
|
||||
// UDP,接收客户端发来的组播消息,用于外接 QT 专家系统,屏蔽之
|
||||
boost::thread searchT(SearchThread);
|
||||
@ -64,8 +63,7 @@ int main(int argc, char *argv[])
|
||||
|
||||
boost::thread InitModuleReadTh(InitModule);
|
||||
InitModuleReadTh.detach();
|
||||
//boost::thread uartWatchDogReadTh(WatchDog);
|
||||
//uartWatchDogReadTh.detach();
|
||||
|
||||
|
||||
// 休眠2秒,等待串口线程初始化完毕
|
||||
sleep(2);
|
||||
@ -124,15 +122,6 @@ int main(int argc, char *argv[])
|
||||
sleep(1);
|
||||
pUart->UpdateZigbeeInfoCtrl();
|
||||
|
||||
bool status = Ping( GlobalConfig::ServerIP.c_str(), 10000);
|
||||
print_info("===========status ======== %d\n",status);
|
||||
|
||||
/* char * szRes = sql_ctl->GetDataChar(T_SENSOR_INFO(TNAME), "dataNodeName", "dataNodeNo = '074cfd0000158d00'");
|
||||
printf("szRes = %s\n",szRes);
|
||||
for(int i = 0; i < 64;i++){
|
||||
printf("temp = %02x ",szRes[i]);
|
||||
}*/
|
||||
|
||||
//启动 mqtt客户端
|
||||
boost::thread startMqtt(StartMqttClient);
|
||||
startMqtt.detach();
|
||||
|
||||
@ -96,7 +96,7 @@ void CheckThread()
|
||||
std::string ipTemp = IpAddrInit();
|
||||
GlobalConfig::IpAddr_G = ipTemp;
|
||||
if ( 0 != ipTemp.compare(GlobalConfig::IpAddr_G)) {
|
||||
//exit(0);
|
||||
|
||||
}
|
||||
heart_count = 0;
|
||||
}
|
||||
@ -478,7 +478,6 @@ void HeartRep()
|
||||
int iRet = data_publish(strJson.c_str(), GlobalConfig::Topic_G.mPubHeart.c_str());
|
||||
print_info("heart = %s,iRet = %d\n",strJson.c_str(),iRet);
|
||||
if(iRet != 0){
|
||||
//count ++;
|
||||
gpio_set(GlobalConfig::GPIO_G.errorLed,1);
|
||||
sleep(1);
|
||||
gpio_set(GlobalConfig::GPIO_G.errorLed,0);
|
||||
@ -495,52 +494,8 @@ void HeartRep()
|
||||
count = 0;
|
||||
gpio_set(GlobalConfig::GPIO_G.errorLed,0);
|
||||
}
|
||||
//gpio_set(GlobalConfig::GPIO_G.errorLed,0);
|
||||
// if(count > 0){
|
||||
// bool status = Ping( GlobalConfig::ServerIP.c_str(), 10000);
|
||||
// if(status != 0)
|
||||
// //LOG_INFO("===========net status ========failed heart count %d\n",count);
|
||||
// if(status != 0 && count > 30){
|
||||
// LOG_ERROR("heart send failed,heart count %d\n",count);
|
||||
// count = 0;
|
||||
// sleep(20);
|
||||
// gpio_set(GlobalConfig::GPIO_G.power,1);
|
||||
// }
|
||||
// }
|
||||
// if(count > 1000){
|
||||
// gpio_set(GlobalConfig::GPIO_G.power,1);
|
||||
// count = 0;
|
||||
// }
|
||||
// write_data(fd,"AT+QENG=\"servingcell\"\r\n",27);
|
||||
// //sleep(1);
|
||||
// char buff[1024]={0x00};
|
||||
// int ret = read_data(fd, buff, 1024, 10);
|
||||
// print_info("ret = %d,buff = %s\n",ret,buff);
|
||||
// const char *str2 = "+QENG: ";
|
||||
// char csq[128] = {0};
|
||||
// char *pdata = strstr((char*)buff, str2);
|
||||
// if(pdata){
|
||||
// strncpy(csq, pdata+7, sizeof(csq));
|
||||
// }
|
||||
// else {
|
||||
// }
|
||||
//
|
||||
// //printf("SIM-CSQ: %s\n", csq);
|
||||
// GlobalConfig::NetStatus = GetOneContent(csq,1,",");
|
||||
// string signal = GetOneContent(csq,13,",");
|
||||
// GlobalConfig::NetSignal = atoi(signal.c_str());
|
||||
// print_info("NetStatus = %s,NetSignal = %d\n",GlobalConfig::NetStatus.c_str(),GlobalConfig::NetSignal);
|
||||
|
||||
//GlobalConfig::NetSignal = getcsq();
|
||||
/*if(GlobalConfig::NetSignal <= -105 ){
|
||||
gpio_set(130,1);
|
||||
}else if(GlobalConfig::NetSignal > -105 ){
|
||||
gpio_set(130,0);
|
||||
}else{
|
||||
gpio_set(130,1);
|
||||
}*/
|
||||
sleep(10);
|
||||
//socketHeart(strJson.c_str());
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -629,8 +584,7 @@ dial5G:
|
||||
}
|
||||
void UartStart()
|
||||
{
|
||||
// onReceiveUart cb = (onReceiveUart)&ProtoConvert::HandleFromUart;
|
||||
// pUart->setCallBack(cb);
|
||||
|
||||
print_info("zigAckrep = %d,zigAckreset = %d,zigReset = %d,errorLed = %d,power = %d",\
|
||||
GlobalConfig::GPIO_G.zigAckrep,GlobalConfig::GPIO_G.zigAckreset,GlobalConfig::GPIO_G.zigReset,GlobalConfig::GPIO_G.errorLed,\
|
||||
GlobalConfig::GPIO_G.power);
|
||||
@ -800,9 +754,6 @@ void my_connect_callback(struct mosquitto *mosq, void *obj, int result)
|
||||
GlobalConfig::LinkStatus_G = 1;
|
||||
print_debug("Connect to server success.\n");
|
||||
|
||||
// std::string cmd20 = JsonCmd_Cgi_20();
|
||||
// data_publish(cmd20.c_str(), GlobalConfig::Topic_G.mPubCmd.c_str());
|
||||
|
||||
char buf[256] = {0};
|
||||
sprintf(buf, "{\"dataNodeGatewayNo\":\"%s\",\"cmd\":\"12\",\"status\":\"REQ\"}",
|
||||
GlobalConfig::MacAddr_G.c_str());
|
||||
@ -875,8 +826,7 @@ void my_disconnect_callback(struct mosquitto *mosq, void *obj, int result)
|
||||
print_info("%s\n", buf);
|
||||
|
||||
#else
|
||||
// int iRet = reconnect();
|
||||
// print_info("reconnect = %d\n",iRet);
|
||||
|
||||
#endif
|
||||
|
||||
}
|
||||
|
||||
532
uart/SH_Uart.cpp
532
uart/SH_Uart.cpp
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user