From e747e6d8524e3146bb48dc304a713f309966b1c6 Mon Sep 17 00:00:00 2001 From: 黄学彪 <hxb@hdlchina.com.cn> Date: 星期二, 19 五月 2020 13:10:03 +0800 Subject: [PATCH] 新版本 --- ZigbeeApp/Shared/Phone/ZigBee/Common/Application.cs | 11 +++++++++++ 1 files changed, 11 insertions(+), 0 deletions(-) diff --git a/ZigbeeApp/Shared/Phone/ZigBee/Common/Application.cs b/ZigbeeApp/Shared/Phone/ZigBee/Common/Application.cs index c446b42..ec0ce95 100755 --- a/ZigbeeApp/Shared/Phone/ZigBee/Common/Application.cs +++ b/ZigbeeApp/Shared/Phone/ZigBee/Common/Application.cs @@ -334,6 +334,10 @@ { //鏈湴Socket public static Socket busSocket; + /// <summary> + /// 璁℃椂鍣� + /// </summary> + private static int timeCount = 0; /// <summary> /// 鍚姩Socket鎺ユ敹鍜屽彂閫佸姛鑳� @@ -406,6 +410,13 @@ private static void CheckConnectiton() { if (busSocket == null) { return; } + timeCount++; + if (timeCount < 20) + { + //姣�10绉掓娴嬩竴娆� + return; + } + timeCount = 0; bool blockingState = busSocket.Blocking; try -- Gitblit v1.8.0