From adfc7e798b9cbdd022bf8df971843436912a0fe5 Mon Sep 17 00:00:00 2001
From: chen <15335560115@163.com>
Date: 星期日, 20 七月 2025 16:58:30 +0800
Subject: [PATCH] 成功移植g_com_map表逻辑,初步测试能读能写,并且TDOA效果和官方一致

---
 keil/include/components/app/src/uci_tl_task.c |   24 +++++++++++++++++++++---
 1 files changed, 21 insertions(+), 3 deletions(-)

diff --git a/keil/include/components/app/src/uci_tl_task.c b/keil/include/components/app/src/uci_tl_task.c
index 0db4d26..0fc8095 100644
--- a/keil/include/components/app/src/uci_tl_task.c
+++ b/keil/include/components/app/src/uci_tl_task.c
@@ -1,5 +1,5 @@
 /*
- * Copyright (c) 2019-2023 Beijing Hanwei Innovation Technology Ltd. Co. and
+ * Copyright (c) 2019-2025 Beijing Hanwei Innovation Technology Ltd. Co. and
  * its subsidiaries and affiliates (collectly called MKSEMI).
  *
  * All rights reserved.
@@ -87,7 +87,8 @@
 
     if (count < UCI_MAX_UL_ITEMS)
     {
-        struct UCI_TL_MSG_T *p = WsfBufAlloc((uint16_t)(len + sizeof(struct UCI_TL_MSG_T)));
+        uint16_t up_data_len = (uint16_t)(len + sizeof(struct UCI_TL_MSG_T));
+        struct UCI_TL_MSG_T *p = WsfBufAlloc(up_data_len);
 
         if (p != NULL)
         {
@@ -97,8 +98,9 @@
         }
         else
         {
-            LOG_INFO(TRACE_MODULE_UCI, "No buff to up queue\r\n");
+            LOG_INFO(TRACE_MODULE_UCI, "No buff to up queue %u\r\n", up_data_len);
         }
+        // LOG_INFO(TRACE_MODULE_UCI, "HCI %02x %02x %02x %02x\r\n", buf[0], buf[1], buf[2], buf[3]);
     }
     else
     {
@@ -135,6 +137,22 @@
     }
 }
 
+void uci_tl_rx_stop(void)
+{
+    if (uci_tl_dev->uci_tl_rx_stop)
+    {
+        uci_tl_dev->uci_tl_rx_stop();
+    }
+}
+
+void uci_tl_rx_restart(void)
+{
+    if (uci_tl_dev->uci_tl_rx_restart)
+    {
+        uci_tl_dev->uci_tl_rx_restart();
+    }
+}
+
 /*************************************************************************************************/
 /*!
  *  \brief  WSF event handler for UCI transmission layer task.

--
Gitblit v1.9.3