zhyinch
2022-04-23 b32e18a80201f1f285f172f07dda6b48beb6bab6
Ô´Âë/ºËÐİå/Src/application/dw_app.c
@@ -23,7 +23,7 @@
static uint8_t tx_final_msg[60] = {0};
static uint8_t tx_resp_msg[22] = {0};
static uint8_t tx_nearpoll_msg[80] = {0};
static uint8_t tx_nearresp_msg[80] = {0};
static uint8_t tx_nearresp_msg[90] = {0};
static uint8_t tx_nearfinal_msg[80] = {0};
static uint8_t tx_near_msg[80] = {0};
@@ -472,7 +472,7 @@
}
uint32_t time_monitor[10];
extern uint16_t configremotetagID;
extern u8 remotetag_paralen;
extern u8 remotetag_paralen,userdatasend_flag[TAG_NUM_IN_SYS];
u8 finalsend=0;
u16 signalpower_list[TAG_NUM_IN_SYS];
uint32_t poll_tx_ts, resp_rx_ts, final_tx_ts;
@@ -497,7 +497,7 @@
         dwt_setrxaftertxdelay(RESP_TX_TO_FINAL_RX_DLY_UUS+(rec_nearbase_num+1-ancrec_nearbasepos)*DELAY_BETWEEN_TWO_FRAME_UUS);//设置发送完成后开启接收延迟时间
         dwt_setrxtimeout(FINAL_RX_TIMEOUT_UUS);//接收超时时间
         //dwt_readdiagnostics(&d1);
         if(tagpos[taglist_pos].tagid==tag_id_recv)
         if(tagpos[taglist_pos].tagid==tag_id_recv&&userdatasend_flag[taglist_pos] == 1)
            {
                memcpy(&tx_nearresp_msg[TAGPOS_INDEX],&tagpos[taglist_pos],tagpos[taglist_pos].datalen+3);
                tagpossend_flag = 1;
@@ -512,7 +512,7 @@
            memcpy(&tx_nearresp_msg[ANC_SIGNALPOWER],&signalpower_list[taglist_pos],2);
         tx_nearresp_msg[MAINBASE_INDEX]=flag_syncbase;
         tx_nearresp_msg[MESSAGE_TYPE_IDX]=NEAR_RESPONSE;
         tx_nearresp_msg[MOTORSTATE_INDEX]=(remotesend_state<<4)|motorstate;
         //tx_nearresp_msg[MOTORSTATE_INDEX]=(remotesend_state<<4)|motorstate;
         waittagconfig_reponse=0;
            finalsend = 0;
         if(pwtag.remain_time>0)
@@ -611,7 +611,7 @@
               LED0_BLINK; //每成功一次通讯则闪烁一次
               dis_after_filter=dist_cm;
               hex_dist = dist_cm+(int16_t)g_com_map[DIST_OFFSET];
               userdatasend_flag[taglist_pos] =0;
               if(hex_dist>-1000&&hex_dist<200000)
               {
                        g_flag_Taggetdist[taglist_pos]=0;
@@ -871,7 +871,7 @@
         }
      
      }
      if(i==MAX_REGTAGNUM)
      if(i==MAX_REGTAGNUM&&g_com_map[NEARSWITCH_DISTANCE_INDEX] != 0)
      {
         dwt_readdiagnostics(&d1);
         LOS(&d1);