zhangbo
2 天以前 2656eff0472262bd13bab16b41a3176a52895d69
keil/include/main/main.c
@@ -272,6 +272,7 @@
            userkey_state = 1;
            keystarttime3 =  HIDO_TimerGetTick();
            flag_first_TCPconnect = 1;
//            TCPHeartBeatUpload();
            //UDPClient_UploadGPS();
        }
//        if(HIDO_TimerGetTick() - keystarttime2>10)
@@ -329,6 +330,7 @@
    }
    
}
uint8_t jingzhi_flag=0;
void SecondTask(void)
{   static uint8_t second_count;
    if(second_count++>60)
@@ -360,6 +362,10 @@
    HIDO_TimerTick();
//      if(nomove_count<=g_com_map[NOMOVESLEEP_TIME])//防止溢出
    nomove_count++;
    if(nomove_count>g_com_map[ALARM_DISTANCE1])
    {
      jingzhi_flag=1;
    }
//    gaodu=GetPressAndHeight()*100;
//      else{
//      nomove_count=g_com_map[NOMOVESLEEP_TIME]+1;
@@ -537,6 +543,7 @@
//    g_com_map[GROUP_ID]=9;
    group_id=g_com_map[GROUP_ID];//组ID
    memcpy(&disoffset,&g_com_map[DIST_OFFSET],2);
//    g_com_map[ALARM_DISTANCE1]=10;
    warning_distance=g_com_map[ALARM_DISTANCE1];
    prewarning_distance=g_com_map[ALARM_DISTANCE2];
    send_struct.warnDistence=warning_distance;
@@ -587,7 +594,7 @@
    g_com_map[MODBUS_MODE] = 0;
    log_4g_enable_flag =1;//g_com_map[LOG_4G_ENABLE];
    g_com_map[VERSION] = (2<<8)|14;
    g_com_map[VERSION] = (2<<8)|15;
    LOG_INFO(TRACE_MODULE_APP,"设备ID: %x .\r\n",dev_id);