From 499fc8166ddc4d71251c27329b026810759ec5a7 Mon Sep 17 00:00:00 2001
From: zhyinch <zhyinch@gmail.com>
Date: 星期一, 05 四月 2021 20:06:20 +0800
Subject: [PATCH] 改回SFD模式

---
 源码/核心板/Src/application/dw_app.c |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diff --git "a/\346\272\220\347\240\201/\346\240\270\345\277\203\346\235\277/Src/application/dw_app.c" "b/\346\272\220\347\240\201/\346\240\270\345\277\203\346\235\277/Src/application/dw_app.c"
index aa1e615..f704432 100644
--- "a/\346\272\220\347\240\201/\346\240\270\345\277\203\346\235\277/Src/application/dw_app.c"
+++ "b/\346\272\220\347\240\201/\346\240\270\345\277\203\346\235\277/Src/application/dw_app.c"
@@ -14,7 +14,7 @@
 	DWT_PAC8,        /* Preamble acquisition chunk size. Used in RX only. */
 	9,               /* TX preamble code. Used in TX only. */
 	9,               /* RX preamble code. Used in RX only. */
-	1,               /* Use non-standard SFD (Boolean) */
+	0,               /* Use non-standard SFD (Boolean) */
 	DWT_BR_6M8,      /* Data rate. */
 	DWT_PHRMODE_STD, /* PHY header mode. */
 	(129 + 8 - 8)    /* SFD timeout (preamble length + 1 + SFD length - PAC size). Used in RX only. */
@@ -925,7 +925,7 @@
 					/*--------------------------以下为非测距逻辑------------------------*/
 					//dist_cm=33000;
 					getrange_success = 1;
-					g_Resttimer=0;
+					
 					LED0_BLINK; //每成功一次通讯则闪烁一次
 					dis_after_filter=dist_cm;
 					hex_dist = dist_cm+(int16_t)g_com_map[DIST_OFFSET]*10;
@@ -935,6 +935,7 @@
 					if(abs(hex_dist-his_dist[taglist_pos])<dist_threshold||misdist_num[taglist_pos]>3)
 					{
 						int32_t filter_dist;
+                        g_Resttimer=0;
 						#ifdef TDFILTER
 						NewTrackingDiffUpdate(taglist_pos, (float)hex_dist);
 						filter_dist=pos_predict[taglist_pos]/10;

--
Gitblit v1.9.3