From 6f2dc73bb6bd5ff48cb4a2e77e9e7b6a93828902 Mon Sep 17 00:00:00 2001
From: yy1717 <fctom1215@outlook.com>
Date: 星期二, 07 一月 2020 19:21:39 +0800
Subject: [PATCH] 修改进程间接口,统一为foo(int, string)

---
 lib/src/main/cpp/rtk_platform/parse_net.cpp |   10 +++++++---
 1 files changed, 7 insertions(+), 3 deletions(-)

diff --git a/lib/src/main/cpp/rtk_platform/parse_net.cpp b/lib/src/main/cpp/rtk_platform/parse_net.cpp
index 8ab1330..c6ab56d 100644
--- a/lib/src/main/cpp/rtk_platform/parse_net.cpp
+++ b/lib/src/main/cpp/rtk_platform/parse_net.cpp
@@ -17,6 +17,7 @@
 #include "../common/net.h"
 #include "platform.h"
 #include "../mcu/mcu_if.h"
+#include "../utils/xconvert.h"
 
 using namespace std;
 
@@ -847,11 +848,9 @@
     sem_post(&sem_tx_mgr);
 }
 
-void PlatformTxInit(const uint8_t *phone)
+void PlatformTxInit(void)
 {
     //2019101500000001
-    memcpy(PhoneNumber, phone, PHONE_NUM_SIZE);
-
 /*    PhoneNumber[0] = 0x20;
     PhoneNumber[1] = 0x19;
     PhoneNumber[2] = 0x10;
@@ -872,6 +871,11 @@
     pthread_create(&pid, &attr, TxQueueMgrThread, NULL);
 }
 
+void SetPlatformTxPhoneNum(const char *phone)
+{
+    ConvertPhoneNum(PhoneNumber, sizeof(PhoneNumber), phone);
+}
+
 void CommonRespend(uint8_t access, uint16_t seq, uint16_t id, uint8_t value)
 {
     uint8_t data[5];

--
Gitblit v1.8.0